shithub: bin.rc

ref: f6706e1759c3e16f6f710ac897b7aa1cb5e22fa4
dir: /bin/rn/

View raw version
#!/bin/rc
from=$1
to=$2
charconst='''[^'']*'''
strconst='"([^"]|\\")*"'
name='[a-zA-Z_][a-zA-Z_0-9]*'
partial=.^`{echo -n $from | tr -c '' .}
exec ssam 'y/'$charconst'/ y/'$strconst'/ x/'$name'/ g/'$from'/ v/'$partial'/ c/'$to