From f7ab981e5dfc2d56bc8e0e16a3ae870e62a0b420 Mon Sep 17 00:00:00 2001 From: Rui Chen Date: Tue, 12 Mar 2024 16:43:34 -0400 Subject: [PATCH 1/2] git-split-diffs 1.1.0 (new formula) Signed-off-by: Rui Chen autobump: add git-split-diffs Signed-off-by: Rui Chen --- .github/autobump.txt | 1 + Formula/g/git-split-diffs.rb | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 35 insertions(+) create mode 100644 Formula/g/git-split-diffs.rb diff --git a/.github/autobump.txt b/.github/autobump.txt index c4847434d7ad4..3f2f228bba69a 100644 --- a/.github/autobump.txt +++ b/.github/autobump.txt @@ -714,6 +714,7 @@ git-cola git-credential-oauth git-delta git-lfs +git-split-diffs git-town git-xargs gitbackup diff --git a/Formula/g/git-split-diffs.rb b/Formula/g/git-split-diffs.rb new file mode 100644 index 0000000000000..3bbf7d909355b --- /dev/null +++ b/Formula/g/git-split-diffs.rb @@ -0,0 +1,34 @@ +require "language/node" + +class GitSplitDiffs < Formula + desc "Syntax highlighted side-by-side diffs in your terminal" + homepage "https://github.com/banga/git-split-diffs" + url "https://registry.npmjs.org/git-split-diffs/-/git-split-diffs-1.1.0.tgz" + sha256 "124709db0b14ba1543553e8774d44c0c2361f4d4765f71df5d9d6d345cc104ed" + license "MIT" + + depends_on "node" + + def install + system "npm", "install", *Language::Node.std_npm_install_args(libexec) + bin.install_symlink Dir["#{libexec}/bin/*"] + end + + test do + system "git", "init", "--initial-branch=main" + system "git", "config", "user.name", "BrewTestBot" + system "git", "config", "user.email", "BrewTestBot@test.com" + + (testpath/"test").write "foo" + system "git", "add", "test" + system "git", "commit", "-m", "Initial commit" + (testpath/"test").delete + (testpath/"test").write "bar" + system "git", "add", "test" + system "git", "commit", "-m", "Second commit" + + system "git", "config", "--global", "core.pager", "git-split-diffs --color | less -RFX" + + assert_match "bar", shell_output("git diff HEAD^1...HEAD") + end +end From 474c7d444c54b065f80215c878c514162e4e156a Mon Sep 17 00:00:00 2001 From: Rui Chen Date: Thu, 14 Mar 2024 22:40:33 +0000 Subject: [PATCH 2/2] git-split-diffs: add 1.1.0 bottle. --- Formula/g/git-split-diffs.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Formula/g/git-split-diffs.rb b/Formula/g/git-split-diffs.rb index 3bbf7d909355b..1bdaae3a03f2b 100644 --- a/Formula/g/git-split-diffs.rb +++ b/Formula/g/git-split-diffs.rb @@ -7,6 +7,10 @@ class GitSplitDiffs < Formula sha256 "124709db0b14ba1543553e8774d44c0c2361f4d4765f71df5d9d6d345cc104ed" license "MIT" + bottle do + sha256 cellar: :any_skip_relocation, all: "5b348302822608e4fe122591d8b0d89cffa0a1687b79c6d49bab09fbbc9dc22b" + end + depends_on "node" def install