diff options
Diffstat (limited to 'zsh/env')
| -rw-r--r-- | zsh/env | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -8,9 +8,12 @@ source_if_exists() { [[ -f $(dotfiles_root)/$1 ]] && . $(dotfiles_root)/$1 || return 0 } -export DOMAIN=${$(cut -d. -f2- -s <<<${HOST}):l} +[[ ${HOST} =~ \\. ]] && export DOMAIN=${(j:.:)${(s:.:)HOST}[-2,-1]:l} export HOST=${HOST:l} -export UNAME=${$(uname):l} +case ${OSTYPE} in + darwin*) export UNAME=darwin ;; + linux*) export UNAME=linux ;; +esac setopt EXTENDED_GLOB setopt REMATCH_PCRE |
