citadel

My dotfiles, scripts and nix configs
git clone git://jb55.com/citadel
Log | Files | Refs | README | LICENSE

switch-term-themes (329B)


      1 #! /usr/bin/env nix-shell
      2 #! nix-shell -i python3 -p python3
      3 
      4 import os
      5 import sys
      6 import subprocess
      7 
      8 theme = sys.argv[1]
      9 pts = os.listdir('/dev/pts/')
     10 for each_pts in pts:
     11   if each_pts.isdigit():
     12     subprocess.call('echo "`~/.dynamic-colors/bin/dynamic-colors switch {0}`" > /dev/pts/{1}'.format(theme,each_pts), shell=True)
     13