Skip to content

Commit

Permalink
(PUP-12031) Add Rake task for building puppet gems
Browse files Browse the repository at this point in the history
This commit adds a Rake task, gem:build, that will build all puppet
gems which includes the three platform specific puppet gems:
x86-mingw32, x64-mingw32, and universal-darwin
  • Loading branch information
AriaXLi committed Apr 23, 2024
1 parent 867ce9c commit e58bc11
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
13 changes: 13 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,19 @@ task :default do
sh %{rake -T}
end

namespace :pl_ci do
desc 'Build puppet gems'
task :gem_build do
stdout, stderr, status = Open3.capture3('gem build puppet.gemspec --platform x86-mingw32 && gem build puppet.gemspec --platform x64-mingw32 && gem build puppet.gemspec --platform universal-darwin && gem build puppet.gemspec')
if !status.exitstatus.zero?
puts "Error building facter.gemspec \n#{stdout} \n#{stderr}"
exit(1)
else
puts stdout
end
end
end

task :spec do
ENV["LOG_SPEC_ORDER"] = "true"
sh %{rspec #{ENV['TEST'] || ENV['TESTS'] || 'spec'}}
Expand Down
2 changes: 1 addition & 1 deletion ext/project_data.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ gem_rdoc_options:
- README.md
- --line-numbers
pre_tasks:
'package:apple': 'cfpropertylist'
'package:apple': 'cfpropertylist'

0 comments on commit e58bc11

Please sign in to comment.