Command line client GET -workingfolder
Moderator: SourceGear
Command line client GET -workingfolder
What is the difference between doing a command line GET with -workingfolder and with -nonworkingfolder?
Re: Command line client GET -workingfolder
The cache watches the working folder and not the non working folder. When something is in a working folder, it is watched for changes and a status can be determined.
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: Command line client GET -workingfolder
I don't seem able to check in a file got with -workingfolder unless I get it to the working folder which was set earlier, and the docs do say "The working folder specified is temporary, used only for this get request", so I don't understand what it's doing.
Re: Command line client GET -workingfolder
Was the item checked out to a different path? You can only check in from the same path an item was checked out to.
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: Command line client GET -workingfolder
The file wasn't checked out -- I have "Require Check Out before Check In" unchecked. If I GET the file to the working folder I can commit it whether I use -workingfolder or -nonworkingfolder. If I GET the file to somewhere else I can't commit it whether I use -workingfolder or -nonworkingfolder, so I can't see the difference.
Re: Command line client GET -workingfolder
The is no way to check in from a nonworking folder.
Are you using check outs, or do you work in CVS mode?
What are you trying to accomplish?
Are you using check outs, or do you work in CVS mode?
What are you trying to accomplish?
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: Command line client GET -workingfolder
We work in CVS mode.
I have written a script which gets a file, modifies it, and checks it in. This script can be run by any user, so all users have to have the working folder set to the same path so the script knows where the file to modify is. I came across the options -workingfolder and -nonworkingfolder, and couldn't find any practical difference between them, hence my question.
I have written a script which gets a file, modifies it, and checks it in. This script can be run by any user, so all users have to have the working folder set to the same path so the script knows where the file to modify is. I came across the options -workingfolder and -nonworkingfolder, and couldn't find any practical difference between them, hence my question.
Re: Command line client GET -workingfolder
If the users use the Vault GUI client as well, they won't see the -workingfolder switch do anything to their working folder that was set in the Vault GUI client.
Only working folders can be compared to the baseline tracked by Vault, and only from a working folder can a check in be made.
Only working folders can be compared to the baseline tracked by Vault, and only from a working folder can a check in be made.
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: Command line client GET -workingfolder
So if I use -workingfolder to get a file to a location which is not the working folder set in the GUI client, can I then change the file and check it in?
Re: Command line client GET -workingfolder
You *should* be able to check it in from the command line, but not the Vault GUI client. The command line doesn't change the working folder in the Vault GUI client.
If you're running into a case where it isn't, let me know.
If you're running into a case where it isn't, let me know.
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: Command line client GET -workingfolder
I don't seem to be able to get it to work.
I then modify the file, and...
and the commit has no effect. What should I be doing?
Code: Select all
D:\>vault GET -repository "test" -makewritable -merge overwrite -workingfolder "D:/vault test2" "$/Playground2/other/File2.txt"
<vault>
<result>
<success>True</success>
</result>
</vault>
Code: Select all
D:\>vault COMMIT -repository "test" -comment "something" "$/Playground2/other/File2.txt"
<vault>
<changeset />
<result>
<success>True</success>
</result>
</vault>
Re: Command line client GET -workingfolder
Try the CHECKIN command instead of COMMIT.
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: Command line client GET -workingfolder
That doesn't seem to make a difference.
Re: Command line client GET -workingfolder
I ran a few tests and I can see where there appears to be a conflict between trying to have the CLC edit and check in from a different working folder than the Vault GUI client has set. I will get a bug logged on this.
In the meantime, you will need to have the script edit in the same working folder the users have set.
If you remove the workingfolder switch entirely, it should just use what is set in the Vault GUI client.
F: 15904
In the meantime, you will need to have the script edit in the same working folder the users have set.
If you remove the workingfolder switch entirely, it should just use what is set in the Vault GUI client.
F: 15904
Beth Kieler
SourceGear Technical Support
SourceGear Technical Support
Re: Command line client GET -workingfolder
Ok, that's what we're doing. It means everyone must have the same working folder set, but that's not really an inconvenience, because we like to have everyone use the same path for other reasons anyway. Unless there's a way to find out the current working folder for a given file?