Vault command line - _sgbak files

If you are having a problem using Vault, post a message here.

Moderator: SourceGear

Post Reply
mmistry
Posts: 2
Joined: Wed Mar 16, 2005 4:42 pm

Vault command line - _sgbak files

Post by mmistry » Wed Mar 16, 2005 4:51 pm

I am using the GET command to retrieve all the latest source files into a working folder. We are using this as an alternative way to back up our latest source files after each labelled release.

Each time I run the command, previously backed up files are placed in the _sgbak folder created under each folder in the repository. Is there a way of preventing this behavior within the vault command line api? Or would I have to write del commands within the batch file to remove them?

Thanks.

dan
Posts: 2448
Joined: Wed Dec 17, 2003 5:03 pm
Location: SourceGear
Contact:

Post by dan » Wed Mar 16, 2005 5:02 pm

Is the folder you are getting to a non-working folder? If so, then they are considered Unknown files, and before overwriting them, they are backed up. A working folder should not have this problem, since we keep state on those working folder files, and know they are the same as some version on the server.

So, if it is to the same non-working folder each time, you would need to delete them after the get, or remove the non-working folder before doing the get.

mmistry
Posts: 2
Joined: Wed Mar 16, 2005 4:42 pm

Vault command line tool - using profiles to authenticate

Post by mmistry » Thu Mar 17, 2005 4:25 pm

Thanks - if I delete the contents of the folder before calling GET, the _sgbak folder is not created.

Another question - is there a way to use profiles to authenticate in the command line? I have a profile set up via the Vault Client GUI which includes the username, password, server and default repository. The ultimate aim is to avoid having to store the password in the batch file...

dan
Posts: 2448
Joined: Wed Dec 17, 2003 5:03 pm
Location: SourceGear
Contact:

Re: Vault command line tool - using profiles to authenticate

Post by dan » Fri Mar 18, 2005 8:26 am

mmistry wrote:
Another question - is there a way to use profiles to authenticate in the command line? I have a profile set up via the Vault Client GUI which includes the username, password, server and default repository. The ultimate aim is to avoid having to store the password in the batch file...
No, but that is a good idea. Alternatively, you can use the "rememberlogin" command to store the connection info in a different file somewhere other than the batch file.

Post Reply