43 lines
1.4 KiB
Ruby
43 lines
1.4 KiB
Ruby
class Mosh < Formula
|
|
desc "Remote terminal application"
|
|
homepage "https://mosh.org"
|
|
url "https://mosh.org/mosh-1.3.2.tar.gz"
|
|
sha256 "da600573dfa827d88ce114e0fed30210689381bbdcff543c931e4d6a2e851216"
|
|
revision 1
|
|
|
|
bottle do
|
|
sha256 "7dc95b3846509283e164906cbe017a21a6c6df8f1ff8d78619d7be4da52542c0" => :high_sierra
|
|
sha256 "4521333485743bdfaf4cb0341e23c58de030d2da68c2c49e541f5d6aff36b2fc" => :sierra
|
|
sha256 "4aea36489bf1fbe3e7bc22a368bbf9d95baba3b4dfb1d245f070981bf45cc37f" => :el_capitan
|
|
end
|
|
|
|
head do
|
|
url "https://github.com/mobile-shell/mosh.git", :shallow => false
|
|
|
|
depends_on "autoconf" => :build
|
|
depends_on "automake" => :build
|
|
end
|
|
|
|
option "with-test", "Run build-time tests"
|
|
|
|
deprecated_option "without-check" => "without-test"
|
|
|
|
depends_on "pkg-config" => :build
|
|
depends_on "protobuf"
|
|
depends_on "tmux" => :build if build.with?("test") || build.bottle?
|
|
|
|
def install
|
|
# teach mosh to locate mosh-client without referring
|
|
# PATH to support launching outside shell e.g. via launcher
|
|
inreplace "scripts/mosh.pl", "'mosh-client", "\'#{bin}/mosh-client"
|
|
|
|
system "./autogen.sh" if build.head?
|
|
system "./configure", "--prefix=#{prefix}", "--enable-completion"
|
|
system "make", "check" if build.with?("test") || build.bottle?
|
|
system "make", "install"
|
|
end
|
|
|
|
test do
|
|
system bin/"mosh-client", "-c"
|
|
end
|
|
end
|