简体   繁体   中英

Checking out a subset of Subversion externals

I am in the process of automating my build process in Jenkins for a specific repo. To ensure a clean build, I want to do a fresh checkout before each build.

I have two linked externals in my repo, one that needs to be built every time along with everything else and another that doesn't (it's very large, takes forever to build, and is mostly third-party libraries). Since the large one doesn't need to built every time, I want to find a way to exclude this particular external from the pre-build checkout.

Toward this goal, is there a way to check out a subset of the svn:externals property? I know about the --ignore-externals option, but that only lets you completely ignore all externals.

It would not be difficult to clean a previous checkout and then update, so why not do that? Jenkins even provides a Check-out strategy that does this for you.

Otherwise, think you would need a script that uses the --depth option and multiple commands to build up your working copy. Example:

svn co --depth=empty url://hostname/repos svn up --set-depth=infinity src svn up --set-depth=infinity tests svn up --set-depth=immediates externals svn up --set-depth=infinity externals/lib1

maybe add symlink for lib2 to point to a pre-existing checkout of big external?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM