[TxMt] Re: SCM Diff Gutter

Caio Fernando Bertoldi Paes de Andrade caiofbpa at icloud.com
Fri Dec 5 16:09:28 UTC 2014

Allan, thanks for the guidance, I found the problem.

I had configured my git to globally show colour in its output, by setting color.ui to always.
This added color code characters before the + or - the bundle's command matches the output against, making it think no changes were made.
I solved it by setting color.ui to auto, which still gives me coloured output when I’m on terminal, but doesn’t pollute the output when TM executes it.

Since color.ui auto is the default since git 1.8.4, I don’t think many others will run into the same issue, but you could consider adding a —no-color flag to the git diff invocation inside the bundle’s command, which would make sure no one has the same problem ever again.


> On 4 Dec 2014, at 23:41, Allan Odgaard <mailinglist at textmate.org> wrote:
> On 5 Dec 2014, at 7:50, Caio Fernando Paes de Andrade wrote:
>> Every test I made I opened a file, added a new line of code and saved the file. No changes in the gutter happened in any test case.
> You can find the source of the command via the bundle editor: SCM Diff Gutter → Other Actions → Update Gutter on Save.
> I suggest you insert some debug statements in this command to figure out why it does not work for you.
> For example insert this on last line to get a dialog on save that show added/changed line numbers, as parsed by the command:
> 	abort "Added: #{added.join(', ')}\nChanged: #{changed.join(', ')}"
> If you do not get such dialog, then it doesn’t run the command or exits at the top, because TM_SCM_NAME is unset.
> _______________________________________________
> textmate mailing list
> textmate at lists.macromates.com
> http://lists.macromates.com/listinfo/textmate

More information about the textmate mailing list