42 lines
1.4 KiB
Ruby
42 lines
1.4 KiB
Ruby
class Nano < Formula
|
|
desc "Free (GNU) replacement for the Pico text editor"
|
|
homepage "https://www.nano-editor.org/"
|
|
url "https://www.nano-editor.org/dist/v5/nano-5.3.tar.xz"
|
|
sha256 "c5c1cbcf622d9a96b6030d66409ed12b204e8bc01ef5e6554ebbe6fb1d734352"
|
|
license "GPL-3.0-or-later"
|
|
|
|
livecheck do
|
|
url "https://www.nano-editor.org/download.php"
|
|
regex(/href=.*?nano[._-]v?(\d+(?:\.\d+)+)\.t/i)
|
|
end
|
|
|
|
bottle do
|
|
sha256 "28dc57a07bcbb80f6f4b372ee8b9c5cd27e9b96bfb33f90a15393ce33cc8c417" => :big_sur
|
|
sha256 "a4a34983c9f7c81fda1ced912f0af688c44c2a34d3f623c81348baec63d5b056" => :catalina
|
|
sha256 "4a4d2a058b98ed80a600fc5c5e4b7fb09f1b2109fee637f38c992db6c875324e" => :mojave
|
|
sha256 "486b3ca40ba07df98354f622df6b7efbd3b3b1a0e9decd043875a9e415c9a107" => :high_sierra
|
|
end
|
|
|
|
depends_on "pkg-config" => :build
|
|
depends_on "gettext"
|
|
depends_on "ncurses"
|
|
|
|
def install
|
|
system "./configure", "--disable-debug",
|
|
"--disable-dependency-tracking",
|
|
"--prefix=#{prefix}",
|
|
"--sysconfdir=#{etc}",
|
|
"--enable-color",
|
|
"--enable-extra",
|
|
"--enable-multibuffer",
|
|
"--enable-nanorc",
|
|
"--enable-utf8"
|
|
system "make", "install"
|
|
doc.install "doc/sample.nanorc"
|
|
end
|
|
|
|
test do
|
|
system "#{bin}/nano", "--version"
|
|
end
|
|
end
|