Skip to content

Instantly share code, notes, and snippets.

@anton0xf
Forked from anonymous/stdin.txt
Created July 4, 2012 08:18
Show Gist options
  • Save anton0xf/3046049 to your computer and use it in GitHub Desktop.
Save anton0xf/3046049 to your computer and use it in GitHub Desktop.
stdin
sed -n 's/[^<>]*<[ \t\n]*set[ \t\n]\+value='\''\([^'\'']*\)'\''[ \t\n]\+name='\''\([^'\'']*\)'\''[ \t\n]*\/>[^<>]*/\n\$\$"\1","\2"\n/pg' test | sed -n 's/^\$\$\(.*\)$/\1/p;'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment