: '

  This script translates to lua any syntagma script. It works by
  first translating the script to nom. It doesnt actually do that
  by using the /tr/syntagma.pss script (which is a syntagma-to-nom
  translator) rather it uses the lua translation of that script to 
  do the translating. The point of all this is to test the lua 
  translation chain which relies on the /tr/nom.tolua.pss nom script.

  If /tr/syntagma.pss changes then the lua version should be 
  updated with the bash script /tr/make.lua.syntagma.tonom.sh
  or just by typeing:
  >> pep -f tr/nom.tolua.pss tr/syntagma.pss > tr/syntagma.tonom.lua
   
TESTING

 * test a simple syntagma script to parse lower case words
 ------
  echo "wo:[a-z]+;ignore [:space:]; ww = wo wo|ww wo;" | ./syntagma.tolua.sh
  echo "this is a" | ./temp.lua    # displays parse stack
  echo "a dot. here" | ./temp.lua  # displays error about unlexed character "."
 ,,,

HISTORY
  26 may 2026 began, seems to be working.
'

# cat > temp.txt;
# cat temp.txt | $PEPNOM/tr/syntagma.tonom.lua > $out;

name="temp.lua"; 
out="$PEPNOM/tr/$name";
temp="$PEPNOM/tr/temp.pss";

# this get stdin automatically.
$PEPNOM/tr/syntagma.tonom.lua > $temp;

# should substitute this for /tr/nom.tolua.lua
pep -f $PEPNOM/tr/nom.tolua.pss $temp > $out
chmod a+x $out; # cat $out;
echo
echo "
 translated syntagma script into nom as 'tr/temp.pss'
 translated syntagma script into lua as 'tr/$name'
 Try it out with, eg: 

  echo '<input>' | tr/$name
  cat input.txt | tr/$name";

