Re: [PATCH 1/2] rm: better error message on failure for multiple files
- From
- Mathieu Liénard--Mayor <mathieu.lienard--mayor@ensimag.fr>
- Date
- Jun 10, 2013, 07:43 UTC
- Message-ID
- <f3f6cb36e56ea8fdf7ebe22230c2aff7@ensibm.imag.fr>
- In-Reply-To
- <CALkWK0mqVCfrPgSLi1dnDv26YAyRrJJD_S179VYfEApmGkd4Uw@mail.gmail.com>
Once again, thanks a lot your feedback, we appreciate it a lot! Le 2013-06-08 15:51, Ramkumar Ramachandra a écrit :
Show 21 quoted lines
> Mathieu Lienard--Mayor wrote:
>> @@ -170,30 +175,47 @@ static int check_local_mod(unsigned char
>> *head, int index_only)
>> * "intent to add" entry.
>> */
>> if (local_changes && staged_changes) {
>> - if (!index_only || !(ce->ce_flags &
>> CE_INTENT_TO_ADD))
>> - errs = error(_("'%s' has staged
>> content different "
>> - "from both the file and
>> the HEAD\n"
>> - "(use -f to force
>> removal)"), name);
>> + if (!index_only || !(ce->ce_flags &
>> CE_INTENT_TO_ADD)) {
>> + strbuf_addstr(&files_staged, "\n
>> ");
>
> Ouch. Wouldn't a string-list be more appropriate for this kind of
> thing?Matthieu Moy told me string-list would be better aswell, so we're gonna change it.
-- Mathieu Liénard--Mayor, 2nd year at Grenoble INP - ENSIMAG (+33)6 80 56 30 02