Skip to content

Instantly share code, notes, and snippets.

@eltonlaw
Last active October 30, 2018 16:29
Show Gist options
  • Save eltonlaw/13259a65f4ea0a85a74cfc2d03fad29c to your computer and use it in GitHub Desktop.
Save eltonlaw/13259a65f4ea0a85a74cfc2d03fad29c to your computer and use it in GitHub Desktop.
# Homebrew binaries now take precedence over Apple defaults
export PATH=/usr/local/bin:$PATH
# For ctrl-z both ways
stty susp undef
bind '"\C-z":"fg\015"'
# Display Settings
export PS1="\[\033[36m\]\u\[\033[m\]@\[\033[32m\]\h:\[\033[33;1m\]\w\[\033[m\]\$ "
export PS1="\e[0;31m> \e[0;37m"
export CLICOLOR=1
export LSCOLORS=ExFxBxDxCxegedabagacad
# MacOS Fix for Tmux 2.2 and Slimux compatibility
export EVENT_NOKQUEUE=1
export EVENT_NOPOLL=1
# Encoding
export LC_ALL=en_CA.UTF-8
export LANG=en_CA.UTF-8
tldr_random() {
array=($(compgen -c));
r=$((RANDOM % ${#array[@]}));
while tldr ${array[$r]} | grep "This page doesn't exist yet!" > /dev/null; do
r=$((RANDOM % ${#array[@]}));
done
tldr ${array[$r]};
}
# Aliases
alias ls='ls -GFh'
alias python="python3"
alias ta="tmux attach"
alias tldr_random=tldr_random
neofetch
# tldr_random
# If direnv exists run it
if hash direnv 2>/dev/null; then
eval "$(direnv hook bash)"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment