homebrew-core/Formula/cheat.rb
2017-02-28 19:43:36 +01:00

39 lines
1.5 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.28.tar.gz"
sha256 "dea9e64b66bda68e1ee602e0d228dc8bfc06834ce1d2463eacad822a8c67adbc"
head "https://github.com/chrisallenlane/cheat.git"
bottle do
cellar :any_skip_relocation
sha256 "5f25c79a96c87ba67bb1c6cf0c79ff9317532ad682be01b0d635524feebd9322" => :sierra
sha256 "c7d3d2ef71fd22a82ee5becd6b54a6b2154d80fd76f4f5a26d74b6110438f453" => :el_capitan
sha256 "29dd13de7dc495aa1557d44c86ca5a933237caa3b0c734c7c0b7c24a996b44c7" => :yosemite
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