aboutsummaryrefslogtreecommitdiffstats
path: root/IRC/translate_colors.py
diff options
context:
space:
mode:
authormakefu <github@syntax-fehler.de>2015-08-28 11:05:44 +0200
committermakefu <github@syntax-fehler.de>2015-08-28 11:05:44 +0200
commit8a8abdde5b9b834fb4f51fcfb44df239e572b8af (patch)
tree5d12f09eb2653774d92983000a3c530b7129ec87 /IRC/translate_colors.py
parent50d9d22aea21701ddde0a349ddb92ffb6b1c66e2 (diff)
Reaktor: IRC -> reaktor
Remove Obsolete README, remove obsolete index
Diffstat (limited to 'IRC/translate_colors.py')
-rw-r--r--IRC/translate_colors.py31
1 files changed, 0 insertions, 31 deletions
diff --git a/IRC/translate_colors.py b/IRC/translate_colors.py
deleted file mode 100644
index bd71661..0000000
--- a/IRC/translate_colors.py
+++ /dev/null
@@ -1,31 +0,0 @@
-
-
-COLOR_MAP = {
- "\x1b[0m" : "\x0F", # reset
- "\x1b[37m" : "\x0300",
- "\x1b[30m" : "\x0301",
- "\x1b[34m" : "\x0302",
- "\x1b[32m" : "\x0303",
- "\x1b[31m" : "\x0304",
- "\x1b[33m" : "\x0305",
- "\x1b[35m" : "\x0306",
- "\x1b[33m" : "\x0307",
- "\x1b[33m" : "\x0308",
- "\x1b[32m" : "\x0309",
- "\x1b[36m" : "\x0310",
- "\x1b[36m" : "\x0311",
- "\x1b[34m" : "\x0312",
- "\x1b[31m" : "\x0313",
- "\x1b[30m" : "\x0314",
- "\x1b[37m" : "\x0315",
- "\x1b[1m" : "\x02", # bold on
- "\x1b[22m" : "\x02" # bold off
- }
-def translate_colors (line):
- for color,replace in COLOR_MAP.items():
- line = line.replace(color,replace)
- return line
-
-if __name__ == "__main__":
- import sys
- print (translate_colors(sys.stdin.read()))