Hi,
We currently have a home built web based code review tool that manages a fairly complex workflow. We integrate into Vault via the API which is called through an ASP.Net webapp. This webapp can produce a review page containing a diff of the two versions under review. Obviously the diff is a reasonably part of the app and we'd prefer not be doing this web based diff ourselves. So my eyes lit up when I saw the new Web Diff in Vault. However, when I looked closely at the URLs it uses I saw "Object". For example:-
http://myserver/VaultService/VaultWeb/V ... aseline=29
At review time our code review system has the Vault server name, the repository name, the folders, the file name and the versions. But I can see no way to easily obtain this Object value. Is there a way to call up a web diff without knowing this? It seems the paths etc should be enough information to generate a diff. If there is no way around needing the Object value is there any easily via the web interface? Or as a worst case via the API?
Thanks,
Adam
Using Web Diff Urls
Moderator: SourceGear
Re: Using Web Diff Urls
Unfortunately, you will need the API for this. You will need to get the Repository ID (which is the number prepended to the file's path) and the ObjID. You can get the repository id from ServerOperations.client.ClientInstance.ActiveRepositoryID
For Objid, you'll need to get a VaultClientTreeObject from RepositoryUtil.FindVaultTreeObjectAtReposOrLocalPath
Let me know if you need more help.
For Objid, you'll need to get a VaultClientTreeObject from RepositoryUtil.FindVaultTreeObjectAtReposOrLocalPath
Let me know if you need more help.
Subscribe to the Fortress/Vault blog