Re: [PATCH 4/6] sequencer: avoid empty lines after 'update-ref' instructions

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

 



On 9/30/2022 10:09 AM, SZEDER Gábor wrote:
> When the sequencer generates a todo list for 'git rebase
> --update-refs', it always inserts an empty line after each
> 'update-ref' instruction and after each comment line about checked out
> refs.  These empty lines are unnecessary, distracting, and waste
> valuable vertical screen real estate, especially when multiple refs
> point to the same commit:
> 
>   pick 29a79f8 two
>   pick 74bf293 three
>   # Ref refs/heads/branch3 checked out at '/tmp/test/WT'
> 
>   update-ref refs/heads/branch2
> 
>   update-ref refs/heads/branch1
> 
>   pick 5f59b82 four
> 
> Eliminate those empty lines.

After this change, I think the end result is this:

  pick 29a79f8 two
  pick 74bf293 three
  # Ref refs/heads/branch3 checked out at '/tmp/test/WT'
  update-ref refs/heads/branch2
  update-ref refs/heads/branch1
  pick 5f59b82 four

Specifically, there is no whitespace break between the last
'update-ref' command and the next 'pick' command. Since the
'update-ref' commands likely correspond to chunks of changes,
it would be nice to still have that whitespace remain. I
agree that the whitespace between the comments and previous
'update-ref' commands is wasteful, but I'd rather leave the
wasteful (and usually rare) whitespace than lose the helpful
whitespace.

There is precedent for this kind of whitespace when using
'--rebase-merges'.

If you can find a nice way to add a line of whitespace between
these lines and the next instruction type, then I fully
support this change.

Thanks,
-Stolee



[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