homebrew-core/Formula/mkdocs.rb

113 lines
4.9 KiB
Ruby

class Mkdocs < Formula
include Language::Python::Virtualenv
desc "Project documentation with Markdown"
homepage "https://www.mkdocs.org/"
url "https://files.pythonhosted.org/packages/ff/cf/724004ec05e9a5558fcdd5787d6c2d6828fa5a4957c5a1d305689ab6c172/mkdocs-1.2.2.tar.gz"
sha256 "a334f5bd98ec960638511366eb8c5abc9c99b9083a0ed2401d8791b112d6b078"
license "BSD-2-Clause"
revision 1
bottle do
sha256 cellar: :any_skip_relocation, arm64_big_sur: "f74b2a2c940eb578a07f934266aaedb4743abf55a382efe276415ff6e53d19f1"
sha256 cellar: :any_skip_relocation, big_sur: "ccf5c6f78321d0df7af0ee6a974f4a958f064c37730a252dc541fe1b15445e0f"
sha256 cellar: :any_skip_relocation, catalina: "4b9eb52b1cfb12a549fd3b3cb0df254ee250ab78f9955f63fabf68671e461386"
sha256 cellar: :any_skip_relocation, mojave: "9b011afdf73c7860ac228ad7cfce495f71d7d8c6e1f74ea3e440383ae33ee255"
sha256 cellar: :any_skip_relocation, x86_64_linux: "e7620bdb6845d059997e0f575a1cf566c488c9165a8c31a176d73fd5fa40bb02"
end
depends_on "python@3.10"
depends_on "six"
resource "click" do
url "https://files.pythonhosted.org/packages/21/83/308a74ca1104fe1e3197d31693a7a2db67c2d4e668f20f43a2fca491f9f7/click-8.0.1.tar.gz"
sha256 "8c04c11192119b1ef78ea049e0a6f0463e4c48ef00a30160c704337586f3ad7a"
end
resource "ghp-import" do
url "https://files.pythonhosted.org/packages/72/60/50a903ae49f4ff2731053de314598ac0cb1f470cd68bb7f98d6dfd2af2c8/ghp-import-2.0.1.tar.gz"
sha256 "753de2eace6e0f7d4edfb3cce5e3c3b98cd52aadb80163303d1d036bda7b4483"
end
resource "importlib-metadata" do
url "https://files.pythonhosted.org/packages/a7/08/c5f2e6193c12ceb5b5048d579e8f1f82c9957b57427da808c15b44479dec/importlib_metadata-4.6.1.tar.gz"
sha256 "079ada16b7fc30dfbb5d13399a5113110dab1aa7c2bc62f66af75f0b717c8cac"
end
resource "Jinja2" do
url "https://files.pythonhosted.org/packages/39/11/8076571afd97303dfeb6e466f27187ca4970918d4b36d5326725514d3ed3/Jinja2-3.0.1.tar.gz"
sha256 "703f484b47a6af502e743c9122595cc812b0271f661722403114f71a79d0f5a4"
end
resource "Markdown" do
url "https://files.pythonhosted.org/packages/49/02/37bd82ae255bb4dfef97a4b32d95906187b7a7a74970761fca1360c4ba22/Markdown-3.3.4.tar.gz"
sha256 "31b5b491868dcc87d6c24b7e3d19a0d730d59d3e46f4eea6430a321bed387a49"
end
resource "MarkupSafe" do
url "https://files.pythonhosted.org/packages/bf/10/ff66fea6d1788c458663a84d88787bae15d45daa16f6b3ef33322a51fc7e/MarkupSafe-2.0.1.tar.gz"
sha256 "594c67807fb16238b30c44bdf74f36c02cdf22d1c8cda91ef8a0ed8dabf5620a"
end
resource "mergedeep" do
url "https://files.pythonhosted.org/packages/3a/41/580bb4006e3ed0361b8151a01d324fb03f420815446c7def45d02f74c270/mergedeep-1.3.4.tar.gz"
sha256 "0096d52e9dad9939c3d975a774666af186eda617e6ca84df4c94dec30004f2a8"
end
resource "packaging" do
url "https://files.pythonhosted.org/packages/df/86/aef78bab3afd461faecf9955a6501c4999933a48394e90f03cd512aad844/packaging-21.0.tar.gz"
sha256 "7dc96269f53a4ccec5c0670940a4281106dd0bb343f47b7471f779df49c2fbe7"
end
resource "pyparsing" do
url "https://files.pythonhosted.org/packages/c1/47/dfc9c342c9842bbe0036c7f763d2d6686bcf5eb1808ba3e170afdb282210/pyparsing-2.4.7.tar.gz"
sha256 "c203ec8783bf771a155b207279b9bccb8dea02d8f0c9e5f8ead507bc3246ecc1"
end
resource "python-dateutil" do
url "https://files.pythonhosted.org/packages/4c/c4/13b4776ea2d76c115c1d1b84579f3764ee6d57204f6be27119f13a61d0a9/python-dateutil-2.8.2.tar.gz"
sha256 "0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"
end
resource "PyYAML" do
url "https://files.pythonhosted.org/packages/a0/a4/d63f2d7597e1a4b55aa3b4d6c5b029991d3b824b5bd331af8d4ab1ed687d/PyYAML-5.4.1.tar.gz"
sha256 "607774cbba28732bfa802b54baa7484215f530991055bb562efbed5b2f20a45e"
end
resource "pyyaml_env_tag" do
url "https://files.pythonhosted.org/packages/fb/8e/da1c6c58f751b70f8ceb1eb25bc25d524e8f14fe16edcce3f4e3ba08629c/pyyaml_env_tag-0.1.tar.gz"
sha256 "70092675bda14fdec33b31ba77e7543de9ddc88f2e5b99160396572d11525bdb"
end
resource "watchdog" do
url "https://files.pythonhosted.org/packages/f5/c2/d1ff8343cd38138561d2f08aba7b0566020485346097019f3a87773c96fc/watchdog-2.1.3.tar.gz"
sha256 "e5236a8e8602ab6db4b873664c2d356c365ab3cac96fbdec4970ad616415dd45"
end
resource "zipp" do
url "https://files.pythonhosted.org/packages/3a/9f/1d4b62cbe8d222539a84089eeab603d8e45ee1f897803a0ae0860400d6e7/zipp-3.5.0.tar.gz"
sha256 "f5812b1e007e48cff63449a5e9f4e7ebea716b4111f9c4f9a645f91d579bf0c4"
end
def install
virtualenv_install_with_resources
end
test do
# build a very simple site that uses the "readthedocs" theme.
(testpath/"mkdocs.yml").write <<~EOS
site_name: MkLorum
nav:
- Home: index.md
theme: readthedocs
EOS
mkdir testpath/"docs"
(testpath/"docs/index.md").write <<~EOS
# A heading
And some deeply meaningful prose.
EOS
system "#{bin}/mkdocs", "build", "--clean"
end
end