diff options
| author | onefang | 2026-01-28 12:36:53 +1000 |
|---|---|---|
| committer | onefang | 2026-01-28 12:36:53 +1000 |
| commit | 95ee2d6423fe0fcbf0b938a310658be46d0381ad (patch) | |
| tree | 2686ce27067ae9824c1654b90ebf1fbe10627e89 /SuckIt | |
| parent | OOps, forgot this bit. (diff) | |
| download | notYetAnotherWiki-95ee2d6423fe0fcbf0b938a310658be46d0381ad.zip notYetAnotherWiki-95ee2d6423fe0fcbf0b938a310658be46d0381ad.tar.gz notYetAnotherWiki-95ee2d6423fe0fcbf0b938a310658be46d0381ad.tar.bz2 notYetAnotherWiki-95ee2d6423fe0fcbf0b938a310658be46d0381ad.tar.xz | |
Basic DocuWiki conversion.
Diffstat (limited to 'SuckIt')
| -rwxr-xr-x | SuckIt | 9 |
1 files changed, 9 insertions, 0 deletions
| @@ -15,6 +15,15 @@ cp -r /opt/nyaw_EMPTY/unsorted . | |||
| 15 | mkdir -p users | 15 | mkdir -p users |
| 16 | cp -r /opt/nyaw_EMPTY/users . | 16 | cp -r /opt/nyaw_EMPTY/users . |
| 17 | 17 | ||
| 18 | ogWiki="DocuWiki" | ||
| 19 | time find DocuWiki \ | ||
| 20 | -name "*.txt" -type f,l -printf "%P\n" | while read line | ||
| 21 | do | ||
| 22 | base=`echo "${line}" | cut -d '/' -f 1- | rev | cut -d '/' -f 2- | rev` | ||
| 23 | file=`echo "${line}" | rev | cut -d '/' -f 1 | cut -b 5- | rev` | ||
| 24 | pandoc -f dokuwiki -t commonmark_x --self-contained ${ogWiki}/${line} >${ogWiki}/${base}/${file}.md | ||
| 25 | done | ||
| 26 | |||
| 18 | # Copy across things like images that where uploaded. | 27 | # Copy across things like images that where uploaded. |
| 19 | mkdir -p /opt/nyaw/Foswiki/pub/ | 28 | mkdir -p /opt/nyaw/Foswiki/pub/ |
| 20 | # TODO - Should rsync this instead. | 29 | # TODO - Should rsync this instead. |
