summaryrefslogtreecommitdiff
path: root/Scripts/Rex2T1000.py
diff options
context:
space:
mode:
authorJulian Teu <julianteule@gmail.com>2018-04-10 18:07:28 +0200
committerJulian Teu <julianteule@gmail.com>2018-04-10 18:07:28 +0200
commit3e00fc23117a6fbb91d5ca09602f8006c3f2365a (patch)
tree4e3f2288424a5c09e9815eff04719f620cd7b321 /Scripts/Rex2T1000.py
parenta3443fca6351cbe9ecbbe29a32e358f7534a92a6 (diff)
Cleanup
Diffstat (limited to 'Scripts/Rex2T1000.py')
-rwxr-xr-xScripts/Rex2T1000.py28
1 files changed, 0 insertions, 28 deletions
diff --git a/Scripts/Rex2T1000.py b/Scripts/Rex2T1000.py
deleted file mode 100755
index 87e4204..0000000
--- a/Scripts/Rex2T1000.py
+++ /dev/null
@@ -1,28 +0,0 @@
-#!/usr/bin/env python
-
-# URXVT Colors -> Terminator config file format by Stolid. Enjoy. I can't promise it will work every time.
-
-import subprocess, os
-
-urxvt_cfg = os.path.expanduser('~')+'/.Xresources'
-
-colors = []
-def getColorSetting(search):
- p1 = subprocess.Popen(['grep', search, urxvt_cfg], stdout=subprocess.PIPE)
- output = subprocess.Popen(['head', '-n1'], stdin=p1.stdout, stdout=subprocess.PIPE)
- r = ' '.join(output.communicate()[0].split())
- r = '#' + r.split('#')[-1]
- return r
-for i in range(0,15+1):
- p1 = subprocess.Popen(['grep', 'color'+str(i), urxvt_cfg], stdout=subprocess.PIPE)
- p2 = subprocess.Popen(['head', '-n1'], stdin=p1.stdout, stdout=subprocess.PIPE)
- output = p2.communicate()[0]
- color = ' '.join(output.split())
- color = color.split('#')[-1]
- colors.append('#'+color)
-#print colors
-print( '\nColors parsed out of ~/.Xresources and terminator-config-file-ized (replace the relevant lines in your ~/.config/terminator/config):\n')
-print( 'palette = "' + (':'.join(colors)) + '"')
-print( 'background_color = "' + getColorSetting('*background:') + '"')
-print( 'foreground_color = "' + getColorSetting('*foreground:') + '"')
-print( 'cursor_color = "' + getColorSetting('cursorColor:') + '"')