Re: [PATCH v3 0/5] notes.c: introduce "--no-blank-line" option

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Teng Long <dyroneteng@xxxxxxxxx> writes:

> Junio C Hamano <gitster@xxxxxxxxx> writes:
>
>> I personally do not have much opinion on this topic, other than that
>> "--no-blank-link" would be a horrible name (i.e. uses concrete words
>> to pretend that it clearly describes what it does, but is utterly
>> unclear where these blank lines are etc.) for the feature to help
>> end-users discover it.
>
> I have some a candidates might like '--newline' and '--no-newline', or
> 'splitted-newline' or 'no-splitted-newline', but I think the latter is
> a little long.
>
> Thanks.

I do not care much between blank and newline.  

Both alone are equally horrible, in that the option would have no
effect when "git notes edit" is used and spawns an editor, or "git
notes append -m one -m two" is used and the command adds the second
paragraph whose text is "two".

Just like "git commit", the argument to each "-m" option becomes a
separate paragraph by default.  I personally feel that those who
want to make them separate lines deserve to have an option like this
one, so that they can do

 $ git notes add -m foo HEAD
 $ git notes append \
	--each-message-is-line-not-paragraph -m bar -m baz
 $ git notes show HEAD
 foo
 bar
 baz

but the point is "blank-line" or "newline" does not say which
newline in the resulting notes object you are mucking with.  It is
not like in this example:

 $ git notes add -m "title of the note"
 $ git notes append --no-blank-line -m "body of the note

 that span multiple

 lines" HEAD

you are removving the blank lines embedded in the body of the
message, but from the option name, it is hard to guess that.



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux