Skip to content

Commit

Permalink
Allow bundle update/lock without .env file to help Renovate
Browse files Browse the repository at this point in the history
  • Loading branch information
knu committed Apr 28, 2024
1 parent 7854450 commit cdc06a6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/gemfile_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,11 @@ def parse_gem_args(args)

def sanity_check(env)
return if ENV['CI'] == 'true' || ENV['APP_SECRET_TOKEN'] || !env.empty?
# .env is not necessary in bundle update/lock; this helps Renovate
return if (File.basename($0) in 'bundle' | 'bundler') && (ARGV.first in 'lock' | 'update')
puts warning
require "shellwords"
puts "command: #{[$0, *ARGV].shelljoin}"
raise "Could not load huginn settings from .env file."
end

Expand Down

0 comments on commit cdc06a6

Please sign in to comment.