How to configure Hudson to archive empty folders
I have the following sample / test configuration that has Hudson create a directory of e开发者_开发百科mpty folders. Its then instructed to archive everything within that folder, except it will not match empty folders and ends up archiving nothing. Whats more annoying is that Hudson does not alert you that nothing matches the search string "root**", but when it builds, it says nothing matches the search string.
(source: 86th.org)
We need Hudson to archive these empty folders for our installer since its expecting them. I fear this may not be possible because of the text "Files to archive".
At any rate, How can I configure Hudson to archive empty folders as an artifact.
You should create the artifact that you want in your build scripts, and then have hudson archive that file. So if you want a zip file that contains empty folders, do the appripriate zip command in your batch file or ant script. Then archive the output file.
Looking at the Hudson source code, it seems as if artifact archiving is meant to only match against files.
You might want to file a feature request or send an email to the USERS list, the Hudson team is pretty good about replying to requests and/or adding features in new releases.
I see three ways:
have your application NOT expect the folders but create them on demand.
or have the application create the folders at startup.
or you could just add dummy files in the folders :) just thinking out of the box.
精彩评论