urltools.plugin.zsh 329 Bytes
Newer Older
Ian Chesal's avatar
Ian Chesal committed
1
2
3
4
5
6
# 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/

7
alias urlencode='node -e "console.log(encodeURIComponent(process.argv[1]))"'
Ian Chesal's avatar
Ian Chesal committed
8

9
alias urldecode='node -e "console.log(decodeURIComponent(process.argv[1]))"'