1
0
Fork 0

bin: urlencode + urldecode

This commit is contained in:
Jeremy Kaplan 2025-03-21 14:01:32 -04:00
commit 5f2cbf20fa
2 changed files with 22 additions and 0 deletions

11
bin/urlencode Executable file
View file

@ -0,0 +1,11 @@
#!/usr/bin/env python3
import sys
from urllib.parse import quote
args = sys.argv[1:]
if len(args) > 0:
for arg in args:
print(quote(arg))
else:
print(quote(sys.stdin.read()), end='')