]> gitweb.pimeys.fr Git - scripts-20-100.git/commitdiff
rangement
authorVincent Le Gallic <legallic@crans.org>
Mon, 9 Dec 2013 11:41:26 +0000 (12:41 +0100)
committerVincent Le Gallic <legallic@crans.org>
Mon, 9 Dec 2013 11:41:26 +0000 (12:41 +0100)
ftp/percent_decode.py [new file with mode: 0755]
percent_decode.py [deleted file]

diff --git a/ftp/percent_decode.py b/ftp/percent_decode.py
new file mode 100755 (executable)
index 0000000..8fc51c9
--- /dev/null
@@ -0,0 +1,28 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+
+"""Piper dedans un flux avec des %20 et autres cochonneries,
+   il ressortira lisible."""
+
+__author__ = "Vincent Le Gallic <legallic@crans.org>"
+
+__license__ = "WTFPL"
+
+import urllib
+import sys
+import time
+
+
+red="\e[1;31m"
+nocolor="\e[0m"
+
+try:
+    while True:
+        l = sys.stdin.readline()
+        if l != "":
+            l = urllib.unquote(l)
+            if "--color" in sys.argv:
+                l = l.replace('"PUT ', '"%sPUT%s ' % (red, nocolor))
+            sys.stdout.write(l)
+except KeyboardInterrupt:
+    pass
diff --git a/percent_decode.py b/percent_decode.py
deleted file mode 100755 (executable)
index 8fc51c9..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-#!/usr/bin/env python
-# -*- coding: utf-8 -*-
-
-"""Piper dedans un flux avec des %20 et autres cochonneries,
-   il ressortira lisible."""
-
-__author__ = "Vincent Le Gallic <legallic@crans.org>"
-
-__license__ = "WTFPL"
-
-import urllib
-import sys
-import time
-
-
-red="\e[1;31m"
-nocolor="\e[0m"
-
-try:
-    while True:
-        l = sys.stdin.readline()
-        if l != "":
-            l = urllib.unquote(l)
-            if "--color" in sys.argv:
-                l = l.replace('"PUT ', '"%sPUT%s ' % (red, nocolor))
-            sys.stdout.write(l)
-except KeyboardInterrupt:
-    pass