Created
December 29, 2009 14:33
-
-
Save BenHall/265343 to your computer and use it in GitHub Desktop.
Albacore zip workaround
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def find_files_in(directories, include, exclude=nil) | |
files = [] | |
directories.each do |d| | |
found = Dir.glob("#{d}/bin/#{@build_type}/#{include}"); | |
found = found - Dir.glob("#{d}/bin/#{@build_type}/#{exclude}") unless exclude.nil? | |
files = files + found | |
end | |
return files | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Get all files apart from pdb | |
Albacore::ZipTask.new() do |zip| | |
zip.additional_files = find_files_in ['xunit', 'xunit.console', 'xunit.gui', 'xunit.runner.msbuild', 'xunit.runner.tdnet', 'xunit.runner.utility'], '*.*', '*.pdb' | |
zip.output_file = "xunit-build-#{get_build_number}.zip" | |
zip.output_path = File.dirname(__FILE__) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment