40 lines
1.6 KiB
Ruby
40 lines
1.6 KiB
Ruby
class Cheat < Formula
|
|
include Language::Python::Virtualenv
|
|
|
|
desc "Create and view interactive cheat sheets for *nix commands"
|
|
homepage "https://github.com/chrisallenlane/cheat"
|
|
url "https://github.com/chrisallenlane/cheat/archive/2.1.26.tar.gz"
|
|
sha256 "427c4e5c9a76b78802c1b1959668af20812e8fae8474d9258fb726f166e8f498"
|
|
head "https://github.com/chrisallenlane/cheat.git"
|
|
|
|
bottle do
|
|
cellar :any_skip_relocation
|
|
sha256 "10add0338998299ab7c5f5f88b4ca4905c30365d33cee6cf5d26de50dc549f8f" => :sierra
|
|
sha256 "84bd2ebdbbf37b72e41eeedbdc558321d2508f202adc006ad94f82f5b1e32094" => :el_capitan
|
|
sha256 "6e60a0e4bd0211e5a9b6d5c1b2f58d2a21cb4dbd5bc0586c678162c4285477e9" => :yosemite
|
|
sha256 "8c5796ed54ee16c81fabec5d2d3e71724dc307b06261ac26ef2edec9182c99b4" => :mavericks
|
|
end
|
|
|
|
depends_on :python if MacOS.version <= :snow_leopard
|
|
|
|
resource "docopt" do
|
|
url "https://files.pythonhosted.org/packages/a2/55/8f8cab2afd404cf578136ef2cc5dfb50baa1761b68c9da1fb1e4eed343c9/docopt-0.6.2.tar.gz"
|
|
sha256 "49b3a825280bd66b3aa83585ef59c4a8c82f2c8a522dbe754a8bc8d08c85c491"
|
|
end
|
|
|
|
resource "Pygments" do
|
|
url "https://files.pythonhosted.org/packages/b8/67/ab177979be1c81bc99c8d0592ef22d547e70bb4c6815c383286ed5dec504/Pygments-2.1.3.tar.gz"
|
|
sha256 "88e4c8a91b2af5962bfa5ea2447ec6dd357018e86e94c7d14bd8cacbc5b55d81"
|
|
end
|
|
|
|
def install
|
|
virtualenv_install_with_resources
|
|
|
|
bash_completion.install "cheat/autocompletion/cheat.bash"
|
|
zsh_completion.install "cheat/autocompletion/cheat.zsh" => "_cheat"
|
|
end
|
|
|
|
test do
|
|
system bin/"cheat", "tar"
|
|
end
|
|
end
|