Skip to content

Instantly share code, notes, and snippets.

@belano
Created January 18, 2015 17:12
Show Gist options
  • Save belano/fa4076056957bf9108dd to your computer and use it in GitHub Desktop.
Save belano/fa4076056957bf9108dd to your computer and use it in GitHub Desktop.
set global variables in zsh while keeping things compatible with bash, add this to either /etc/zsh/zprofile or ~/.zprofile
# User config for login shells
if [ -d /etc/profile.d ]; then
for i in /etc/profile.d/*.sh; do
if [ -r $i ]; then
. $i
fi
done
unset i
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment