0
0
Fork 0
mirror of https://github.com/ohmyzsh/ohmyzsh.git synced 2024-09-12 04:01:14 +02:00

fix(git-auto-fetch): avoid password prompt with GIT_TERMINAL_PROMPT=0 (#11234)

This commit is contained in:
Syphdias 2022-10-14 19:12:04 +02:00 committed by GitHub
parent 52e848ce8f
commit 08d5c936c6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -28,6 +28,7 @@ function git-fetch-all {
# Fetch all remotes (avoid ssh passphrase prompt)
date -R &>! "$gitdir/FETCH_LOG"
GIT_SSH_COMMAND="command ssh -o BatchMode=yes" \
GIT_TERMINAL_PROMPT=0 \
command git fetch --all 2>/dev/null &>> "$gitdir/FETCH_LOG"
) &|
}