I'm switching to subversion from git but I found that "svn add ." doesn't do the same as git.
It prints
svn: warning: W150002: '/home/mike/Projects/repos' is already under version control
svn: E200009: Could not add all targets because some targets are already versioned
svn: E200009: Illegal target for the requested operation
Does SVN have an equivalent? Or I must add them manually?
svn add adds an item (file or directory) to a local working copy. svn add is a local operation and does not contact server. No changes made to a repository when you run svn add . It simply schedules and item to be committed to a repository next time your run svn commit .
An equivalent of "svn update" would be "git pull --rebase".
git clone is more of an analogue to svn checkout than git checkout . git checkout just checks out a branch or commit from your local repository. git clone makes a new copy of a remote repository. Save this answer.
The svn add
and git add
commands do different things. The git add
command is used to submit any change to any file (including new files) to the Git index, in preparation for a subsequent commit.
The svn add
command is only used to add new files to the repository, when preparing for a commit. Changed files are submitted using the svn commit
command, and do not need to be added first.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With