Skip to content

Instantly share code, notes, and snippets.

@rubypanther
Created September 8, 2012 01:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rubypanther/3671304 to your computer and use it in GitHub Desktop.
Save rubypanther/3671304 to your computer and use it in GitHub Desktop.
Convert C comments for Ruby 2 (using sed)
s/\/\/(.*http:\/\/.*)$/\/* \1 *\//g
t
s/(http:\/\/.*)$/\1/g
t
s/\/\/(.*)$/\/* \1 *\//g
find $1 -name '*.c' | xargs sed -r -i -f rb_ansi_to_iso.sed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment