Merge pull request #11274 from Bo98/all-json

dev-cmd/bottle: fix `all` JSON filename
This commit is contained in:
Bo Anderson 2021-04-29 00:23:37 +01:00 committed by GitHub
commit 32fe482a4c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -674,8 +674,8 @@ module Homebrew
puts "Copying #{filename} to #{all_filename}" if args.verbose? puts "Copying #{filename} to #{all_filename}" if args.verbose?
FileUtils.cp filename.to_s, all_filename.to_s FileUtils.cp filename.to_s, all_filename.to_s
puts "Writing #{filename.json}" if args.verbose? puts "Writing #{all_filename.json}" if args.verbose?
all_local_json_path = Pathname(filename.json) all_local_json_path = Pathname(all_filename.json)
all_local_json_path.unlink if all_local_json_path.exist? all_local_json_path.unlink if all_local_json_path.exist?
all_local_json_path.write(JSON.pretty_generate(all_bottle_hash)) all_local_json_path.write(JSON.pretty_generate(all_bottle_hash))
end end