blob: d77f6c55e03ab83a4633587d6c3561fff4050c8c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
class GitDelta < Formula
version "0.9.0"
desc "A viewer for git and diff output"
homepage "https://github.com/dandavison/delta"
disable! because: "it is now in homebrew core. Please reinstall it as follows:\nbrew untap dandavison/delta\nbrew install git-delta\n"
if OS.mac?
url "https://github.com/dandavison/delta/releases/download/#{version}/delta-#{version}-x86_64-apple-darwin.tar.gz"
sha256 "c324ec2e571d0a623a9ec5f7124c776206a8de4dcefbf5f5e0709a7f836a7fd6"
elsif OS.linux?
url "https://github.com/dandavison/delta/releases/download/#{version}/delta-#{version}-x86_64-unknown-linux-musl.tar.gz"
sha256 "54eb5e817dae8b44462580a2005048e8e72fa678fce45c429c9e0513fadf7526"
end
conflicts_with "delta"
def install
bin.install "delta"
ohai "To configure git to use delta, run:"
ohai "git config --global core.pager \"delta --dark\" # --light for light terminal backgrounds"
end
test do
shell_output "#{bin}/delta --show-syntax-themes"
end
end
|