From 9a06c367a89e4e8a980fe7c1a5dea7fa5b95aca9 Mon Sep 17 00:00:00 2001 From: Martin Potier Date: Wed, 30 Mar 2016 22:52:31 +0200 Subject: [PATCH] Adding zsh config --- configure | 6 ++++ zsh/.zsh-aliases | 10 ++++++ zsh/.zsh-color-names | 72 ++++++++++++++++++++++++++++++++++++++++++++ zsh/.zshrc | 33 ++++++++++++++++++++ 4 files changed, 121 insertions(+) create mode 100644 zsh/.zsh-aliases create mode 100644 zsh/.zsh-color-names create mode 100644 zsh/.zshrc diff --git a/configure b/configure index 176f136..a064dd5 100755 --- a/configure +++ b/configure @@ -56,6 +56,12 @@ case $1 in echo "On first tmux start, run 'prefix + I' to install modules" exit 0 ;; + "zsh" ) + echo "Installing zsh config" + git clone git://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh + stow -v zsh + echo "You can add your local config in ~/.zsh-local-$HOST" + ;; * ) echo "$1 cannot be installed…" exit 1 diff --git a/zsh/.zsh-aliases b/zsh/.zsh-aliases new file mode 100644 index 0000000..b1004bc --- /dev/null +++ b/zsh/.zsh-aliases @@ -0,0 +1,10 @@ +alias m='mosh protonpack -- tmux a' +alias ocaml="rlwrap ocaml" +alias please="sudo" +alias scan="simple-scan 'hpaio:/net/Photosmart_2570_series?ip=192.168.1.43'" +alias scan="simple-scan 'hpaio:/net/Photosmart_2570_series?ip=impOlitin.local'" +alias skype="ssh docker-skype skype-pulseaudio" +alias vimus="vimus -h /home/eeva/.config/mpd/mpd.socket" +alias v="viewnior" +alias z="zathura" +alias copy="xclip -selection clipboard" diff --git a/zsh/.zsh-color-names b/zsh/.zsh-color-names new file mode 100644 index 0000000..bb5a8b0 --- /dev/null +++ b/zsh/.zsh-color-names @@ -0,0 +1,72 @@ +# Reset +Color_Off='\e[0m' # Text Reset + +# Regular Colors +Black='\e[0;30m' # Black +Red='\e[0;31m' # Red +Green='\e[0;32m' # Green +Yellow='\e[0;33m' # Yellow +Blue='\e[0;34m' # Blue +Purple='\e[0;35m' # Purple +Cyan='\e[0;36m' # Cyan +White='\e[0;37m' # White + +# Bold +BBlack='\e[1;30m' # Black +BRed='\e[1;31m' # Red +BGreen='\e[1;32m' # Green +BYellow='\e[1;33m' # Yellow +BBlue='\e[1;34m' # Blue +BPurple='\e[1;35m' # Purple +BCyan='\e[1;36m' # Cyan +BWhite='\e[1;37m' # White + +# Underline +UBlack='\e[4;30m' # Black +URed='\e[4;31m' # Red +UGreen='\e[4;32m' # Green +UYellow='\e[4;33m' # Yellow +UBlue='\e[4;34m' # Blue +UPurple='\e[4;35m' # Purple +UCyan='\e[4;36m' # Cyan +UWhite='\e[4;37m' # White + +# Background +On_Black='\e[40m' # Black +On_Red='\e[41m' # Red +On_Green='\e[42m' # Green +On_Yellow='\e[43m' # Yellow +On_Blue='\e[44m' # Blue +On_Purple='\e[45m' # Purple +On_Cyan='\e[46m' # Cyan +On_White='\e[47m' # White + +# High Intensity +IBlack='\e[0;90m' # Black +IRed='\e[0;91m' # Red +IGreen='\e[0;92m' # Green +IYellow='\e[0;93m' # Yellow +IBlue='\e[0;94m' # Blue +IPurple='\e[0;95m' # Purple +ICyan='\e[0;96m' # Cyan +IWhite='\e[0;97m' # White + +# Bold High Intensity +BIBlack='\e[1;90m' # Black +BIRed='\e[1;91m' # Red +BIGreen='\e[1;92m' # Green +BIYellow='\e[1;93m' # Yellow +BIBlue='\e[1;94m' # Blue +BIPurple='\e[1;95m' # Purple +BICyan='\e[1;96m' # Cyan +BIWhite='\e[1;97m' # White + +# High Intensity backgrounds +On_IBlack='\e[0;100m' # Black +On_IRed='\e[0;101m' # Red +On_IGreen='\e[0;102m' # Green +On_IYellow='\e[0;103m' # Yellow +On_IBlue='\e[0;104m' # Blue +On_IPurple='\e[0;105m' # Purple +On_ICyan='\e[0;106m' # Cyan +On_IWhite='\e[0;107m' # White diff --git a/zsh/.zshrc b/zsh/.zshrc new file mode 100644 index 0000000..71cba1f --- /dev/null +++ b/zsh/.zshrc @@ -0,0 +1,33 @@ +# Path to your oh-my-zsh installation. +export ZSH=$HOME/.oh-my-zsh + +# Default plugins (used everywhere) +plugins=(git systemd) + +ZSH_THEME="lambda" +source $ZSH/oh-my-zsh.sh + +export EDITOR='vim' + +# Set GPG_AGENT_INFO +export GPG_TTY=$(tty) +if [ -f "/tmp/.gpg-agent-info" ]; then + . "/tmp/.gpg-agent-info" + export GPG_AGENT_INFO +fi + +# Pick a local at random for this session +export LANG=$(locale -a | grep -vE "(C|POSIX)" | sort -R | head -n1) +unset LC_CTYPE + +# Some more aliases +source $HOME/.zsh-aliases + +# Define color names +source $HOME/.zsh-color-names + +# Local config (not shared) +if [ -f "$HOME/.zsh-local-$HOST" ]; then + source $HOME/.zsh-local-$HOST +fi +