Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to add content to an SVN directory without checking out its contents?

Tags:

svn

Today I needed to add two Android projects to our Subversion repository but I had a problem. The directory in the repository already contained a lot of projects and I didn't want to checkout all of them. Is it possible add two directories to that directory without checking out everything?

like image 526
Henrique Rocha Avatar asked Sep 14 '11 23:09

Henrique Rocha


People also ask

How do I add something to svn?

Adding a File or Directory To add an existing file to a Subversion repository and put it under revision control, change to the directory with its working copy and run the following command: svn add file… Similarly, to add a directory and all files that are in it, type: svn add directory…

How remove checked out folder from svn?

Just delete your complete local checked-out working copy (including all . svn directories). This will not modify your repository as you are not committing your deletion.

How do you svn checkout a folder?

So we right-click on this folder and select 'SVN Checkout…' From here we'll specify the location of the repository that we want to check our files out from. So something like… If you've forgotten what this URL is then you can go back to the VisualSVN server app and right click to select 'Copy URL to Clipboard'.


1 Answers

You can simply import the new stuff right into the repository without any working copy:

svn import INSTALL.txt $SVN_REPO/trunk/proj1/INSTALL.txt

Works with directories (aka. "projects") also.

svn import proj2 $SVN_REPO/trunk/proj2

After importing you must checkout the stuff in order to continue your work:

rm -rf proj2/*
svn co $SVN_REPO/trunk/proj2 proj2
like image 154
A.H. Avatar answered Oct 11 '22 20:10

A.H.