From 790435b0d33bf0ae518409be59d804e4f6f97c13 Mon Sep 17 00:00:00 2001 From: Julien Palard Date: Fri, 21 Apr 2017 14:36:05 +0200 Subject: [PATCH] s/python2/python3/ --- .bashrc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.bashrc b/.bashrc index e52e210..8f6359d 100644 --- a/.bashrc +++ b/.bashrc @@ -169,13 +169,13 @@ jsonpp() urldecode() { input="$([ $# -gt 0 ] && printf "%s\n" "$*" || cat -)" - python -c "import urllib2, sys; print urllib2.unquote(sys.argv[1])" "$input" + python3 -c "import urllib.parse, sys; print(urllib.parse.unquote(sys.argv[1]))" "$input" } urlencode() { input="$([ $# -gt 0 ] && printf "%s\n" "$*" || cat -)" - python -c "import urllib2, sys; print urllib2.quote(sys.argv[1])" "$input" + python3 -c "import urllib.parse, sys; print(urllib.parse.quote(sys.argv[1]))" "$input" } # Removes *~ and #*# files in curent folder, for a depth limited to 3 folders.