简体   繁体   English

如何从SVN存储库结帐中排除文件夹?

[英]How do i exclude a folder from SVN Repository Checkout?

How do i exclude Jenkins CI to exclude a folder from SVN checkout? 如何排除Jenkins CI以从SVN结帐中排除文件夹?

I tried the "Exclude Regions" but is not working, am i doing it the correct way? 我试过“排除区域”但是没有用,我是按照正确的方式做的吗?

Screenshot of my setting on Jenkins: 我在Jenkins上设置的屏幕截图: 詹金斯设置

I too was looking for a solution for the same. 我也在寻找同样的解决方案。 The only one I could find was to instead add each folder under your repo (ie, trunk/source, trunk/docs ..etc) as a different Module (Repository url) using the "Add more locations" option. 我唯一能找到的是使用“添加更多位置”选项将您的仓库下的每个文件夹(即主干/源,主干/文档..等)添加为不同的模块(存储库URL)。

Jenkins will then check for updates to all these folders before triggerign a build. 然后Jenkins将在触发构建之前检查所有这些文件夹的更新。

Obviously this option helps if you have less number of folders under your project trunk. 显然,如果项目主干下的文件夹数量较少,此选项会有所帮助。

Cheers, 干杯,

Excluded regions are excluded from triggering builds, not from checkout (eg you might not want to trigger a build just because the documentation changed) 排除的区域被排除在触发构建之外,而不是从结帐中排除(例如,您可能不希望仅因为文档更改而触发构建)

If set, and Jenkins is set to poll for changes, Jenkins will ignore any files and/or folders in this list when determining if a build needs to be triggered. 如果设置,并且Jenkins设置为轮询更改,Jenkins将在确定是否需要触发构建时忽略此列表中的所有文件和/或文件夹。

afaict you can't do that directly in jenkins (still). 你不能直接在詹金斯(仍然)那样做。 But you might use multiple modules now so you could use a whitelisting: 但是您现在可以使用多个模块,因此您可以使用白名单:

url: http://svn/root/project/trunk
repository depth: files

url: http://svn/root/project/trunk/dirA
repository depth: infinity

url: http://svn/root/project/trunk/dirB
repository depth: infinity

url: http://svn/root/project/trunk/dirC
repository depth: infinity

Which will skip all directories that are not dirA , dirB or dirC and will include all files from the the root project. 这将跳过所有不是dirAdirBdirC ,并将包含根项目中的所有文件。

它的名字可能会说它从结帐中排除了一些文件,但是阅读了帮助:它是不会触发项目自动构建的文件列表它在SVN上有一个新版本

I think your are looking for an SVN command to ignoring some paths when export. 我认为你正在寻找一个SVN命令来在导出时忽略一些路径。

You may be check this answer 你可能会检查这个答案

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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