2012-10-08 19:42:27 +00:00
|
|
|
# URL Tools
|
|
|
|
# Adds handy command line aliases useful for dealing with URLs
|
|
|
|
#
|
|
|
|
# Taken from:
|
|
|
|
# http://ruslanspivak.com/2010/06/02/urlencode-and-urldecode-from-a-command-line/
|
|
|
|
|
2012-11-28 23:33:45 +00:00
|
|
|
alias urlencode='node -e "console.log(encodeURIComponent(process.argv[1]))"'
|
2012-10-08 19:42:27 +00:00
|
|
|
|
2012-11-28 23:33:45 +00:00
|
|
|
alias urldecode='node -e "console.log(decodeURIComponent(process.argv[1]))"'
|