Skip to content

Instantly share code, notes, and snippets.

@crazy-max
Created June 3, 2013 00:36
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 crazy-max/5695521 to your computer and use it in GitHub Desktop.
Save crazy-max/5695521 to your computer and use it in GitHub Desktop.
url decode
#! /bin/sh
echo "http%3A%2F%2Fwww.foo.com%2Findex.php%3Fid%3Dqwerty" | sed -e "s/%\([0-9A-F][0-9A-F]\)/\\\\\x\1/g" | xargs -0 echo -e
# http://www.foo.com/index.php?id=qwerty
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment