Created
March 18, 2020 15:41
-
-
Save FrenchBen/327668a077c38efc1aed2849ce54d537 to your computer and use it in GitHub Desktop.
Homebrew Flutter install
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Flutter < Formula | |
desc "Google’s UI toolkit for mobile, web, and desktop from a single codebase" | |
homepage "https://flutter.dev" | |
version "1.12.13" | |
url "https://storage.googleapis.com/flutter_infra/releases/stable/macos/flutter_macos_v1.12.13+hotfix.8-stable.zip" | |
sha256 "5b5308a400bddbc29874f8fd8de7b39bb5dd8707da499c42feb3721524e784a1" | |
def install | |
prefix.install Dir["packages",".git*"] | |
bin.install Dir["bin/*"] | |
end | |
def post_install | |
puts "Updating cache folder permissions to u+rw for: #{prefix}/bin/cache" | |
chmod "u+rw", Dir["#{prefix}/bin/cache/", "#{prefix}/bin/cache/*"] | |
end | |
test do | |
system bin/"flutter", "--help" | |
system bin/"flutter", "create my_app" | |
assert_predicate testpath/"my_app.iml", :exist? | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment