mirror of
https://github.com/chromebrew/chromebrew.git
synced 2026-05-01 03:00:26 -04:00
20 lines
815 B
Ruby
20 lines
815 B
Ruby
require 'package'
|
|
|
|
class Terminus < Package
|
|
description 'The Pantheon CLI — a standalone utility for performing operations on the Pantheon Platform'
|
|
homepage 'https://github.com/pantheon-systems/terminus'
|
|
version '3.0.7'
|
|
license 'MIT'
|
|
compatibility 'all'
|
|
source_url 'SKIP'
|
|
|
|
depends_on 'php74' unless File.exist? "#{CREW_PREFIX}/bin/php"
|
|
|
|
def self.install
|
|
system "curl -#LO https://github.com/pantheon-systems/terminus/releases/download/#{version}/terminus.phar"
|
|
abort 'Checksum mismatch. :/ Try again.'.lightred unless Digest::SHA256.hexdigest( File.read('terminus.phar') ) == 'f8fd66afb825ba2314a3c1d9a0b0e7e3dedbe687668613bd511ff6b41c4c6516'
|
|
FileUtils.mkdir_p "#{CREW_DEST_PREFIX}/bin"
|
|
FileUtils.install 'terminus.phar', "#{CREW_DEST_PREFIX}/bin/terminus", mode: 0o755
|
|
end
|
|
end
|