1
0
Fork 0
dotfiles/bin/urlencode
2025-03-21 14:01:32 -04:00

11 lines
201 B
Python
Executable file

#!/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='')