homebrew-core/Formula/paket.rb
Igor Kapkov 29ebb4e533
paket 5.195.1
Closes #35975.

Signed-off-by: Chongyu Zhu <i@lembacon.com>
2019-01-14 12:58:43 +08:00

46 lines
1.1 KiB
Ruby

class Paket < Formula
desc "Dependency manager for .NET with support for NuGet and Git repositories"
homepage "https://fsprojects.github.io/Paket/"
url "https://github.com/fsprojects/Paket/releases/download/5.195.1/paket.exe"
sha256 "6cb2eaf522615230a5efd2a3dac3b86261f03fede4308a6359c383f508425484"
bottle :unneeded
depends_on "mono"
def install
libexec.install "paket.exe"
(bin/"paket").write <<~EOS
#!/bin/bash
mono #{libexec}/paket.exe "$@"
EOS
end
test do
test_package_id = "Paket.Test"
test_package_version = "1.2.3"
touch testpath/"paket.dependencies"
touch testpath/"testfile.txt"
system bin/"paket", "install"
assert_predicate testpath/"paket.lock", :exist?
(testpath/"paket.template").write <<~EOS
type file
id #{test_package_id}
version #{test_package_version}
authors Test package author
description
Description of this test package
files
testfile.txt ==> lib
EOS
system bin/"paket", "pack", "output", testpath
assert_predicate testpath/"#{test_package_id}.#{test_package_version}.nupkg", :exist?
end
end