shithub: rc

ref: 094869e40b9ab8fb1bb2f548fbe3847f81710900
dir: /bin/mfmt/

View raw version
#!/bin/rc
pref=$1
fmt=$2
sed \
	$pref^'
	s/^''//
	s/''$//
	s/[\[\]\!,\(\)''\$\*\?:\;=\}\{`]//g
	s/#/♯/g
	s/\&/and/g
	s/( - | |_)/./g
	s/\.[^\.]+$/.'^$fmt^'/
	s/ /./g
	s/\.\.+/./g
' |\
	tr A-ZА-Я a-zа-я