9base

revived minimalist port of Plan 9 userland to Unix
git clone git://git.suckless.org/9base
Log | Files | Refs | README | LICENSE

cvt (246B)


      1 #!/bin/sh
      2 
      3 /usr/bin/sed -E '
      4 	s/\.(sp|rsp)/.s.\1/g
      5 	s/\.(ep|rep)/.e.\1/g
      6 	s/(\.|->)(cp|r|subid|right)([^a-zA-Z0-9_])/\1u1.\2\3/g
      7 	s/(\.|->)(left|next)([^a-z])/\1u2.\2\3/g
      8 	/#include <u.h>/d
      9 	s/<libc.h>/"lib9.h"/g
     10 	s/"regexp.h"/"regexp9.h"/g
     11 ' $*