Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

By "every change" I mean TortoiseSVN's "Commit" button.
It removes the deleted files, adds new ones, and commit the changes.
At least these are the ones I know of, but there may be others as well.
(I just press "All" and push Commit in Tortoise.)

RabbitVCS is available for Linux, but the cli version's commit == svn commit.
Is there a small script or something that could imitate Tortoise's commit?

Environment is Linux with bash prompt. (SVN 1.7.5)

share|improve this question
RabbitVCS seems to work now, but I'm still interested in a shell script that would do the work. – Shiki Apr 3 '13 at 0:18
up vote 0 down vote accepted

Go to the root of your working directory.

svn add . --force

(This recursively traverses your working directory and does an svn add on every file it finds that is not already under version control.)

Next do this:

svn rm $( svn status | sed -e '/^!/!d' -e 's/^!//' )

(This runs svn status. The status command recursively gives a list of everything that has changed in the working directory. The weird sed command finds all the lines starting with "!" (which is how svn status indicates a deleted file.))

Now do:

svn commit

Not that I really advise doing this. It would be preferable to just use "svn rm oldfile" instead of "rm oldfile" as you are doing your modifications. The "svn add . --force" isn't so great either: it's going to check in all the temporary files and object files that you generate while testing. It would be better to just "svn add newfile" when you care about adding a new file.

I typically run "svn status -u" before every checkin to get a clear picture of what has changed in my working copy.

I found the answer for the svn rm part at:, which in turn credits

share|improve this answer
Thank you! Well, Tortoise and Rabbit basically commit every change (updates, new files, deletions) if you choose to do so. For continuous backup, I use Dropbox. But having SVN is good stuff. – Shiki Apr 4 '13 at 22:50

I Use & Schedule This Batch Script . It Working Well.

CD "MyPath"

for /f "usebackq tokens=2*" %%i in (`svn status ^| findstr /R "^\!"`) do (svn del "%%i %%j")

svn add * --depth=infinity --force 

svn commit . -m "My Message"
share|improve this answer
The question is tagged Linux but this answer applies to Windows. – Kevin Panko Apr 15 '14 at 14:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .