I have a scheduled task setup that needs to run as the System account.
The scheduled taks gets latest version of files in a project and then attempts to checkout a file. I get an error message but the file actually shows up as checked out. i believe I am getting the error because the sytem account does not have any vault working folders setup. I can't understand why it has no problem getting latest version of files though.
Here is the command that the task uses:
'C:\Program Files\SourceGear\Vault Client\vault.exe' -host pbiwww2 -user $usernamegoeshere$ -password $passwordgoeshere$ -repository Development checkout $/WebSolutions/PBISolutions/PBI-WGSolution/Website/AssemblyInfo.cs -setfiletime modification -merge overwrite -commit
Here is the error message that I get:
Object reference not set to an instance of an object. System.NullReferenceException: Object reference not set to an instance of an object. at VaultClientOperationsLib.WorkingFolder.GetHashedPathName(String path) at VaultClientOperationsLib.WorkingFolder.HasWorkingFolderData(String diskFolderPath, Boolean lookInWorkingFolder, TreeCache treeCache) at VaultClientOperationsLib.ClientInstance.CreateGetFileRequests(VaultClientFile[] files, Boolean forceLatest, Boolean forceDisplayVersion, Boolean dontCheckWorkingFolders, MakeWritableType makeWritable, Boolean isLabelGet, String labelSubItemPath, Boolean isLabelGetForSingleFile) at VaultClientOperationsLib.ClientInstance.Get(VaultClientFile[] files, Boolean forceLatest, MakeWritableType makeWritable, SetFileTimeType setFileTime, MergeType merge, OverwritePrompt PromptData) at VaultClientOperationsLib.ClientInstance.Get(VaultClientFile file, Boolean forceLatest, MakeWritableType makeWritable, SetFileTimeType setFileTime, MergeType merge, OverwritePrompt PromptData) at VaultCmdLineClient.VaultCmdLineClient.ProcessCommandCheckout(ArrayList strItemArray) at VaultCmdLineClient.VaultCmdLineClient.ProcessCommand(Args curArg) at VaultCmdLineClient.VaultCmdLineClient.Main(String[] args) Process completed with exit code -1
The file still shows up in vault as checked out though. How can I configure this to work with the sytem account?
System Account abd Checkout
Moderator: SourceGear
jnapier,
The problem is a different flavor of the usual Command line problem where no working folder has been set. Check out this KB article.
http://support.sourcegear.com/viewtopic.php?t=225
The problem is a different flavor of the usual Command line problem where no working folder has been set. Check out this KB article.
http://support.sourcegear.com/viewtopic.php?t=225