diff --git a/.zshrc2 b/.zshrc2 index 66b879d..1ecb5a0 100644 --- a/.zshrc2 +++ b/.zshrc2 @@ -100,6 +100,7 @@ alias "se"='sudo -sE' alias "pbd"='ping baidu.com' alias "p114"='ping 114.114.114.114' alias "p666"='ping6 2001:da8::666' +alias "gdebug"='git add -A; git commit -m "bug fix"' case $(bash "$DOTFILES/tools/common.sh" get_os_type) in macos ) alias l='ls -lAGh -D "%y-%m-%d %H:%M"' ;; * ) alias l='ls -lAGh --time-style="+%y-%m-%d %H:%M"' ;; diff --git a/tools/common.sh b/tools/common.sh index 87fcdfa..2e38c85 100755 --- a/tools/common.sh +++ b/tools/common.sh @@ -1,8 +1,8 @@ #!/bin/bash - +set -e THIS_DIR_COMMON_SH=$( cd "$( dirname "${BASH_SOURCE[0]:-${(%):-%x}}" )" && pwd ) export DOTFILES=$( cd "$THIS_DIR_COMMON_SH/.." && pwd ) -if [[ -f ~/.config/dotfiles/env ]]; then source ~/.config/dotfiles/env; fi +if [[ -f ~/.config/dotfiles/env ]]; then set -a; source ~/.config/dotfiles/env; set +a; fi # Color settings # Source: https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh