]> git.ipfire.org Git - thirdparty/git.git/commit
remote set-head: set followRemoteHEAD to "warn" if "always"
authorBence Ferdinandy <bence@ferdinandy.com>
Thu, 5 Dec 2024 12:16:22 +0000 (13:16 +0100)
committerJunio C Hamano <gitster@pobox.com>
Thu, 5 Dec 2024 17:59:40 +0000 (02:59 +0900)
commit012bc566bad79876f4809d1e730a348b419772d0
treefe711e3876917ee28f1b522158ed41f7608c84d2
parent9e2b7005becaf730ff75f6efbef4542cc4454107
remote set-head: set followRemoteHEAD to "warn" if "always"

When running "remote set-head" manually it is unlikely, that the user
would actually like to have "fetch" always update the remote/HEAD. On
the contrary, it is more likely, that the user would expect remote/HEAD
to stay the way they manually set it, and just forgot about having
"followRemoteHEAD" set to "always".

When "followRemoteHEAD" is set to "always" make running "remote
set-head" change the config to "warn".

Signed-off-by: Bence Ferdinandy <bence@ferdinandy.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/remote.c
t/t5505-remote.sh