views:

71

answers:

2

Hello everybody

We are having trouble with having a generalized approach to committing with a batch file using commandline svn.

We've got a backupscript that created a new folder with the current date containing the database dumps of our database. (Yes, we version control our database).

Now how can I use the svn commit command to include all directories that are new in the project?

Is there an approach without using the svn add command?`

Thanks for all advice!

A: 

No. You must svn add files before you can commit them.

You could use wildcards, or have your script construct a list of what's to be added, which can then be passed to the --targets option.

Michael Hackner
+3  A: 

svn add --force . will add all the files and directories below your current working directory that aren't added yet (And aren't ignored) to your working copy.

A svn ci will then handle the commit.

The only way without 'svn add' would be to use 'svn import', but this assumes a new location.

Bert Huijben
Here is a link to the relevant documentation: http://svnbook.red-bean.com/en/1.5/svn.ref.svn.c.add.html
ChrisH
thank you, works like a charm!
Shaharyar