aboutsummaryrefslogtreecommitdiff
path: root/c2x
diff options
context:
space:
mode:
authorInqiyad Sabr <sabr@ariamath.xyz>2025-11-02 10:07:40 +0600
committerInqiyad Sabr <sabr@ariamath.xyz>2025-11-02 10:07:40 +0600
commit11b86ff1a85efe5d1170ea8c90ebca5ac313e24f (patch)
tree12356d8e8677d77b166b8e00d614f491d632597b /c2x
Add files
Diffstat (limited to 'c2x')
-rwxr-xr-xc2x8
1 files changed, 8 insertions, 0 deletions
diff --git a/c2x b/c2x
new file mode 100755
index 0000000..8ee737c
--- /dev/null
+++ b/c2x
@@ -0,0 +1,8 @@
+#!/bin/sh
+[ -s ./"$1_xhtml" ] && rm -rf "./${1}_xhtml"
+cp -r ./"${1}" ./"${1}_xhtml"
+cd ./"${1}_xhtml" || exit
+for file in $(find ./* | grep ".gmi" | sed 's/.gmi//'); do
+ g2x < "./${file}.gmi" > "./${file}.html"
+ rm "./${file}.gmi"
+done