Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SVN pushing changes

Tags:

svn

I am used to Git and am learning SVN now. In Git you have to add the files, commit the changes, and the push to the repo. In SVN I only found add and commit commands. Does this mean that when you run svn commit the changes are pushed to the server? If not what command do I run to push changes to a repo?

like image 282
Tyler Avatar asked Oct 31 '16 19:10

Tyler


People also ask

Does svn commit push?

Correct, svn commit will push your local modifications to the server. Take a look at the Basic Work Cycle to get a quick-ish overview of the commands you'll typically use.

Is svn better than git?

SVN is better than Git for architecture performance, binary files, and usability. And it may be better for access control and auditability, based on your needs.

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.


1 Answers

Correct, svn commit will push your local modifications to the server. Take a look at the Basic Work Cycle to get a quick-ish overview of the commands you'll typically use.

The "common" pattern is:

  1. update to merge the latest changes from the server into your working copy;
  2. Perform whatever modifications you need to do;
  3. update again to make sure you're up to date (you can skip this and the next step will fail if you're not up to date);
  4. commit to push your changes to the server.

SVN doesn't have a staging area; there's just your working copy and the repository (plus your local pristine, but you only interact with that indirectly when you revert any working copy changes).

As a side note, Git and SVN have an awful set of terminology that can overlap when not expected (see revert and checkout). Check out this resource for some help with that.

like image 90
Patrick Quirk Avatar answered Oct 10 '22 04:10

Patrick Quirk