Re: [PATCH 1/2] commit: add message options for rebase --autosquash

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

 



On Fri, Sep 17, 2010 at 9:14 AM, Bryan Drewery <bryan@xxxxxxxxxx> wrote:
> Stephen Boyd wrote:
>>
>> On 09/16/2010 06:39 PM, Pat Notz wrote:
>>
>>>
>>> These options make it convenient to construct commit messages for use
>>> with 'rebase --autosquash'.  The resulting commit message will be
>>> "fixup! ..." or "squash! ..." where "..." is the subject line of the
>>> specified commit message.
>>>
>>> Example usage:
>>>  $ git commit --fixup HEAD~2
>>>  $ git commit --squash HEAD~5
>>>
>>> Signed-off-by: Pat Notz <patnotz@xxxxxxxxx>
>>> ---
>>>
>>
>> So far I've been using an alias for these, but I suppose making them
>> real features of git could be worthwhile. What are the benefits with
>> this approach vs. an alias?
>>
>>
>
> I keep wanting to do these at commit time.
>
> What are the alternative aliases?
>

`git fixup' is aliased to `!f() { git commit -m "$(git show -s
--pretty='format:fixup! %s%n%nFixup for %h%n' "$1")" $2; }; f'
`git squash' is aliased to `!f() { git commit -m "$(git show -s
--pretty='format:squash! %s%n%n' "$1")" -e $2; }; f'
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[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]