46 lines
2.1 KiB
Ruby
46 lines
2.1 KiB
Ruby
class Certigo < Formula
|
|
desc "Utility to examine and validate certificates in a variety of formats"
|
|
homepage "https://github.com/square/certigo"
|
|
url "https://github.com/square/certigo/archive/v1.3.0.tar.gz"
|
|
sha256 "a4292340abd2f5c0254a567538d6597ce3b467ff8f49a0157403397cd6e8b838"
|
|
head "https://github.com/square/certigo.git"
|
|
|
|
bottle do
|
|
cellar :any_skip_relocation
|
|
sha256 "5af36ac7ea040ca4d3da5d621a432a12053cf5f489e413e3993f3442764a9197" => :el_capitan
|
|
sha256 "3c88e31bd094d9669f658fdae1ed8fcfe5cfc655a9bcdd962fdc57ef09330cd5" => :yosemite
|
|
sha256 "77978fc40ff9cf604f863f9fc49452a2783e0f7e44ff4a83ab7ed82a070e2c9a" => :mavericks
|
|
end
|
|
|
|
depends_on "go" => :build
|
|
|
|
def install
|
|
system "./build"
|
|
bin.install "bin/certigo"
|
|
end
|
|
|
|
test do
|
|
(testpath/"test.crt").write <<-EOS.undent
|
|
-----BEGIN CERTIFICATE-----
|
|
MIIDLDCCAhQCCQCa74bQsAj2/jANBgkqhkiG9w0BAQsFADBYMQswCQYDVQQGEwJV
|
|
UzELMAkGA1UECBMCQ0ExEDAOBgNVBAoTB2NlcnRpZ28xEDAOBgNVBAsTB2V4YW1w
|
|
bGUxGDAWBgNVBAMTD2V4YW1wbGUtZXhwaXJlZDAeFw0xNjA2MTAyMjE0MTJaFw0x
|
|
NjA2MTEyMjE0MTJaMFgxCzAJBgNVBAYTAlVTMQswCQYDVQQIEwJDQTEQMA4GA1UE
|
|
ChMHY2VydGlnbzEQMA4GA1UECxMHZXhhbXBsZTEYMBYGA1UEAxMPZXhhbXBsZS1l
|
|
eHBpcmVkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAs6JY7Hm/NAsH
|
|
3nuMOOSBno6WmwsTYEw3hk4eyprWiI/NpoiaiZVCGahT8NAKqLDW5t9vgKz6c4ff
|
|
i5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