Skip to content

Commit

Permalink
Use gemfile.d for upstream CI (#116)
Browse files Browse the repository at this point in the history
The gemspec shouldn't contain environment variables, because it's also
used in other contexts where it could break.

In common CI we read gemfile.d/*.rb so this is the best place for
bundler overrides.

Fixes: 3eedb81 ("feat(actions): switch to upstream CI templates (#113)")
  • Loading branch information
ekohl committed May 6, 2024
1 parent 861f54c commit 2e1ff55
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
8 changes: 1 addition & 7 deletions foreman_wreckingball.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,7 @@ Gem::Specification.new do |s|
s.test_files = Dir['test/**/*']

s.add_dependency 'foreman_puppet'

case ENV['FOREMAN_VERSION']
when '3.7-stable', '3.8-stable'
s.add_dependency 'foreman-tasks', '>= 8.0.0', '< 9.0.0'
else
s.add_dependency 'foreman-tasks'
end
s.add_dependency 'foreman-tasks'

s.add_development_dependency 'rdoc'
s.add_development_dependency 'theforeman-rubocop', '~> 0.1.2'
Expand Down
6 changes: 6 additions & 0 deletions gemfile.d/tasks.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# frozen_string_literal: true

case ENV['FOREMAN_VERSION']
when '3.7-stable', '3.8-stable'
gem 'foreman-tasks', '~> 8.0'
end

0 comments on commit 2e1ff55

Please sign in to comment.