Merge pull request #11163 from Bo98/bottle-filename

dev-cmd/bottle: revert filename in JSON to use single dash always
This commit is contained in:
Mike McQuaid 2021-04-16 14:30:46 +01:00 committed by GitHub
commit 2b34ecfe18
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -504,12 +504,6 @@ module Homebrew
return unless args.json? return unless args.json?
bottle_filename = if bottle.root_url.match?(GitHubPackages::URL_REGEX)
filename.github_packages
else
filename.url_encode
end
json = { json = {
f.full_name => { f.full_name => {
"formula" => { "formula" => {
@ -535,7 +529,7 @@ module Homebrew
"date" => Pathname(local_filename).mtime.strftime("%F"), "date" => Pathname(local_filename).mtime.strftime("%F"),
"tags" => { "tags" => {
bottle_tag.to_s => { bottle_tag.to_s => {
"filename" => bottle_filename, "filename" => filename.url_encode,
"local_filename" => local_filename, "local_filename" => local_filename,
"sha256" => sha256, "sha256" => sha256,
"formulae_brew_sh_path" => formulae_brew_sh_path, "formulae_brew_sh_path" => formulae_brew_sh_path,