I'm trying to compare two versions of a VBA file which are placed on a TFS. The Diff Tool shows several changes, but there actually are none.
♪And they don't stop coming...
In fact, VS tries to beautify the code by changing it's case despite the fact that I turned the Pretty Listing feature off.
Example
Well, I've disabled literally EVERYTHING here
Note: VS does not change the files either on disk or TFS.
The question is how to make it stop. I can't find real changes when comparing files.
Microsoft Visual Studio Community 2019
Version 16.4.6
Related
I work on a team that uses Ryder. I want to use Visual Studio 2022.
When I open the solution, Visual Studio makes a bunch of changes to the solution file (it modifies one of the project guids and adds debugging information for it).
I'm not allowed to check in these changes, nor are they needed, so every time I check anything in to git, I have to undo the changes to the solution file.
Is there any way to disable Visual Studio 2022 from doing this?
I've searched every setting I could think of and read the documentation but I can't find anything. I don't want Visual Studio to change my solution file if I haven't added or removed projects.
Though not exactly a "fix", I have a workaround that's been quite helpful from time to time. Copy the .sln file so you have a second one with a different filename. Let VS do what it wants to that second .sln without affecting the first one. You can take it one step further and gitignore the second file so that git will not constantly want to 'add' it to the repo.
I never did find a solution for this. I run a script every time I check in to undo the change to the solution file.
I am the only one on the team using Visual Studio and the team has strict rules about can be committed so this is the only solution.
It's not a problem now that I'm used to it, and I love Visual Studio 2022 so I'm willing to put up with it.
I have a problem in Visual Studio 2013 (Update 5), when opening a project development on another machine, using the same version, Visual Studio marks all the files as containing differences, however when checking each file "Compare with Unmodified ", all files are blank, meaning no difference whatsoever.
If I select the "Undo" option in the project, close the project and open it again the problem does not happen.
The big problem is when I actually get changes made in my project, checking file by file will stretch a great deal of time.
Has anyone ever had a problem like this?
There are a few things I know that can cause this behavior:
Your machine and/or the TFS Server is configured to enforce FIPS compliance which invalidates the hashing algorithm used to calculate differences. If this is the case, then all machines connecting to the TFS server and the server itself must be configured to enforce FIPS compliance, otherwise the hashes will be out of sync and all files will be marked changed.
There are whitespace changes, some plugin may be changing all line-endings from windows to linux or vice versa. Or doing the same with tabs and spaces. Your diff settings may be ignoring whitespace differences, so even though the files are different, they're the same according to the merge tool. You can configure whitespace checking using the = button on the diff toolbar.
You're using server workspaces and something or someone has removed the read-only bit from your files. Choosing "Go Offline" and then "Go Online" from the File -> Source Control menu should trigger a full compare of your local version against the server to restore sanity.
As a workaround, you can select "Undo Unchanged" from the Source Control Explorer or from the commandline (if you have the Visual Studio TFS Power Tools 2015 installed).
I was wondering if there is a way for Visual Studio's built-in search to only look in files that have been modified in a certain time frame.
I think it would be very convenient, especially when working with a large codebase where you don't really need to search for certain things in ancient code (or even code older than, say a month, even a week).
No. Not in Visual Studio 2010. Also not in Visual Studio 2012 (which includes the Quick Find feature from the Productivity Power Tools extension.)
You'll probably need to make do with Windows Search or a third party tool like Agent Ransack.
I just had Visual Studio fail on a commit due to a merge conflict and when I was done I had about 10 files that it thought were checked in that in reality never made it to TFS.
I ended up having to compare every file I might have changed and adding a single space to the ones I did... quite tedious. I'm wondering if anyone knows of a way to tell which files have been changed in this situation?
Visual Studio will recheck all files when you change from offline mode to online.
If you don't mind losing the changes, you can also just re-checkout everything with the option to overwrite files enabled.
I've been developing a project for a while, and we have started a "documentation" folder in the Visual Studio 2008 solution so that we can keep the developer documentation (and a few other useful files) in there (it's one of Visual Studio's solution folders, rather than a project). We're also using the AnkhSVN plugin so these files get copied to Subversion.
However, every time I save any of the files, Visual Studio automatically removes it from the solution, so I have to add it back in,and then close Word again without saving.
I'd have thought this was a fairly easy problem to solve, but the past three weeks (and reading many spurious results on Google for almost every search query I can think of that might be relevant) seem to have proved me wrong.
Does anyone have any ideas how to stop this behaviour?
I don't know if this still happens with VS2013, but for VS2010 here is a detailed explanation on the cause and a work-around:
Word files disappear from "Solution Items" in VS2010
Are you sure the files are removed and not just hidden? I had a similar thing with non-code files.
Showing and Hiding Hidden Files in Visual Studio 2008