tags:

views:

86

answers:

3

Is there a way to do a selective commit from command-line?

I would like to commit some, but not all of the modified files. I'm thinking in the lines of parsing the output of svn status.

+2  A: 
svn commit -m 'Fixed bug 1234' file1.c file2.c directory/*.h
Sjoerd
This is handy if there's a few files. And you can't use tab completion on the removed files.
Strudel
A: 
svn commit file1 file2 -m "Message"

Use that

+1  A: 

You could put the files you're working on in a changelist:

Subversion's changelist support allows you to create changelists by applying labels to files you want to be associated with that changelist, remove those labels, and limit the scope of the files on which its subcommands operate to only those bearing a particular label.

This way, you can go about your work, and when you type SVN commands (e.g. svn diff, svn st, svn ci, etc.), you can specify a changelist and only those files in the changelist will be worked on.

William Leara