zsh-config/zshrc

60 lines
1.4 KiB
Bash
Raw Normal View History

2014-12-02 21:07:00 +05:00
#!/bin/bash
# ^^^ THIS IS FOR SYNTAX HIGHLIGHT!
#. /etc/profile
#####################################################################
# CONFIGURATION
# -------------
# You should set these variables :)
#####################################################################
# The very important thing - debug.
# Should we enable debug output?
DEBUG=0
# Prompt configuration
PROMPT_THEME="pztrn"
# FBTerm - should we use it?
# nVidia users with proprietary drivers - sorry, you can't use it.
USE_FBTERM=0
2014-12-02 21:07:00 +05:00
# PyENV in use?
USE_PYENV=0
# Path to PyENV.
PYENV_PATH="/data/.pyenv"
2014-12-02 21:07:00 +05:00
#####################################################################
# INITIALIZATION
# --------------
# Here goes initialization thing.
# DO NOT CHANGE ANYTHING, UNLESS YOU ARE KNOW WHAT ARE YOU DOING!
#####################################################################
# Get real script path.
CONFIG_PATH=''
CONFIG_FOUND=0
if [ -h ${HOME}/.zshrc ]; then
CONFIG_PATH=`readlink ${HOME}/.zshrc`
CONFIG_PATH=`dirname ${CONFIG_PATH}`
if [ ${#CONFIG_PATH[@]} -gt 0 ]; then
CONFIG_FOUND=1
else
echo "CONFIG_PATH has invalid value: '${CONFIG_PATH}'"
fi
fi
# Some sourcing.
source ${CONFIG_PATH}/zsh/lib/logger.lib.sh
if [ $CONFIG_FOUND -eq 1 ]; then
for config_file in `ls ${CONFIG_PATH}/zsh/ | sort | grep zsh`; do
source ${CONFIG_PATH}/zsh/${config_file}
done
else
error "Failed to load configuration."
2014-12-02 21:07:00 +05:00
fi
set -B