fix(cli): ignore system/user git configs
So they don't interfere with straight in odd, unpredictable ways. If you *really* know what you're doing, set DOOMGITCONFIG to the path of a gitconfig file. This envvar may be renamed in the future, however. Close: #5640 Co-authored-by: M. Yas. Davoodeh <Davoodeh@users.noreply.github.com>
This commit is contained in:
parent
c36d1702fb
commit
a9c22b704b
2 changed files with 4 additions and 1 deletions
3
bin/doom
3
bin/doom
|
@ -2,6 +2,9 @@
|
|||
:; set -e # -*- mode: emacs-lisp; lexical-binding: t -*-
|
||||
:; case "$EMACS" in *term*) EMACS=emacs ;; *) EMACS="${EMACS:-emacs}" ;; esac
|
||||
:; $EMACS --version >/dev/null 2>&1 || { >&2 echo "Can't find emacs in your PATH"; exit 1; }
|
||||
:; unset GIT_CONFIG
|
||||
:; export GIT_CONFIG_NOSYSTEM=1
|
||||
:; export GIT_CONFIG_GLOBAL="${DOOMGITCONFIG:-/dev/null}"
|
||||
:; $EMACS --no-site-file --script "$0" -- "$@" || __DOOMCODE=$?
|
||||
:; [ "${__DOOMCODE:-0}" -eq 128 ] && { sh "`$EMACS -Q --batch --eval '(princ temporary-file-directory)'`/doom.sh" "$0" "$@" && true; __DOOMCODE=$?; }
|
||||
:; exit $__DOOMCODE
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue