From: Stefan Sperling Subject: Re: Make "got branch -d" print reference name and value To: Christian Weisgerber Cc: gameoftrees@openbsd.org Date: Sat, 4 Sep 2021 17:46:48 +0200 On Sat, Sep 04, 2021 at 04:06:44PM +0200, Christian Weisgerber wrote: > make "got branch -d" print reference name and value > > Currently, "branch -d" operates silently. With this change we match > the behavior of "ref -d" and "rebase -X"/"histedit -X" that print > sufficient information to allow recovering if the user fat-fingered > something. > > I was about to copy-paste the code from delete_ref() into > delete_branch(), but I think we can just call delete_ref(). > > OK? OK. You'll also want this patch to prevent this new line of output from appearing during 'make regress': diff 376d7c6217310146ba605e4994521c6fde62fc18 /home/stsp/src/got blob - 2e47e88822a9bd8fc8b102ab03348302fe334aa7 file + regress/cmdline/fetch.sh --- regress/cmdline/fetch.sh +++ regress/cmdline/fetch.sh @@ -438,7 +438,7 @@ test_fetch_delete_branch() { return 1 fi - got branch -r $testroot/repo -d foo + got branch -r $testroot/repo -d foo >/dev/null got fetch -q -r $testroot/repo-clone ret="$?"