forked from Homebrew/homebrew-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapktool.rb
25 lines (21 loc) · 859 Bytes
/
apktool.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
class Apktool < Formula
desc "Tool for reverse engineering 3rd party, closed, binary Android apps"
homepage "https://github.com/iBotPeaches/Apktool"
url "https://github.com/iBotPeaches/Apktool/releases/download/v2.4.0/apktool_2.4.0.jar"
sha256 "a0f116e8916d6f21160e1559847bb8b8c32ee71900f321cafeadbe37b87ebcc1"
bottle :unneeded
resource "sample.apk" do
url "https://github.com/downloads/stephanenicolas/RoboDemo/robodemo-sample-1.0.1.apk"
sha256 "bf3ec04631339538c8edb97ebbd5262c3962c5873a2df9022385156c775eb81f"
end
def install
libexec.install "apktool_#{version}.jar"
bin.write_jar_script libexec/"apktool_#{version}.jar", "apktool"
end
test do
resource("sample.apk").stage do
system bin/"apktool", "d", "robodemo-sample-1.0.1.apk"
system bin/"apktool", "b", "robodemo-sample-1.0.1"
end
end
end