Skip to content

Commit

Permalink
s5cmd 2.3.0 (new formula)
Browse files Browse the repository at this point in the history
  • Loading branch information
bayandin committed Dec 16, 2024
1 parent 8cbacef commit 8c0778e
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions Formula/s/s5cmd.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
class S5cmd < Formula
desc "Parallel S3 and local filesystem execution tool"
homepage "https://github.com/peak/s5cmd/"
url "https://github.com/peak/s5cmd/archive/refs/tags/v2.3.0.tar.gz"
sha256 "6910763a7320010aa75fe9ef26f622e440c2bd6de41afdbfd64e78c158ca19d4"
license "MIT"
head "https://github.com/peak/s5cmd.git", branch: "master"

depends_on "go" => :build

def install
ldflags = %W[
-s -w
-X=github.com/peak/s5cmd/v2/version.Version=#{version}
-X=github.com/peak/s5cmd/v2/version.GitCommit=#{tap.user}
]
system "go", "build", *std_go_args(ldflags:)
generate_completions_from_executable(bin/"s5cmd", "--install-completion")
end

test do
assert_match "no valid providers in chain", shell_output("#{bin}/s5cmd --retry-count 0 ls s3://brewtest 2>&1", 1)
assert_match version.to_s, shell_output("#{bin}/s5cmd version")
end
end

0 comments on commit 8c0778e

Please sign in to comment.