class GitDelta < Formula version "0.0.8" desc "A syntax-highlighting pager for git" homepage "https://github.com/dandavison/delta" if OS.mac? url "https://github.com/dandavison/delta/releases/download/#{version}/delta-#{version}-x86_64-apple-darwin.tar.gz" sha256 "5254fd9b0aae158eae4ad9b0ef1725e57e17df68ec27365343bfa9c7ba094a1f" elsif OS.linux? url "https://github.com/dandavison/delta/releases/download/#{version}/delta-#{version}-x86_64-unknown-linux-musl.tar.gz" sha256 "2bb95762c6bd43ffbd14ea6bb2f2d95c7ecbf97f8af64fa39db81458cc93ff6c" 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 --compare-themes" end end