about summary refs log tree commit diff stats
path: root/adapter/tools/urldec.nim
diff options
context:
space:
mode:
Diffstat (limited to 'adapter/tools/urldec.nim')
-rw-r--r--adapter/tools/urldec.nim6
1 files changed, 6 insertions, 0 deletions
diff --git a/adapter/tools/urldec.nim b/adapter/tools/urldec.nim
new file mode 100644
index 00000000..b26fcb68
--- /dev/null
+++ b/adapter/tools/urldec.nim
@@ -0,0 +1,6 @@
+# Percent-decode input received on stdin.
+#TODO a streaming implementation of this could be useful
+
+import utils/twtstr
+
+stdout.write(percentDecode(stdin.readAll()))