[ACCEPTED]-SVN checkout filtered by file extension?-svn-checkout
This is possible: you can
svn checkout an empty directory, and 7 then
svn update filename for each file that you do want.
Your 6 script can do something like:
svn checkout svn://path/to/repos/directory --depth empty
svn list --recursive svn://path/to/repos/directory
- Pipe that result through a filter that removes the forbidden file extensions, e.g.
- Iterate over this new filtered list and
svn update --parentseach file
That would 5 give your desired result of a working copy 4 without certain files or file extensions.
Of 3 course, there is also the issue that you 2 mention of “people [checking] in lots of 1 fluff” but that’s a separate matter.
As I told here, there is only one option build 5 into SVN itself: A new feature in SVN 1.5 4 called sparse checkout, however you can only select checkout 3 on directory level, so you have to sort 2 the files you do not need in a different 1 directory.
You can't check out just a few specific 5 files -- you can only check out a whole 4 folder. You can rearrange the organization 3 of what you're checking out, or you can 2 just copy a working copy from somewhere 1 else and update.
I just tried the approach presented by Michael 3 Hackner. Below is the implementation for 2 a DOS system. Note that you have to to checkout 1 the empty folder before running this script.
@echo off svn list --recursive https://path_to_repository_folder | find /I ".sql" > filelist.txt REM Specify a custom delim. Otherwise space in filename will be treated as a delimiter. FOR /F "delims=|" %%i IN (filelist.txt) DO ( echo ------------- echo %%i svn update --parents "%%i" )
More Related questions