public
Last active

Examples of how to build all Nuget nuspec files in a folder

  • Download Gist
package.bat
Batchfile
1 2 3 4 5 6 7 8
@ECHO OFF
SETLOCAL
SET VERSION=%1
SET NUGET=buildsupport\nuget.exe
 
FOR %%G IN (packaging\nuget\*.nuspec) DO (
%NUGET% pack %%G -Version %VERSION% -Symbols -o artifacts
)
package.rb
Ruby
1 2 3 4 5 6 7 8 9
# A rake task to build all packages in a folder
 
desc "Build the nuget packages"
task :package do
rm Dir.glob("#{ARTIFACTS}/*.nupkg")
FileList["packaging/nuget/*.nuspec"].each do |spec|
sh "#{nuget} pack #{spec} -o #{ARTIFACTS} -Version #{BUILD_NUMBER} -Symbols"
end
end

I really enjoyed your article on Los Techies! I know powershell isn't what the cool kids are using but feel free to grab the new file I added in my fork. I might add a scriptcs version as well and will let you know if I do.

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.