Copying a versioned directory

I am curious whether it is correct to copy the directory under version control and start working on both copies.

I know that it may differ from one VCS to another, but I intentionally do not specify any VCS, as I am curious about different cases.

I recently spoke with a colleague on how to do this in SVN. I think that everything should be fine, but I'm still not 100% sure, since I do not know what exactly SVN stores in a working copy.

However, if we talk about the world of DVCS, things may be even more obscure, since each working copy is a repository in itself. Now, faced with this in bzr, I decided to ask a question.

Next edit:

Some people asked why I would like to do this. Here is the whole story:

In the case of SVN, this was because, due to the office, the connection to the SVN server was very slow, so my colleague and I decided to check the sources only once and make a local copy. This is what we did, and it worked fine, but I'm still wondering if this is guaranteed to work, or if it just happened.

In the case of bzr, I plan to move the "main" repo to another server. So I thought to just copy it there and start counting that main repo. I think the safest thing is to make a clone, though.

+3
source share
10 answers

Subversion .svn , . , . .

, / , "" . , - - , .

, , . .svn-, , .

+6

SVN, . , SVN , , , .

, , .

  • File1 Copy1 File2 Copy2 ,
  • File1 Copy1 , File1 Copy2 , , , /.

, , , , , . , , , .

+3

svn . , .

. .svn, svn .

+3

bzr, .bzr , . , , .

+2

, , .

, , ""?

0

( , SVN), work/copy1 work/copy2 .

, , .

0

VCS. CVS, () , . , , .

, , rsync (-C), , CVS.

0

SVN, Visual Studio. , , , .svn. , .svn , . SVN clean up , . SVN switch . , .svn , .

, , SVN . , , diff .

SVN svn //, . Visual Studio. , , TortoiseSVN.

0

SVN , .

, , , . , SVN URL- ://, , , . URL http:// svn://, .

To stay safe, I just wanted to check in a new place. If there are many unspecified changes in the new working directory (this is usually a bad idea), you can use rsync to copy the source code without adding the .svn directories.

0
source

It seems to me that GIT can also satisfy your needs, as you mention that you are disconnected or in a crappy connection. GIT also has very good support for SVN, so they complement each other and you get a good file system with a version.

-2
source

Source: https://habr.com/ru/post/1696805/


All Articles