diff options
author | Philipp Gesang <phg@phi-gamma.net> | 2021-11-21 19:22:18 +0100 |
---|---|---|
committer | Philipp Gesang <phg@phi-gamma.net> | 2021-11-21 19:29:47 +0100 |
commit | 814b93d12bc9a0792b150527495ece0847a343fc (patch) | |
tree | d7ce166f7f642956e12db8104493075f9d71d4f6 /scripts/context/lua/third | |
parent | 798c814949998d48b06d37b55d7f26d72477bf82 (diff) | |
download | transliterator-814b93d12bc9a0792b150527495ece0847a343fc.tar.gz |
reorganize source tree
Diffstat (limited to 'scripts/context/lua/third')
-rw-r--r-- | scripts/context/lua/third/transliterator/mtx-t-transliterate.lua | 64 |
1 files changed, 0 insertions, 64 deletions
diff --git a/scripts/context/lua/third/transliterator/mtx-t-transliterate.lua b/scripts/context/lua/third/transliterator/mtx-t-transliterate.lua deleted file mode 100644 index a6e3968..0000000 --- a/scripts/context/lua/third/transliterator/mtx-t-transliterate.lua +++ /dev/null @@ -1,64 +0,0 @@ --- --------------------------------------------------------------------------------- --- FILE: mtx-transliterate.lua --- USAGE: mtxrun --script transliterate [--mode=mode] --s="string" --- DESCRIPTION: context script interface for the Transliterator module --- REQUIREMENTS: latest ConTeXt MkIV --- AUTHOR: Philipp Gesang (Phg), <gesang@stud.uni-heidelberg.de> --- CREATED: 2011-06-11T16:14:16+0200 --------------------------------------------------------------------------------- --- - -environment.loadluafile("transliterator") - -local translit = thirddata.translit - -translit.__script = true -scripts = scripts or { } -scripts.transliterate = { } -local ea = environment.argument - -local helpinfo = [[ -=============================================================== - The Transliterator module, command line interface. - © 2010--2011 Philipp Gesang. License: 2-clause BSD. - Home: <https://bitbucket.org/phg/transliterator/> -=============================================================== - -USAGE: - - mtxrun --script transliterate [--mode=mode] --s="target" - - Where “target” is the target string to be transliterated. - Optionally, a transliteration mode can be specified (see - the respective descriptions in transliterator.pdf). The - “mode” defaults to “ru_old”. - -=============================================================== -]] - -local application = logs.application { - name = "mtx-transliterate", - banner = "The Transliterator for ConTeXt, hg-rev 38+", - helpinfo = helpinfo, -} - -scripts.transliterate.input = ea("s") -scripts.transliterate.out = function (sin, sout) - if ea("silent") then - io.write(sout) - else - io.write(string.format("\n“%s” -> “%s”\n", sin, sout)) - end -end - -if scripts.transliterate.input then - local mode = ea("mode") or "ru_old" - scripts.transliterate.out( - scripts.transliterate.input, - translit.transliterate(mode, ea("s")) - ) -else - application.help() -end - |