Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bump-cask-pr: fix for casks that have multiple languages #9122

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 3 additions & 2 deletions Library/Homebrew/dev-cmd/bump-cask-pr.rb
Expand Up @@ -140,6 +140,7 @@ def bump_cask_pr
silent: true)

tmp_cask = Cask::CaskLoader.load(tmp_contents)
tmp_config = cask.config
tmp_url = tmp_cask.url.to_s

if new_hash.nil?
Expand All @@ -151,9 +152,9 @@ def bump_cask_pr
cask.languages.each do |language|
next if language == cask.language

tmp_cask.config.languages = [language]

lang_config = tmp_config.merge(Cask::Config.new(explicit: { languages: [language] }))
lang_cask = Cask::CaskLoader.load(tmp_contents)
lang_cask.config = lang_config
lang_url = lang_cask.url.to_s
lang_old_hash = lang_cask.sha256

Expand Down