How can I view a list of all files with conflicts in a Tortoise SVN Repository? - tortoisesvn

Is there any way to get a list of files that are in a (SVN) conflicted state using Tortoise SVN?

To do this, right-click on the folder containing the conflicts you wish to see, then click Resolve....
Note that this is something of a side-effect, since this option is (generally) for marking conflicts as resolved. It is also, however, intended to help you actually find and resolve the conflicts. The behavior is as follows:
A window will appear that lists all the file conflicts, with check-boxes next to them. If you double-click on a file name, Tortoise will bring up the Merge window for that file. When you've selected the files you want to mark as resolved (using the check-boxes), you can do so by clicking "Ok," or you can simply exit the window without changing the resolution status of any conflicts by clicking "Cancel."

You can't do it with TSVN, but it's rather easy for CLI-interface.
Just use svn status inside your WC and check output:
The first seven columns in the output are each one character wide:
First column: Says if item was added, deleted, or otherwise changed
...
'C' Conflicted

Inside "Check for modifications" theres another button...
... "check repository" it will show conflicts
This is my source

Related

Is there a way prevent TortoiseSVN from "forgetting" the selected files when a commit fails?

My problem is this:
Basically if I try to commit a change to SVN and the commit fails then all the files I have selected are lost or forgotten and I have to go back through and choose the ones I want to commit again.
This is hugely annoying and I've not been able to find a solution to it.
So, is there any way that I can get TortoiseSVN to return to the state it was in just prior to when I pressed OK? i.e. all my selected files and comment are restored.
I know I can get the comment back using the Recent Messages button so it would be really handy if I could also do something similar to get the file list state back to what I had too.
For TortoiseSVN 1.6:
Settings-Dialog->Dialogs 2->Reopen commit and branch/tag dialog after a commit failed
in TSVN 1.7, that option is enabled by default, and only available as Settings->Advanced->OutOfDateRetry
If that is something that happens often to you, you could use change lists in TortoiseSVN. It works like that:
You check for modifications in your files by using the menu entry TortoiseSVN > Check for modifications.
In that dialog, you select the files you want to commit together, and select from the context menu Move to change list > <new changelist>.
You enter the name of the change list and accept it.
In you commit dialog, you see now the files grouped by change list, so if anything goes wrong, that information is kept then.
If you change the same files again and again, you may check the check box Keep changelists so that you may use the change list for your next commits.

"Show In - Explorer" with multiple files?

Here's a frequent situation: You have about thirty files checked out into a specific pending change-list. After working on those files, and before submitting them, you needed to move them to a folder (external to deposits, so a simple "Integrate" wouldn't be suitable).
Using the "Show In - Explorer" option, you'll get a lot of window popped-up. And that's just painful (and sometimes, the system just cannot open all of them).
So, question is, is there a simple way to copy-paste multiple files from a change-list without doing it individually?
You can do this with a custom tool.
In P4V, open the custom tools manager via the Tools->Manage Custom Tools... menu item
Click New->Tool... to open the Add Custom Tool dialog and enter these parameters (xcopy isn't the ideal app for this, but I'll talk about that later1)
alt text http://img202.imageshack.us/img202/6678/p4editcustomtool.png
Now you will be able to select all the files in your change list, right click on them, and a new item will be available in the context menu Copy selected files to another location..."
alt text http://img97.imageshack.us/img97/4003/p4vcustomtoolincontextm.png
An input box will appear, asking you where you wish to copy the files.
alt text http://img132.imageshack.us/img132/7612/p4locationprompt.png
Click OK and the files will be copied to the location you entered in the input dialog. Maybe...
1There are some problems with xcopy:
the target directory must already exist
it doesn't seem to work if the path contains spaces
if the process fails, you're process list will fill up with a bunch of instances of xcopy.exe that are stuck trying to do who knows what
the custom tool will no longer work if the previous condition occurs
I tried robocopy also, which would be perfect if there was a way to pass it the source directory, but P4V custom tool editor doesn't provide the parent directory as a parameter. Ideally, you should write your own file copy utility, if this is really important to you. It wouldn't require that much effort.
Lastly, the P4V custom tool editor offers a file browser, but not a folder browser, and the latter is what you really need for a tool such as this.
So, play around with the custom tool thing. You might be able to come up with an answer to your problem.
I know you want to do these things outside of Perforce, but the best I can think of is if you create another workspace specifically for exporting files. You can sync your Perforce workspace to contain only the files in a particular changelist.
In this workspace, try giving the files in your changelist, after it is submitted, a particular label. If you sync your workspace to this label, it will delete every file that does not have this label based on this Perforce page. (do Find for label in that page)
p4 sync #label_name
This involves Perforce, but it does provide a way to get only the files you want.
I believe you can also accomplish this only using changelist numbers, but it may be more complicated. I'm not 100% sure this works
p4 sync #none
p4 sync #changelist,#changelist
I think this will sync files only in this changelist.

Perforce changelist does not show any files

Using P4V 2009.2.
I have used P4Win in the past, but this is a new setup for me.
The problem is that the files I have checked out disappear from the changelists, so I cannot check them in.
To reproduce:
Check out a file, make a change to it.
Go to the 'pending changelist' tab.
There will be a + sign on the default changelist.
Click on the plus, or on the changelist line, the plus will disappear, there will be nothing in the changelist.
Try to check the file in by right-click on the file itself, the changelist dialog will show up but NO files are listed.
You can transfer the file to a new changelist, the same thing happens.
Looking at the file in the 'checked out by' window does correctly show the changelist number & description.
It sometimes happens to me, and what I normally do is change workspace and then change back again. Not sure if there is an easier way to get it to realise the files are checked out.
the only thing I can imagine is that you are looking at a different client workspace. Notice that the "Pending Changes" tab has a filter on the top, where you can separately filter for folder/files, user and workspace. Maybe the filter is set to something so that it doesn't match the client workspace where you have actually checked out the file.
Good luck,
Henrik
You may get this if the perforce server has not been upgraded. Old versions of P4D have this error: http://kb.perforce.com/article/1167/opened-files-missing-in-default-changelist
If that is not an option, use p4Win.
I agree with jhwist,sounds like your looking at a different client spec.
P4V is a bit confusing on this front, IMO and I personally prefer P4 Win but to check, open up a command prompt and type p4 changes -s pending -c YOURCLIENTSPEC - chances are that the changes you think you have aren't in your current clientspec
This can happen sometimes and in my experience it is a refresh issue with p4v. Often simply closing the pending tab or reopening p4v solves the problem.
In my case, the pending List has over 4000 files, (due to eclipse created so many files after mvn tasks) so none of them are shown. I created a different pending list, then cleared all contents, then moved the files to the new change list. Then it is appearing in the new change list.
Modify the file directly in the correctly mapped client folder (i.e. your current workspace). You will see the changelist for sure. As jhwist mentioned clear filters if any and choose your current workspace (since you may have many)

Tortoise svn adding <<<< to files!

My problem is that whenever I update a folder via tortoise svn I get the files that were edited and now different from revision 1 to revision 2, SVN adds a "<<<<<<" to places that were affected.
Can anyone please provide some sort of solution?
These markers indicate where there have been conflicting changes between what you have changed and what somebody else has changed. The SVN Book has a section on merging which shows you what to expect. The book talks about the command line commands but the workflow for TortoiseSVN is similar.
See in particular the section titled "Merging conflicts by hand".
This lines are inserted by the default tortoise merge program.
If you change the default program to see the file differences you will not see this ugly <<<<<mine anymore. Use for example Winmerge
To use winmerge for file changes do the following:
Right click on a versioned folder and select Tortoise SVN->Settings
In External Programs->Diff Viewer section you can set the program you want to see file diffs. Select winmerger or you prefered.

I'd like to have a clear report of non-updated files (because of conflicts) during a perforce update

When I do an update and zillions of files are updated, I often miss the one that aren't merged because of conflicts. The only way I have is to go through all my changelists and look at file icons.
Isn't there a nicer way ? even a console based command would do...
You could immediately do an update again, which this time would just print out the conflicts. If you are using p4v, make sure you have the log showing, as the results should scroll through there.
From the command line,
p4 resolve -n
will list each file with unresolved conflicts.
In p4v, you can right-click on the root of your depot or workspace and select "Resolve" to get a window where you can resolve conflicts interactively.

Resources