diff options
author | Robin Haberkorn <robin.haberkorn@googlemail.com> | 2025-08-07 20:07:34 +0300 |
---|---|---|
committer | Robin Haberkorn <robin.haberkorn@googlemail.com> | 2025-08-07 20:15:58 +0300 |
commit | 0da832023b3d7d0921de1f76acbf6dd2595341d0 (patch) | |
tree | fcddc59d0a952a6a2a5455152480bf9df2f9b0f6 | |
parent | c385217bbb6448eb21d0cb1568e3cc10c47d0b5b (diff) | |
download | sciteco-0da832023b3d7d0921de1f76acbf6dd2595341d0.tar.gz |
added tecat.tes to standard library: can be installed as the Git textconv filter
tecat.tes and repl.tes are now executable scripts, even though they are
installed into the $SCITECOPATH.
This is still much slower than the Lua version here:
https://gist.github.com/rhaberkorn/6534ecf1b05de6216d0a9c33f31ab5f8
-rw-r--r-- | freebsd/pkg-plist | 1 | ||||
-rw-r--r-- | lib/Makefile.am | 13 | ||||
-rwxr-xr-x[-rw-r--r--] | lib/repl.tes | 3 | ||||
-rwxr-xr-x | lib/tecat.tes | bin | 0 -> 532 bytes |
4 files changed, 15 insertions, 2 deletions
diff --git a/freebsd/pkg-plist b/freebsd/pkg-plist index 3fe8a43..d7dd9a8 100644 --- a/freebsd/pkg-plist +++ b/freebsd/pkg-plist @@ -12,6 +12,7 @@ share/man/man7/%%PROGRAM_PREFIX%%sciteco.7.gz %%DATADIR%%/lib/getopt.tes %%DATADIR%%/lib/lexer.tes %%DATADIR%%/lib/repl.tes +%%DATADIR%%/lib/tecat.tes %%LEXILLA%%%%DATADIR%%/lib/lexers/abaqus.tes %%LEXILLA%%%%DATADIR%%/lib/lexers/ada.tes %%LEXILLA%%%%DATADIR%%/lib/lexers/asciidoc.tes diff --git a/lib/Makefile.am b/lib/Makefile.am index 194802f..ae57c47 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -1,9 +1,20 @@ +include $(top_srcdir)/bootstrap.am dist_scitecolib_DATA = color.tes lexer.tes session.tes opener.tes \ fnkeys.tes string.tes getopt.tes # standalone scripts -dist_scitecolib_DATA += repl.tes +dist_scitecolib_SCRIPTS = repl.tes tecat.tes + +# Fix up the hash-bang line of installed SciTECO scripts upon +# installation to refer to the installed sciteco binary. +# This takes --program-prefix into account. +# +# FIXME: This will patch the hash-bang line repeatedly. +install-data-hook: + $(SCITECO_FULL) -e "<%i^[ :Q[^A^E\\i]:; @EB'$(DESTDIR)$(scitecolibdir)/^EN[^A^E\\i]'> 1U* \ + EJ-1<%*^[ 0,^Q::@FR'#!^EM^Xsciteco'#!$(SCITECO_INSTALLED)'> \ + :EX" $(dist_scitecolib_SCRIPTS) # Helper script for creating lexer definitions EXTRA_DIST = scite2co.lua diff --git a/lib/repl.tes b/lib/repl.tes index 9cfa8c0..b830e8b 100644..100755 --- a/lib/repl.tes +++ b/lib/repl.tes @@ -1,10 +1,11 @@ +#!/usr/local/bin/sciteco -m !* * This is a stand-alone script that mimics * classic TECO command lines. * Requires an ANSI-compatible terminal. * * Currently, you must set the terminal characteristics on the outside: - * stty raw opost icrnl && sciteco -m repl.tes + * stty raw opost icrnl && /usr/local/share/sciteco/lib/repl.tes * * You can launch into interactive mode by typing -u#ex * diff --git a/lib/tecat.tes b/lib/tecat.tes Binary files differnew file mode 100755 index 0000000..a09c458 --- /dev/null +++ b/lib/tecat.tes |