aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
authorCarl Moden2014-10-30 07:22:58 +0100
committerMike McQuaid2014-11-01 21:10:43 +0000
commitc307168828724e462a8b29a7c698c7dc04882d3a (patch)
treeccf26704cc21751ce0afd521a6cee93433eca8c9 /Library/Formula
parent57eb9e50e8e5728367d133a3fdacfcd3ccb465d0 (diff)
downloadhomebrew-c307168828724e462a8b29a7c698c7dc04882d3a.tar.bz2
megatools 1.9.93 (new formula)
Cli tools for interfacing with the webservice mega.co.nz. Closes #33720. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/megatools.rb28
1 files changed, 28 insertions, 0 deletions
diff --git a/Library/Formula/megatools.rb b/Library/Formula/megatools.rb
new file mode 100644
index 000000000..0e74ec9e9
--- /dev/null
+++ b/Library/Formula/megatools.rb
@@ -0,0 +1,28 @@
+require "formula"
+
+class Megatools < Formula
+ homepage "http://megatools.megous.com/"
+ url "http://megatools.megous.com/builds/megatools-1.9.93.tar.gz"
+ sha1 "06411d7ee19a3acaae97346c87ed3194d7d0c321"
+
+ depends_on "pkg-config" => :build
+ depends_on "glib"
+ depends_on "glib-networking"
+ depends_on "openssl"
+
+ def install
+ system "./configure", "--disable-debug",
+ "--disable-dependency-tracking",
+ "--disable-silent-rules",
+ "--prefix=#{prefix}"
+ system "make", "install"
+ end
+
+ test do
+ # Downloads a publicly hosted file and verifies its contents.
+ system "#{bin}/megadl",
+ "https://mega.co.nz/#!3Q5CnDCb!PivMgZPyf6aFnCxJhgFLX1h9uUTy9ehoGrEcAkGZSaI",
+ "--path", "testfile.txt"
+ assert_equal File.read("testfile.txt"), "Hello Homebrew!\n"
+ end
+end