Is there a way to ignore changes of just one file?

If you are having a problem using Vault, post a message here.

Moderator: SourceGear

Post Reply
draza
Posts: 9
Joined: Sun Oct 31, 2004 10:02 am

Is there a way to ignore changes of just one file?

Post by draza » Wed Dec 01, 2004 3:49 am

Here's the deal:
every Visual Studio project has at least one extra file besides the project file itself (regardles of kind of project, VB.NET, C#, Managed C++). Projects are usually named <ProjectName>.<lang>proj where <lang> is vb|cs|vc. There is a file named the same as project file + extension ".user". Settings stored there are relatively important and not recreatable automatically from other files so I decided to keep these files in Vault.

The problem is Visual Studio "touches" these files (yyy.user) all the time, but nothing is changed (not even whitespace). Still, Vault marks these files as changed (it can't know what's going on, of course).

Sometimes I will actually do some meaningful changes to these files, and at those times I will most likely want to check-in changes. But the rest 99% of the time, I'd like Vault to ignore those fake changes and not show these files in the changeset because they obscure my view and it is hard to see files that have really been changed.

So I looked for something to help me and pinning looked like a solution. However, when I pin the file, it is still shown in the changeset as changed which is exactly what I'm trying to avoid.

Is there a way to tell Vault to ignore changes for a partcular file until I say so? Something simple as on/off ignore changes?

dan
Posts: 2448
Joined: Wed Dec 17, 2003 5:03 pm
Location: SourceGear
Contact:

Post by dan » Wed Dec 01, 2004 9:22 am

The only way to do this right now is to require checkout before checkin. Then a changed file will show up as "Renegade", and will not appear in the pending change set. However, then you miss out on Vault automatically determining which files you have modified.

Another thought is to store the .user file in a subfolder in Vault, and then copy it to project folder on your local disk. Then your changes are not being made in your working folder.

Neither of these are great solutions. We have thought in the past that being able to exclude modified files from the pending change set would be a good feature, but no one else has asked for it until now. It would not be trivial as we would have to decided when the file is allowed to come back to the change set (probably when it gets modified again), but then that requires storing a lot of extra state info.

In any case, we'll add your vote to the feature, and thanks for the feedback.

draza
Posts: 9
Joined: Sun Oct 31, 2004 10:02 am

Temporarily hiding some files from the changeset

Post by draza » Wed Dec 01, 2004 12:11 pm

dan wrote:The only way to do this right now is to require checkout before checkin. Then a changed file will show up as "Renegade", and will not appear in the pending change set. However, then you miss out on Vault automatically determining which files you have modified.
Ah, yes, I forgot to mention that I am using CVS style so required checkout is not an option. I also forgot to mention that I am using 2.0.6.
Another thought is to store the .user file in a subfolder in Vault, and then copy it to project folder on your local disk. Then your changes are not being made in your working folder.
In that case I'd rather let Visual Studio create a default version of .user file, loose those few settings I keep in there and then I'll just manually add them. It is annoying, but only if I either accidentally delete the file or do a fresh checkout.

If you really want a hackish solution, I just thought of one - I might delete the file (not permanently) and then just resurrect it when I really want to change it, do the change, commit, and then delete again :)
Neither of these are great solutions. We have thought in the past that being able to exclude modified files from the pending change set would be a good feature, but no one else has asked for it until now. It would not be trivial as we would have to decided when the file is allowed to come back to the change set (probably when it gets modified again), but then that requires storing a lot of extra state info.
I would not propose any kind of automatic return to change set as it would be complicated as you mention. I was thinking more along the lines of how pin works - you have to unpin explicitly, by hand.
Another good solution might be filtering out the contents of the changeset based on a list of filemasks like "*.user;pro??.bmp" which would filter (not show changes made to) all files with extension "user" and all files where name starts with "pro" then followed by two characters with extension "bmp".
In any case, we'll add your vote to the feature, and thanks for the feedback.
Thank you for being very fast and responsive regarding my inquiries.

icnocop
Posts: 46
Joined: Wed Aug 18, 2004 12:41 pm

Re: Is there a way to ignore changes of just one file?

Post by icnocop » Tue Jun 02, 2009 1:58 am

Please add my vote for this feature.

I would like to exclude entire folders (ex. bin, Release, etc.) and also files (ex. AssemblyInfo.cs, *.dll, *.exe, etc.)

Thank you very much.

Beth
Posts: 8550
Joined: Wed Jun 21, 2006 8:24 pm
Location: SourceGear
Contact:

Re: Is there a way to ignore changes of just one file?

Post by Beth » Tue Jun 09, 2009 7:33 am

If you are using the Classic Client, then in some projects you will receive an option to Exclude from Source Control. That option would show up in the right-click menu. If you are using the Enhanced Client, then I have a feature request open to add that same functionality to that client as well. Are you using the Enhanced Client by any chance?
Beth Kieler
SourceGear Technical Support

icnocop
Posts: 46
Joined: Wed Aug 18, 2004 12:41 pm

Re: Is there a way to ignore changes of just one file?

Post by icnocop » Tue Jun 09, 2009 3:31 pm

I am using SourceGear Vault stand-alone GUI Client (not integrated with Visual Studio).

In the GUI client I have the option to cloak a folder, but I don't have this option on a file level.

Beth
Posts: 8550
Joined: Wed Jun 21, 2006 8:24 pm
Location: SourceGear
Contact:

Re: Is there a way to ignore changes of just one file?

Post by Beth » Tue Jun 09, 2009 3:40 pm

So you want to ignore changes of a file that is already in Vault? Or can you explain further what you need? It appears to be different than the original post, plus, some things have changed since the original post.

One can have things ignored for putting them into Vault the first time when using the GUI client by using the Exclude File and Folder types in the Vault admin web page. That is a repository setting.

The cloak will only make a different when downloading from Vault.
Beth Kieler
SourceGear Technical Support

icnocop
Posts: 46
Joined: Wed Aug 18, 2004 12:41 pm

Re: Is there a way to ignore changes of just one file?

Post by icnocop » Tue Jun 09, 2009 5:25 pm

Right, I want to ignore changes of a file that is already in Vault.

If I download a folder from Vault, cloak it, and then make local changes to files in that folder, the changed files do not appear in the pending change set and I would like to apply that effect on specific files as well (so they don't show up in the pending changeset).

Thank you.

Beth
Posts: 8550
Joined: Wed Jun 21, 2006 8:24 pm
Location: SourceGear
Contact:

Re: Is there a way to ignore changes of just one file?

Post by Beth » Mon Sep 21, 2009 3:52 pm

I found a feature request that asked for the same thing, so I have added a "vote" for you to that feature request.

F: 8718
Beth Kieler
SourceGear Technical Support

Post Reply