I'm thinking maybe OP wants to run `git commit -m` from a script or
automate the messages in some fashion. There might be a better way,
but the following will work:

echo -e "Line One\nLine Two" | git commit -a -F -

The `-e` option tells `echo` to treat `\n` as an escape sequence. The
echoed output is piped to `git commit`, and the `-F -` option tells
Git to read the message from stdin.

Hope that's what you're looking for.

- Ryan

On Fri, Oct 12, 2012 at 12:16 AM, Gadget/Steve <gadgetst...@hotmail.com> wrote:
> On 12/10/2012 3:58 AM, lei yang wrote:
>> I know git commit -m "somethingsomething" will give the git info in the git 
>> log
>>
>> but I don't know how to write some thing with more than two line some
>> thing like
>>
>> something something
>> something something
>> something something
>>
>> in the git log
>>
> One solution is not to specify the -m "something.." on the command line
> - the commit process will then start vi, or whatever you have set as
> your editor, for you to type in as long a commit comment as you like.
>
> Gadget/Steve
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Git for human beings" group.
> To post to this group, send email to git-users@googlegroups.com.
> To unsubscribe from this group, send email to 
> git-users+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/git-users?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To post to this group, send email to git-users@googlegroups.com.
To unsubscribe from this group, send email to 
git-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/git-users?hl=en.

Reply via email to