Convert usfm bibles into gemtext (python library/utility)
usfm2gmi: Add 'sp' tag
Zach DeCook 2023-09-06
parent 930590a · commit 3679315
-rwxr-xr-xusfm2gmi.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/usfm2gmi.py b/usfm2gmi.py
index e618870..222d800 100755
--- a/usfm2gmi.py
+++ b/usfm2gmi.py
@@ -43,9 +43,9 @@ def convert(line):
elif split[0] in ['\\mt1','\\mt','\\ms','\\h']:
return '\n# ' + convert(' '.join(split[1:]))
# TODO: parse as word for title tags in title line
- elif split[0] in ['\\mt2','\\s']:
+ elif split[0] in ['\\mt2','\\s','\\s1']:
return '\n## ' + convert(' '.join(split[1:]))
- elif split[0] in ['\\mt3','\\d']:
+ elif split[0] in ['\\mt3','\\d', '\\sp']:
return '\n### ' + convert(' '.join(split[1:]))
elif split[0] == '\\b':
return '\n'