Created
December 18, 2019 22:17
-
-
Save cockscomb/183acd19d2f5e127045dc43c6c472535 to your computer and use it in GitHub Desktop.
Homebrew Formula of apple/swift-format
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 SwiftFormat < Formula | |
desc "Formatting technology for Swift source code" | |
homepage "https://github.com/apple/swift-format" | |
url "https://github.com/apple/swift-format.git", :branch => "swift-5.1-branch" | |
head "https://github.com/apple/swift-format.git" | |
depends_on :xcode => ["11.0", :build] | |
def install | |
system "swift", "build", "--configuration", "release", | |
"--disable-sandbox", | |
"--build-path", "#{buildpath}/swift-format" | |
system "install", "-d", "#{prefix}/bin" | |
system "install", "#{buildpath}/swift-format/release/swift-format", "#{prefix}/bin" | |
end | |
test do | |
system "#{bin}/swift-format", "--version" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment