From: Philippe Blain Date: Sat, 16 Mar 2024 19:44:49 GMT Subject: Re: [PATCH v2 2/2] builtin/am: allow disabling conflict advice Message-ID: <1961b9dc-e372-b0f9-9185-a1c11d32f1b3@gmail.com> In-Reply-To: Hi Phillip and Junio, Le 2024-03-11 à 13:49, Junio C Hamano a écrit : > Junio C Hamano writes: > >>> I think you need to append "\n" to the message strings here (and >>> below) to match the behavior of printf_ln(). >> >> Good eyes. You'll get the final "\n" but the line breaks inside the >> paragraph you give to advise*() functions are your responsibility. >> Even though advice.c:vadvise() handles multi-line message better >> (unlike usage.c:vreportf() that is used for error() and die()) by >> giving a line header for each line of the message, we do not wrap >> lines at runtime. > > Perhaps something like this. Thanks Phillip for noticing, and Junio for the fix. I should have looked at the output, apologies. I made sure that the test passed but since t/t4150-am.sh only checks for the "To record the empty patch as an empty commit" string, it still passed despite the missing newlines. Just a note if it helps anyone: I cherry-picked Junio's fixes using: b4 shazam -P _ '' Cheers, Philippe.