I'd like to update all files of a project to an older revision and I'm having a bit of trouble. I was able to pull the older revisions down but I don't know how to turn them into the current revision. I've seen answers on how to do this through the command line but I'm curious if it's possible in Ankh. Thanks!
Open the history viewer, right-click on the revision you want to return to, and choose "Revert to this revision". Alternatively, pick the revision(s) you want to undo (you can multi-select them) and choose "Revert changes from this/these revisions"
Related
TortoiseSVN has a nice feature where I can quickly go back to older versions in the log in my working directory, in order to quickly determine where something went wrong. It is called "Update to revision." I can't find the equivalent in TortoiseGit. Is there such an option?
Go to the log dialog an switch to a different commit.
For that use the contect menu on a comit and select "Switch/checkout to this..." (cf. https://tortoisegit.org/docs/tortoisegit/tgit-dug-showlog.html). This, by default, will create a new branch wich can be deleted afterwards.
If you are searching a revision where a bug got introduced, you should have a look at git bisect, which does a binary search on the revisions in order to find a faulty commit (cf. https://tortoisegit.org/docs/tortoisegit/tgit-dug-bisect.html).
We made a lot of changes to our code and don't want them any more. We would like to roll back these changes to a changeset from a couple of days ago. However, we are having considerable trouble doing so. We have loaded the version we want to use. How do we go about promoting this version to be the Latest Version on the TFS server, so that our other machines can pull it?
Thanks
Open source control explorer, right click on the folder that you want to roll back, and choose the "roll back" option.
I have a Visual Studio solution and am using TFS for version control.
When I've made a bunch of changes to my working copy of the solution, the Team Explorer window will show me all the files that I've changed, and allow me to compare my version with either the workspace (original) version, or the latest version in TFS.
However, before I check in my changes, I first want to integrate any changes that have been made (by other people) to the latest TFS version since I got the source from TFS.
I could do a Get Latest Version and hope for the best. However, I would generally prefer to know what will be changed, and have the opportunity to look in detail at those changes, before overwriting my local files.
Is there a way to either compare my workspace (original) version against the latest version in TFS, or to see what the effects of a "Get" will be before I actually execute it?
To be useful, this would have to be a at a solution level - I would not want to have to go through each individual file.
Use Compare... and select Latest Version. That's best executed from the commandline or the Source Control Explorer.
If you compare "Latest Version" (remote) with "Workspace version" (local), then it'll tell you what has changes on the server since the last get-latest.
If you compare "Latest version (remote) with "Latest version" (local), then it'll tell you what has changed both locally and remotely.
The command line is your friend you can use the /preview switch to see what will happen if you do the get
tf get $/MyTeamProject/MySourcePath /recursive /preview
I am in the following situation:
A Team Member worked on a task which was partially done in few changesets, few months back. These changesets were reverted and many more changes are done on same files in subsequent changesets.
I want to get the latest version of code (which I have taken) and have some option to get the older changesets (even I can merge changesets one by one) and merge it.
Though I find option to changeset GetThisVersion which gives me whole old codebase. I don't find relevant option in Visual Studio 2010. It would be great to have GUI option and not command line one.
Please help. Thanks in advance.
You can get specific version of a file from file history (view or get specific version) or with command line Need command to get a file from TFS without a workspace. But to get a folder (project, solution) state seems to be necessary to have a workspace How to get specific version of folder from tfs without creating a workspace?. I don't think that there is a possibility to merge an old and newer version. When I want to resuscitate some old code I use view in history and copy/paste.
I am the only developer of a software project. I did not use any version control until now. I know I can put the last version of the project under version control. The question is whether it is possible to put older versions and branches of the project under version control. If it is possible, how ?
which version control software should I use ? (I am using Visual Studio 2008)
Edit: I have almost all previous versions.
You could do it, assuming you have copies of the older revisions that you want to put into source control (you can't magically make them appear, of course).
What I would do is take the oldest version, put it somewhere, and commit the folder to your source control (this would become Revision 1). Then, take the second-oldest version, overwrite the first version on your hard drive with that, then check in again (this becomes Revision 2 in source control). Repeat, overwriting with the next-newest revision each time until all of the versions you want are checked in.
There are good, free version control systems available. I use SVN (with the TortoiseSVN shell add-on), and I'm quite happy with it. CVS is alright too, but gets very slow as projects get large.
Which VCS you should use is really up to you. I'd recommend Mercurial as it is a very good distributed VCS and runs rather well under Windows. I don't know what VS support but you may want to use a supported VCS (which probably means Subversion I guess). There is TortoiseHg available there as well.
If you have all previous versions, you can import them manually, one after the other to get to the last one then work from that.