Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SVN Commit without update

Tags:

merge

commit

svn

My coworker has checked in a few files that I know are wrong. I would like to be able to replace them and commit my local older copies back to the repo. However, SVN doesn't allow me to commit these files without me running update.

I am worried that this may cause automatic merge and messe up my local "good" copies. I

Is there anyway that I can commit my versions without updating? Non-automatic merge is highly discouraged. What is the alternative?

like image 698
Ari Avatar asked Jun 06 '12 19:06

Ari


People also ask

What is difference between commit and update in svn?

Commit uploads your changes on the CVS / SVN server, and Update overwrites the files on your localhost with the ones on the server.

How do I commit changes in svn?

Select any file and/or folders you want to commit, then TortoiseSVN → Commit.... The commit dialog will show you every changed file, including added, deleted and unversioned files. If you don't want a changed file to be committed, just uncheck that file.

How do I commit a directory in svn?

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 -m "" will then handle the commit. The only way without 'svn add' would be to use 'svn import', but this assumes a new location.


2 Answers

Copy your modified files off to the side, update, copy your modified files back, commit.

like image 105
Ernest Friedman-Hill Avatar answered Sep 17 '22 04:09

Ernest Friedman-Hill


If you have the right rights you can go in and remove the invalid files from the repo. Check out the command line docs here.

like image 44
AlG Avatar answered Sep 19 '22 04:09

AlG