From c6b11a0dbc73dc3b7d2421801788f1a5ff8a30ff Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 18:17:51 +0530 Subject: [PATCH 01/32] allureofthestars: style fixes --- Formula/allureofthestars.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Formula/allureofthestars.rb b/Formula/allureofthestars.rb index 716696a9f3d77..a834b99ac96eb 100644 --- a/Formula/allureofthestars.rb +++ b/Formula/allureofthestars.rb @@ -28,8 +28,8 @@ def install test do assert_equal "", shell_output("#{bin}/Allure --dbgMsgSer --dbgMsgCli --logPriority 0 --newGame 3 --maxFps 100000 " \ - "--stopAfterFrames 50 --automateAll --keepAutomated --gameMode battle " \ - "--setDungeonRng \"SMGen 7 7\" --setMainRng \"SMGen 7 7\"") + "--stopAfterFrames 50 --automateAll --keepAutomated --gameMode battle " \ + "--setDungeonRng \"SMGen 7 7\" --setMainRng \"SMGen 7 7\"") assert_equal "", (testpath/".Allure/stderr.txt").read assert_match "Client FactionId 1 closed frontend.", (testpath/".Allure/stdout.txt").read end From 6f2788a1f9fbecb66efddf686a78b82930b503ef Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 18:17:52 +0530 Subject: [PATCH 02/32] bitchx: style fixes --- Formula/bitchx.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Formula/bitchx.rb b/Formula/bitchx.rb index ad01c5866b9d4..37a0b07164ee1 100644 --- a/Formula/bitchx.rb +++ b/Formula/bitchx.rb @@ -26,7 +26,7 @@ def install "--mandir=#{man}", "--enable-ipv6", "--with-plugins=acro,aim,arcfour,amp,autocycle,blowfish,cavlink,encrypt,fserv," \ - "hint,identd,nap,pkga,possum,qbx,qmail", + "hint,identd,nap,pkga,possum,qbx,qmail", "--with-ssl" system "make" system "make", "install" From 70493a19ff69ac14d1d4b40c0f7a9e8b145c1cc9 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 18:17:52 +0530 Subject: [PATCH 03/32] blaze: style fixes --- Formula/blaze.rb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Formula/blaze.rb b/Formula/blaze.rb index 59fd215144ea2..c1be2a735ec7a 100644 --- a/Formula/blaze.rb +++ b/Formula/blaze.rb @@ -44,8 +44,11 @@ def install } EOS - expected = "C =\n( -1 -1 )" \ - "\n( 0 -4 )\n" + expected = <<~EOS + C = + ( -1 -1 ) + ( 0 -4 ) + EOS system ENV.cxx, "test.cpp", "-std=c++14", "-I#{include}", "-o", "test" assert_equal expected, shell_output(testpath/"test") From a39febd6484214d10d8358442c810763abd543fe Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 18:17:53 +0530 Subject: [PATCH 04/32] cql: style fixes --- Formula/cql.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Formula/cql.rb b/Formula/cql.rb index 36125406d6783..ffb8d062e8e43 100644 --- a/Formula/cql.rb +++ b/Formula/cql.rb @@ -20,8 +20,8 @@ def install ENV["CGO_ENABLED"] = "1" ldflags = "-s -w -X main.version=v#{version} " \ - "-X github.com/CovenantSQL/CovenantSQL/conf.RoleTag=C " \ - "-X github.com/CovenantSQL/CovenantSQL/utils/log.SimpleLog=Y" + "-X github.com/CovenantSQL/CovenantSQL/conf.RoleTag=C " \ + "-X github.com/CovenantSQL/CovenantSQL/utils/log.SimpleLog=Y" system "go", "build", *std_go_args, "-tags", "sqlite_omit_load_extension", "-ldflags", ldflags, "./cmd/cql" From 07c3c75e64143db5efe3d0a6dcc4c0cc1ed1ed8b Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 18:17:53 +0530 Subject: [PATCH 05/32] dmagnetic: style fixes --- Formula/dmagnetic.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Formula/dmagnetic.rb b/Formula/dmagnetic.rb index a20994e3960b1..18de5c7218fe8 100644 --- a/Formula/dmagnetic.rb +++ b/Formula/dmagnetic.rb @@ -20,9 +20,9 @@ def install test do assert_match "ab9ec7787593e310ac4d8187db3f6cee", \ shell_output("echo Hello | #{bin}/dMagnetic "\ - "-vmode none -vcols 300 -vrows 300 -vecho -sres 1024x768 "\ - "-mag #{share}/games/dMagnetic/minitest.mag "\ - "-gfx #{share}/games/dMagnetic/minitest.gfx "\ - "| md5").strip + "-vmode none -vcols 300 -vrows 300 -vecho -sres 1024x768 "\ + "-mag #{share}/games/dMagnetic/minitest.mag "\ + "-gfx #{share}/games/dMagnetic/minitest.gfx "\ + "| md5").strip end end From 1b5f8741317f23a1082dfa7a92d9a5b1c27ae866 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 18:17:53 +0530 Subject: [PATCH 06/32] dungeon: style fixes --- Formula/dungeon.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Formula/dungeon.rb b/Formula/dungeon.rb index a891f43e38fd9..604629ac0d6af 100644 --- a/Formula/dungeon.rb +++ b/Formula/dungeon.rb @@ -18,8 +18,8 @@ def install # look for game files where homebrew installed them, not pwd inreplace "game.f" do |s| s.gsub! "FILE='dindx',STATUS='OLD',", "FILE='#{opt_pkgshare}/dindx'," - s.gsub! "1\tFORM='FORMATTED',ACCESS='SEQUENTIAL',ERR=1900)", "1\tSTATUS='OLD',FORM='FORMATTED', -\t2\tACCESS='SEQUENTIAL',ERR=1900)" + s.gsub! "1\tFORM='FORMATTED',ACCESS='SEQUENTIAL',ERR=1900)", "1\tSTATUS='OLD',FORM='FORMATTED'," \ + "\n\t2\tACCESS='SEQUENTIAL',ERR=1900)" s.gsub! "FILE='dtext',STATUS='OLD',", "FILE='#{opt_pkgshare}/dtext'," s.gsub! "1\tFORM='UNFORMATTED',ACCESS='DIRECT',", "1\tSTATUS='OLD',FORM='UNFORMATTED',ACCESS='DIRECT'," end From eb9efa8167e43e70bf97af569683b09ec06808ca Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 18:17:53 +0530 Subject: [PATCH 07/32] jdnssec-tools: style fixes --- Formula/jdnssec-tools.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Formula/jdnssec-tools.rb b/Formula/jdnssec-tools.rb index 1eb95fab0f9d7..8245ef652b55d 100644 --- a/Formula/jdnssec-tools.rb +++ b/Formula/jdnssec-tools.rb @@ -30,14 +30,14 @@ def install end test do - (testpath/"powerdns.com.key").write( - "powerdns.com. 10773 IN DNSKEY 257 3 8 (AwEAAb/+pXOZWYQ8mv9WM5dFva8 + (testpath/"powerdns.com.key").write <<~EOS + powerdns.com. 10773 IN DNSKEY 257 3 8 (AwEAAb/+pXOZWYQ8mv9WM5dFva8 WU9jcIUdDuEjldbyfnkQ/xlrJC5zA EfhYhrea3SmIPmMTDimLqbh3/4SMTNPTUF+9+U1vp NfIRTFadqsmuU9F ddz3JqCcYwEpWbReg6DJOeyu+9oBoIQkPxFyLtIXEPGlQzrynKubn04 Cx83I6NfzDTraJT3jLHKeW5PVc1ifqKzHz5TXdHHTA7NkJAa0sPcZCoNE 1LpnJI/wcUpRU iuQhoLFeT1E432GuPuZ7y+agElGj0NnBxEgnHrhrnZW UbULpRa/il+Cr5Taj988HqX9Xdm - 6FjcP4Lbuds/44U7U8du224Q8jTrZ 57Yvj4VDQKc=)", - ) + 6FjcP4Lbuds/44U7U8du224Q8jTrZ 57Yvj4VDQKc=) + EOS assert_match "D4C3D5552B8679FAEEBC317E5F048B614B2E5F607DC57F1553182D49AB2179F7", shell_output("#{bin}/jdnssec-dstool -d 2 powerdns.com.key") From 117e331d222fd0aec117a2bb405adf3886ae6b78 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:47:00 +0530 Subject: [PATCH 08/32] kubeless: style fixes --- Formula/kubeless.rb | 43 ++++++++++++++++++++++++++----------------- 1 file changed, 26 insertions(+), 17 deletions(-) diff --git a/Formula/kubeless.rb b/Formula/kubeless.rb index d0fb0ca4174c6..a8e9452646d4c 100644 --- a/Formula/kubeless.rb +++ b/Formula/kubeless.rb @@ -33,41 +33,50 @@ def install socket = server.accept request = socket.gets request_path = request.split[1] + runtime_images_data = <<-'EOS'.gsub(/\s+/, "") + [{ + \"ID\": \"python\", + \"versions\": [{ + \"name\": \"python27\", + \"version\": \"2.7\", + \"httpImage\": \"kubeless/python\" + }] + }] + EOS response = case request_path when "/api/v1/namespaces/kubeless/configmaps/kubeless-config" - '{ + <<-EOS + { "kind": "ConfigMap", "apiVersion": "v1", "metadata": { "name": "kubeless-config", "namespace": "kubeless" }, "data": { - "runtime-images": "[{' \ - '\"ID\": \"python\",' \ - '\"versions\": [{' \ - '\"name\": \"python27\",' \ - '\"version\": \"2.7\",' \ - '\"httpImage\": \"kubeless/python\"' \ - "}]" \ - '}]" - } - }' + "runtime-images": "#{runtime_images_data}" + } + } + EOS when "/apis/kubeless.io/v1beta1/namespaces/default/functions" - '{ + <<-EOS + { "apiVersion": "kubeless.io/v1beta1", "kind": "Function", "metadata": { "name": "get-python", "namespace": "default" } - }' + } + EOS when "/apis/apiextensions.k8s.io/v1beta1/customresourcedefinitions/functions.kubeless.io" - '{ + <<-EOS + { "apiVersion": "apiextensions.k8s.io/v1beta1", "kind": "CustomResourceDefinition", "metadata": { "name": "functions.kubeless.io" } - }' + } + EOS else "OK" end socket.print "HTTP/1.1 200 OK\r\n" \ - "Content-Length: #{response.bytesize}\r\n" \ - "Connection: close\r\n" + "Content-Length: #{response.bytesize}\r\n" \ + "Connection: close\r\n" socket.print "\r\n" socket.print response socket.close From 0f2294d34e0530ce8b595c3cb311050280fcc9e2 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:54:59 +0530 Subject: [PATCH 09/32] faas-cli: style fixes --- Formula/faas-cli.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Formula/faas-cli.rb b/Formula/faas-cli.rb index 8a72763868c20..8f46fbceb22a2 100644 --- a/Formula/faas-cli.rb +++ b/Formula/faas-cli.rb @@ -48,8 +48,8 @@ def install socket = server.accept response = "OK" socket.print "HTTP/1.1 200 OK\r\n" \ - "Content-Length: #{response.bytesize}\r\n" \ - "Connection: close\r\n" + "Content-Length: #{response.bytesize}\r\n" \ + "Connection: close\r\n" socket.print "\r\n" socket.print response socket.close From 7a00b2bbd7649e7af31fd76d1f0956df8866b86d Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:55:00 +0530 Subject: [PATCH 10/32] fn: style fixes --- Formula/fn.rb | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/Formula/fn.rb b/Formula/fn.rb index 0c2ada82c9f1b..eeae56cc13282 100644 --- a/Formula/fn.rb +++ b/Formula/fn.rb @@ -27,13 +27,17 @@ def install server = TCPServer.new("localhost", port) pid = fork do loop do + response = { + id: "01CQNY9PADNG8G00GZJ000000A", + name: "myapp", + created_at: "2018-09-18T08:56:08.269Z", + updated_at: "2018-09-18T08:56:08.269Z", + }.to_json + socket = server.accept - response = - '{"id":"01CQNY9PADNG8G00GZJ000000A","name":"myapp",' \ - '"created_at":"2018-09-18T08:56:08.269Z","updated_at":"2018-09-18T08:56:08.269Z"}' socket.print "HTTP/1.1 200 OK\r\n" \ - "Content-Length: #{response.bytesize}\r\n" \ - "Connection: close\r\n" + "Content-Length: #{response.bytesize}\r\n" \ + "Connection: close\r\n" socket.print "\r\n" socket.print response socket.close From 7bbcca7014e5e072062051a036894bc464700387 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:55:00 +0530 Subject: [PATCH 11/32] git-xargs: style fixes --- Formula/git-xargs.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Formula/git-xargs.rb b/Formula/git-xargs.rb index 52de126b89130..ed53b35229b97 100644 --- a/Formula/git-xargs.rb +++ b/Formula/git-xargs.rb @@ -23,8 +23,8 @@ def install assert_match "You must export a valid Github personal access token as GITHUB_OAUTH_TOKEN", shell_output("#{bin}/git-xargs --branch-name test-branch" \ - "--github-org brew-test-org" \ - "--commit-message 'Create hello-world.txt'" \ - "touch hello-world.txt 2>&1", 1) + "--github-org brew-test-org" \ + "--commit-message 'Create hello-world.txt'" \ + "touch hello-world.txt 2>&1", 1) end end From 521dcc33d85fb3e160fcb60e073fec3fd3a15e99 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:55:00 +0530 Subject: [PATCH 12/32] jmxtrans: style fixes --- Formula/jmxtrans.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Formula/jmxtrans.rb b/Formula/jmxtrans.rb index f539b8c96d57c..2e3b46ad7fcec 100644 --- a/Formula/jmxtrans.rb +++ b/Formula/jmxtrans.rb @@ -26,7 +26,7 @@ def install cd "jmxtrans" do # Point JAR_FILE into Cellar where we've installed the jar file inreplace "jmxtrans.sh", "$( cd \"$( dirname \"${BASH_SOURCE[0]}\" )/../lib\" "\ - ">/dev/null && pwd )/jmxtrans-all.jar", + ">/dev/null && pwd )/jmxtrans-all.jar", libexec/"target/jmxtrans-#{version}-all.jar" # Exec java to avoid forking the server into a new process From 22c796b8c29f7d68d3fdb020b5b3315a441780ad Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:55:01 +0530 Subject: [PATCH 13/32] k3d: style fixes --- Formula/k3d.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Formula/k3d.rb b/Formula/k3d.rb index b6fa7f764bf8b..d16357a242961 100644 --- a/Formula/k3d.rb +++ b/Formula/k3d.rb @@ -23,7 +23,7 @@ def install system "go", "build", "-mod", "vendor", "-ldflags", "-s -w -X github.com/rancher/k3d/v#{version.major}/version.Version=v#{version}"\ - " -X github.com/rancher/k3d/v#{version.major}/version.K3sVersion=latest", + " -X github.com/rancher/k3d/v#{version.major}/version.K3sVersion=latest", "-trimpath", "-o", bin/"k3d" # Install bash completion From 608d9de8d69726599be594c0bcdfaf8742cf52fb Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:55:01 +0530 Subject: [PATCH 14/32] kubergrunt: style fixes --- Formula/kubergrunt.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Formula/kubergrunt.rb b/Formula/kubergrunt.rb index 9ff2eece6197d..53e58455e7271 100644 --- a/Formula/kubergrunt.rb +++ b/Formula/kubergrunt.rb @@ -20,11 +20,11 @@ def install test do output = shell_output("#{bin}/kubergrunt eks verify --eks-cluster-arn " \ - "arn:aws:eks:us-east-1:123:cluster/brew-test 2>&1", 1) + "arn:aws:eks:us-east-1:123:cluster/brew-test 2>&1", 1) assert_match "ERROR: Error finding AWS credentials", output output = shell_output("#{bin}/kubergrunt tls gen --namespace test " \ - "--secret-name test --ca-secret-name test 2>&1", 1) + "--secret-name test --ca-secret-name test 2>&1", 1) assert_match "ERROR: --tls-common-name is required", output end end From 24f4b93a6367f18aa43a83a24c156436d0d09568 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:55:01 +0530 Subject: [PATCH 15/32] libelf: style fixes --- Formula/libelf.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Formula/libelf.rb b/Formula/libelf.rb index 87d541fb829a0..5f957ec93f60e 100644 --- a/Formula/libelf.rb +++ b/Formula/libelf.rb @@ -55,9 +55,9 @@ def install test do elf_content = "7F454C460101010000000000000000000200030001000000548004083" \ - "4000000000000000000000034002000010000000000000001000000000000000080040" \ - "80080040874000000740000000500000000100000B00431DB43B96980040831D2B20CC" \ - "D8031C040CD8048656C6C6F20776F726C640A" + "4000000000000000000000034002000010000000000000001000000000000000080040" \ + "80080040874000000740000000500000000100000B00431DB43B96980040831D2B20CC" \ + "D8031C040CD8048656C6C6F20776F726C640A" File.open(testpath/"elf", "w+b") do |file| file.write([elf_content].pack("H*")) end From 06c847a976793a011d7a221e6e95607fdbd8d307 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:55:01 +0530 Subject: [PATCH 16/32] mockolo: style fixes --- Formula/mockolo.rb | 55 ++++++++++++++++++++++++---------------------- 1 file changed, 29 insertions(+), 26 deletions(-) diff --git a/Formula/mockolo.rb b/Formula/mockolo.rb index 90d200c2a45e4..e67ca1aaf300f 100644 --- a/Formula/mockolo.rb +++ b/Formula/mockolo.rb @@ -18,36 +18,39 @@ def install end test do - (testpath/"testfile.swift").write(" - /// @mockable - public protocol Foo { - var num: Int { get set } - func bar(arg: Float) -> String - }") + (testpath/"testfile.swift").write <<~EOS + /// @mockable + public protocol Foo { + var num: Int { get set } + func bar(arg: Float) -> String + } + EOS system "#{bin}/mockolo", "-srcs", testpath/"testfile.swift", "-d", testpath/"GeneratedMocks.swift" assert_predicate testpath/"GeneratedMocks.swift", :exist? - assert_equal " - /// - /// @Generated by Mockolo - /// - public class FooMock: Foo { - public init() { } - public init(num: Int = 0) { - self.num = num - } + output = <<~EOS.gsub(/\s+/, "").strip + /// + /// @Generated by Mockolo + /// + public class FooMock: Foo { + public init() { } + public init(num: Int = 0) { + self.num = num + } - public private(set) var numSetCallCount = 0 - public var num: Int = 0 { didSet { numSetCallCount += 1 } } + public private(set) var numSetCallCount = 0 + public var num: Int = 0 { didSet { numSetCallCount += 1 } } - public private(set) var barCallCount = 0 - public var barHandler: ((Float) -> (String))? - public func bar(arg: Float) -> String { - barCallCount += 1 - if let barHandler = barHandler { - return barHandler(arg) - } - return \"\" + public private(set) var barCallCount = 0 + public var barHandler: ((Float) -> (String))? + public func bar(arg: Float) -> String { + barCallCount += 1 + if let barHandler = barHandler { + return barHandler(arg) + } + return "" + } } - }".gsub(/\s+/, "").strip, shell_output("cat #{testpath/"GeneratedMocks.swift"}").gsub(/\s+/, "").strip + EOS + assert_equal output, shell_output("cat #{testpath/"GeneratedMocks.swift"}").gsub(/\s+/, "").strip end end From bc9ae86653f0d7f90f0da4dc2011177ac7ab3775 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:07 +0530 Subject: [PATCH 17/32] molten-vk: style fixes --- Formula/molten-vk.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Formula/molten-vk.rb b/Formula/molten-vk.rb index 507fb62e7d995..84042ec260ba7 100644 --- a/Formula/molten-vk.rb +++ b/Formula/molten-vk.rb @@ -94,19 +94,19 @@ def install xcodebuild "-quiet", "-create-xcframework", "-output", "External/build/Latest/SPIRVCross.xcframework", "-library", "External/build/Intermediates/XCFrameworkStaging/" \ - "Release/Platform/libSPIRVCross.a" + "Release/Platform/libSPIRVCross.a" # Create SPIRVTools.xcframework xcodebuild "-quiet", "-create-xcframework", "-output", "External/build/Latest/SPIRVTools.xcframework", "-library", "External/build/Intermediates/XCFrameworkStaging/" \ - "Release/Platform/libSPIRVTools.a" + "Release/Platform/libSPIRVTools.a" # Created glslang.xcframework xcodebuild "-quiet", "-create-xcframework", "-output", "External/build/Latest/glslang.xcframework", "-library", "External/build/Intermediates/XCFrameworkStaging/" \ - "Release/Platform/libglslang.a" + "Release/Platform/libglslang.a" # Build MoltenVK Package xcodebuild "-project", "MoltenVKPackaging.xcodeproj", From 83061884afbe404deb401ca0a515124b8e2d0616 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:08 +0530 Subject: [PATCH 18/32] monero: style fixes --- Formula/monero.rb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Formula/monero.rb b/Formula/monero.rb index 91e8606aee4dd..7e878677ba6c0 100644 --- a/Formula/monero.rb +++ b/Formula/monero.rb @@ -70,11 +70,11 @@ def plist test do cmd = "yes '' | #{bin}/monero-wallet-cli --restore-deterministic-wallet " \ - "--password brew-test --restore-height 1 --generate-new-wallet wallet " \ - "--electrum-seed 'baptism cousin whole exquisite bobsled fuselage left " \ - "scoop emerge puzzled diet reinvest basin feast nautical upon mullet " \ - "ponies sixteen refer enhanced maul aztec bemused basin'" \ - "--command address" + "--password brew-test --restore-height 1 --generate-new-wallet wallet " \ + "--electrum-seed 'baptism cousin whole exquisite bobsled fuselage left " \ + "scoop emerge puzzled diet reinvest basin feast nautical upon mullet " \ + "ponies sixteen refer enhanced maul aztec bemused basin'" \ + "--command address" address = "4BDtRc8Ym9wGzx8vpkQQvpejxBNVpjEmVBebBPCT4XqvMxW3YaCALFraiQibejyMAxUXB5zqn4pVgHVm3JzhP2WzVAJDpHf" assert_equal address, shell_output(cmd).lines.last.split[1] end From ac7939b21bf30f986e23575220f669e45bbb630b Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:08 +0530 Subject: [PATCH 19/32] parliament: style fixes --- Formula/parliament.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Formula/parliament.rb b/Formula/parliament.rb index 2c1de7e390afe..4e68d357086e4 100644 --- a/Formula/parliament.rb +++ b/Formula/parliament.rb @@ -73,7 +73,7 @@ def install test do assert_equal "MEDIUM - No resources match for the given action - - [{'action': 's3:GetObject',"\ - " 'required_format': 'arn:*:s3:::*/*'}] - {'line': 1, 'column': 40, 'filepath': None}", \ + " 'required_format': 'arn:*:s3:::*/*'}] - {'line': 1, 'column': 40, 'filepath': None}", \ pipe_output("#{bin}/parliament --string \'{\"Version\": \"2012-10-17\", \"Statement\": {\"Effect\": \"Allow\","\ " \"Action\": \"s3:GetObject\", \"Resource\": \"arn:aws:s3:::secretbucket\"}}\'").strip end From e3bb3149106ce1e4323a7cb05a21269d23255836 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:08 +0530 Subject: [PATCH 20/32] pmdmini: style fixes --- Formula/pmdmini.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Formula/pmdmini.rb b/Formula/pmdmini.rb index 8474c78b7b6fb..7f9e3d69b798f 100644 --- a/Formula/pmdmini.rb +++ b/Formula/pmdmini.rb @@ -28,8 +28,9 @@ def install system "make" # Makefile doesn't build a dylib - system "#{ENV.cc} -dynamiclib -install_name #{lib}/libpmdmini.dylib " \ - "-o libpmdmini.dylib -undefined dynamic_lookup obj/*.o" + system ENV.cc, "-dynamiclib", "-install_name", "#{lib}/libpmdmini.dylib", + "-o", "libpmdmini.dylib", "-undefined", "dynamic_lookup", + *Dir["obj/*.o"] bin.install "pmdplay" lib.install "libpmdmini.a", "libpmdmini.dylib" From 5111fa465880df6e6aa9fee96cc8edf1bbd762e7 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:09 +0530 Subject: [PATCH 21/32] rust-analyzer: style fixes --- Formula/rust-analyzer.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Formula/rust-analyzer.rb b/Formula/rust-analyzer.rb index 516825eb2d5a7..34ed08f08c9d0 100644 --- a/Formula/rust-analyzer.rb +++ b/Formula/rust-analyzer.rb @@ -25,8 +25,8 @@ def install test do def rpc(json) "Content-Length: #{json.size}\r\n" \ - "\r\n" \ - "#{json}" + "\r\n" \ + "#{json}" end input = rpc <<-EOF From fb1f2ba4899f9f319d46a10de5f27612111e77be Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:09 +0530 Subject: [PATCH 22/32] shallow-backup: style fixes --- Formula/shallow-backup.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Formula/shallow-backup.rb b/Formula/shallow-backup.rb index 36f3b54f12a08..b2d63f3c2147e 100644 --- a/Formula/shallow-backup.rb +++ b/Formula/shallow-backup.rb @@ -84,7 +84,7 @@ def install # Creates a config file and adds a test file to it # There is colour in stdout, hence there are ANSI escape codes assert_equal "\e[34m\e[1mCreating config file at: \e[22m#{pwd}/.config/shallow-backup.conf\e[0m\n" \ - "\e[34m\e[1mAdded: \e[22m#{test_fixtures("test.svg")}\e[0m", + "\e[34m\e[1mAdded: \e[22m#{test_fixtures("test.svg")}\e[0m", shell_output("#{bin}/shallow-backup --add-dot #{test_fixtures("test.svg")}").strip # Checks if config file was created From 05b41d90058b43d985f62278b8d54d00d8d4b53c Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:09 +0530 Subject: [PATCH 23/32] skopeo: style fixes --- Formula/skopeo.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Formula/skopeo.rb b/Formula/skopeo.rb index 33e4c64f9aaa2..c401b20123128 100644 --- a/Formula/skopeo.rb +++ b/Formula/skopeo.rb @@ -38,7 +38,7 @@ def install "-X github.com/containers/image/v5/internal/tmpdir.unixTempDirForBigFiles=/var/tmp", "-X github.com/containers/image/v5/signature.systemDefaultPolicyPath=#{etc/"containers/policy.json"}", "-X github.com/containers/image/v5/pkg/sysregistriesv2.systemRegistriesConfPath=" \ - "#{etc/"containers/registries.conf"}", + "#{etc/"containers/registries.conf"}", ].join(" ") system "go", "build", "-tags", buildtags, "-ldflags", ldflags, *std_go_args, "./cmd/skopeo" From 50b8fd76fc063ec0d3357e5d040a08a838775654 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:09 +0530 Subject: [PATCH 24/32] speech-tools: style fixes --- Formula/speech-tools.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Formula/speech-tools.rb b/Formula/speech-tools.rb index 49ee2bd80b2eb..cfef938fa9216 100644 --- a/Formula/speech-tools.rb +++ b/Formula/speech-tools.rb @@ -70,8 +70,8 @@ def install "-otype", "est" # extract one frame from the middle using ch_track, capturing stdout - pitch = shell_output("#{bin}/ch_track #{ptcfile} -from #{frequency_hz * duration_secs / 2} " \ - "-to #{frequency_hz * duration_secs / 2}") + value = frequency_hz * duration_secs / 2 + pitch = shell_output("#{bin}/ch_track #{ptcfile} -from #{value} -to #{value}") # should be 100 (Hz) assert_equal frequency_hz, pitch.to_i From 4e231a39c28d151145536689d019ef4d47092921 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:09 +0530 Subject: [PATCH 25/32] sqlcipher: style fixes --- Formula/sqlcipher.rb | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/Formula/sqlcipher.rb b/Formula/sqlcipher.rb index e9cd3130db27e..3017b865aa40d 100644 --- a/Formula/sqlcipher.rb +++ b/Formula/sqlcipher.rb @@ -25,8 +25,15 @@ def install ] # Build with full-text search enabled - args << "CFLAGS=-DSQLITE_HAS_CODEC -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_FTS3 " \ - "-DSQLITE_ENABLE_FTS3_PARENTHESIS -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_COLUMN_METADATA" + cflags = %w[ + -DSQLITE_HAS_CODEC + -DSQLITE_ENABLE_JSON1 + -DSQLITE_ENABLE_FTS3 + -DSQLITE_ENABLE_FTS3_PARENTHESIS + -DSQLITE_ENABLE_FTS5 + -DSQLITE_ENABLE_COLUMN_METADATA + ].join(" ") + args << "CFLAGS=#{cflags}" system "./configure", *args system "make" From 8e0fe92aaa0eff21fa0cd65f7e823889edfb320a Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:10 +0530 Subject: [PATCH 26/32] step: style fixes --- Formula/step.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Formula/step.rb b/Formula/step.rb index d30ebd367ef0b..1b702d9f8e777 100644 --- a/Formula/step.rb +++ b/Formula/step.rb @@ -94,7 +94,7 @@ def install assert_match(/^ok$/, File.read(testpath/"health_response.txt")) shell_output("#{bin}/step ca token --password-file #{testpath}/password.txt " \ -"homebrew-smallstep-leaf > token.txt") + "homebrew-smallstep-leaf > token.txt") token = File.read(testpath/"token.txt") system "#{bin}/step", "ca", "certificate", "--token", token, "homebrew-smallstep-leaf", "brew.crt", "brew.key" From e0b237d64ae33b756a4c52d29b00701a9917f9b4 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:10 +0530 Subject: [PATCH 27/32] texlab: style fixes --- Formula/texlab.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Formula/texlab.rb b/Formula/texlab.rb index c9f7c6cca1f02..1b88834656441 100644 --- a/Formula/texlab.rb +++ b/Formula/texlab.rb @@ -22,8 +22,8 @@ def install test do def rpc(json) "Content-Length: #{json.size}\r\n" \ - "\r\n" \ - "#{json}" + "\r\n" \ + "#{json}" end input = rpc <<-EOF From 55344530a11a270f218e7e2cc7c13639f1fea0cd Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:10 +0530 Subject: [PATCH 28/32] volatility: style fixes --- Formula/volatility.rb | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/Formula/volatility.rb b/Formula/volatility.rb index 9542993524f39..691e75486db6c 100644 --- a/Formula/volatility.rb +++ b/Formula/volatility.rb @@ -155,15 +155,18 @@ def install resource("Pillow").stage do inreplace "setup.py" do |s| + s.gsub! "openjpeg.h", "probably_not_a_header_called_this_eh.hi" + sdkprefix = MacOS.sdk_path_if_needed ? MacOS.sdk_path : "" - s.gsub! "openjpeg.h", "probably_not_a_header_called_this_eh.h" s.gsub! "ZLIB_ROOT = None", "ZLIB_ROOT = ('#{sdkprefix}/usr/lib', '#{sdkprefix}/usr/include')" + + jpeg_opt_prefix = Formula["jpeg"].opt_prefix s.gsub! "JPEG_ROOT = None", - "JPEG_ROOT = ('#{Formula["jpeg"].opt_prefix}/lib', " \ - "'#{Formula["jpeg"].opt_prefix}/include')" + "JPEG_ROOT = ('#{jpeg_opt_prefix}/lib', '#{jpeg_opt_prefix}/include')" + + freetype_opt_prefix = Formula["freetype"].opt_prefix s.gsub! "FREETYPE_ROOT = None", - "FREETYPE_ROOT = ('#{Formula["freetype"].opt_prefix}/lib', " \ - "'#{Formula["freetype"].opt_prefix}/include')" + "FREETYPE_ROOT = ('#{freetype_opt_prefix}/lib', '#{freetype_opt_prefix}/include')" end begin From daa7e92a5ab6c0e5990466850e415d4c2bbc86ad Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 19:58:10 +0530 Subject: [PATCH 29/32] wownero: style fixes --- Formula/wownero.rb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Formula/wownero.rb b/Formula/wownero.rb index 59a72d5309f93..d76b4d0a7e7a9 100644 --- a/Formula/wownero.rb +++ b/Formula/wownero.rb @@ -65,11 +65,11 @@ def plist test do cmd = "yes '' | #{bin}/wownero-wallet-cli --restore-deterministic-wallet " \ - "--password brew-test --restore-height 238084 --generate-new-wallet wallet " \ - "--electrum-seed 'maze vixen spiders luggage vibrate western nugget older " \ - "emails oozed frown isolated ledge business vaults budget " \ - "saucepan faxed aloof down emulate younger jump legion saucepan'" \ - "--command address" + "--password brew-test --restore-height 238084 --generate-new-wallet wallet " \ + "--electrum-seed 'maze vixen spiders luggage vibrate western nugget older " \ + "emails oozed frown isolated ledge business vaults budget " \ + "saucepan faxed aloof down emulate younger jump legion saucepan'" \ + "--command address" address = "Wo3YLuTzJLTQjSkyNKPQxQYz5JzR6xi2CTS1PPDJD6nQAZ1ZCk1TDEHHx8CRjHNQ9JDmwCDGhvGF3CZXmmX1sM9a1YhmcQPJM" assert_equal address, shell_output(cmd).lines.last.split[1] end From 6edfbe9f5a67896c199ca5381258193e264e5a49 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 20:16:44 +0530 Subject: [PATCH 30/32] cidrmerge: style fixes --- Formula/cidrmerge.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Formula/cidrmerge.rb b/Formula/cidrmerge.rb index 6998a3a7cdf81..2b63c28b07faa 100644 --- a/Formula/cidrmerge.rb +++ b/Formula/cidrmerge.rb @@ -1,5 +1,5 @@ class Cidrmerge < Formula - desc "CIDR merging with white listing (network exclusion)" + desc "CIDR merging with network exclusion" homepage "https://cidrmerge.sourceforge.io" url "https://downloads.sourceforge.net/project/cidrmerge/cidrmerge/cidrmerge-1.5.3/cidrmerge-1.5.3.tar.gz" sha256 "21b36fc8004d4fc4edae71dfaf1209d3b7c8f8f282d1a582771c43522d84f088" From 520d467c445d9cf1206d0a91e34e1c39470c6d6b Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 20:16:44 +0530 Subject: [PATCH 31/32] ocaml: style fixes --- Formula/ocaml.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Formula/ocaml.rb b/Formula/ocaml.rb index ff7ed32b18723..4f2848b65edc7 100644 --- a/Formula/ocaml.rb +++ b/Formula/ocaml.rb @@ -32,7 +32,7 @@ class Ocaml < Formula pour_bottle? do # The ocaml compilers embed prefix information in weird ways that the default - # brew detection doesn't find, and so needs to be explicitly blacklisted. + # brew detection doesn't find, and so needs to be explicitly blocked. reason "The bottle needs to be installed into #{Homebrew::DEFAULT_PREFIX}." satisfy { HOMEBREW_PREFIX.to_s == Homebrew::DEFAULT_PREFIX } end From 4cd724ddc6c232b36df60f72cf5c6f82bd37ef14 Mon Sep 17 00:00:00 2001 From: Nanda H Krishna Date: Wed, 30 Jun 2021 20:37:58 +0530 Subject: [PATCH 32/32] randomize-lines: style fixes --- Formula/randomize-lines.rb | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Formula/randomize-lines.rb b/Formula/randomize-lines.rb index 6fe2bd893d950..59480661bcbe7 100644 --- a/Formula/randomize-lines.rb +++ b/Formula/randomize-lines.rb @@ -28,6 +28,11 @@ def install end test do - system "echo", "-e", "\" ""1\n2\n4\" | \"#{bin}/rl\" -c 1" + (testpath/"test.txt").write <<~EOS + 1 + 2 + 4 + EOS + system "#{bin}/rl", "-c", "1", testpath/"test.txt" end end