summaryrefslogtreecommitdiff
path: root/zsh/.zsh/functions
diff options
context:
space:
mode:
authorUrbain Vaes <urbain@vaes.uk>2016-04-19 15:24:25 +0100
committerUrbain Vaes <urbain@vaes.uk>2016-04-19 15:24:25 +0100
commite146e947c52ac4adbe426b3f893faff1e46ed5f8 (patch)
tree1605bf4eb78cc619988c92632f3cee2a56143fd5 /zsh/.zsh/functions
parent83bd503208d45fa837348441196dd07223b13e3e (diff)
Use GNU stow for dotfiles management
Diffstat (limited to 'zsh/.zsh/functions')
-rw-r--r--zsh/.zsh/functions16
1 files changed, 16 insertions, 0 deletions
diff --git a/zsh/.zsh/functions b/zsh/.zsh/functions
new file mode 100644
index 0000000..7c2b49a
--- /dev/null
+++ b/zsh/.zsh/functions
@@ -0,0 +1,16 @@
+#!/bin/zsh
+
+function colo {
+
+ # Change colors for current session
+ $HOME/bin/recolor < ~/.Xresources/$1
+
+ # Load Xresources file for future sessions
+ xrdb -I$HOME ~/.Xresources/$1
+
+ # Change environment variable
+ export COLORSCHEME=$1
+
+ # Change default environment variable for future sessions
+ sed -i --follow-symlinks "s/^export COLORSCHEME=.*$/export COLORSCHEME=$1/g" ~/.zsh/tmp
+}