Jump to content
Mike Torrettinni

DPROJ changes: SourceTree vs Beyond Compare

Recommended Posts

Every now and then I notice that SourceTree seems to detect as if the whole .dproj file is changed:

 

image.thumb.png.a9e65f601144f066b9a8a37b358d44a5.png

 

... and all red lines until line 499, the limit to what it shows. If I use External diff option, the Beyond Compare finds just 2 lines of change:

 

image.png.52d12f7f09b34710668bf2dfe5a8333a.png

 

 

I will report to JIRA, but since it's freeware I doubt any useful help will be provided.

 

I'm curios if anybody else noticed this anomaly and found a solution. Could it be 10.2.3 IDE is causing some odd issue that triggers how SourceTree handles this file, while BeyondCompare handles it correctly?

Share this post


Link to post

It's just a text file. My guess is that either the file encoding or line breaks have changed.

If you can provide a file "before" and "after", I'm sure we can find what's up.

 

I don't know about SourceTree, but diff editors often have an option whether line breaks or whitespace changes should be taken into account.

Edited by Der schöne Günther
  • Thanks 1

Share this post


Link to post
1 hour ago, Der schöne Günther said:

whitespace changes

That was it! I had an option to hide whitespace difference. Here is without this option enabled:

 

image.png.b019826486032ea6444c7f9363466dea.png

 

 

I checked the other .dproj files and with new project and actually double (4 char) indentation seems to be normal, so every now and then I get a version with single (2 char) indentation.

 

 

 

Share this post


Link to post
4 hours ago, Mike Torrettinni said:

I will report to JIRA, but since it's freeware I doubt any useful help will be provided.

SourceTree is made by Atlassian. Any time you spend reporting bugs to them would better spent picking your nose.

  • Haha 2

Share this post


Link to post
36 minutes ago, Mike Torrettinni said:

so every now and then I get a version with single (2 char) indentation.

This is probably a project last edited with an older Delphi version, which always wrote two spaces. Alas, I don't remember which one.

Share this post


Link to post
1 hour ago, Uwe Raabe said:

This is probably a project last edited with an older Delphi version, which always wrote two spaces. Alas, I don't remember which one.

It could be some relic from older versions (the project went from D7 -> D2006 -> D2009 -> a few XEs -> 10.2.3), and I've been using 10.2.3 for years now with this project, and the change I showed above occurred in today's commit.

Share this post


Link to post
2 hours ago, Anders Melander said:

SourceTree is made by Atlassian. Any time you spend reporting bugs to them would better spent picking your nose.

Classic! I can certainly attest to this.. currently researching how to migrate away from confluence for our documentation site.   

Share this post


Link to post
2 hours ago, Anders Melander said:

SourceTree is made by Atlassian. Any time you spend reporting bugs to them would better spent picking your nose.

Yes, I had a feeling it could be something like that. Their SourceTree support site doesn't give too much confidence: https://community.atlassian.com/t5/Sourcetree/ct-p/sourcetree

Luckily, it was mistake on my side not realizing the option to ignore whitespace was switched on, in Beyopnd Compare, so nothing to report to JIRA.

Share this post


Link to post

I've solved this problem for me by calling Uwe Raabe's Project Magician (Dproj Normalizer for older versions) as an input filter in beyond compare. Not quite as simple as it could be, because it overwrites the input file, but with a little bit of my own magic aka InplaceExeWrapper this works fine.

Share this post


Link to post
59 minutes ago, dummzeuch said:

Not quite as simple as it could be, because it overwrites the input file,

You can specify a different target path with the -o parameter. I know this option is missing in the help.

  • Like 1

Share this post


Link to post
9 hours ago, Vincent Parrett said:

Classic! I can certainly attest to this.. currently researching how to migrate away from confluence for our documentation site.   

Will you share your final choice with us then? ;)

Share this post


Link to post
1 hour ago, Uwe Raabe said:

You can specify a different target path with the -o parameter. I know this option is missing in the help.

Does that also apply to DprojNormalizer?

Share this post


Link to post
1 hour ago, Edwin Yip said:

Will you share your final choice with us then? 😉

Don't hold your breath, I've been looking for a while, don't feel like anything has stood out so far.  

Share this post


Link to post
1 hour ago, dummzeuch said:

Does that also apply to DprojNormalizer?

Yes, it does.

  • Like 1

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×