Skip to content

Commit

Permalink
Lock the language version for the formula
Browse files Browse the repository at this point in the history
This will prevent issues like #57 where a new, incompatible embedded
protocol version lands before we release a new Dart Sass version.

Closes #57
  • Loading branch information
nex3 committed Feb 8, 2024
1 parent 4dcbe94 commit e2f7ff2
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions Formula/sass.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,20 @@ class Sass < Formula
depends_on "buf" => :build
depends_on "dart-lang/dart/dart" => :build

resource "language" do
url "https://github.com/sass/sass.git", revision: "c04dbf6c447caf9d62094597e68fe5bf5d0b4025"
end

def install
# Tell the pub server where these installations are coming from.
ENV["PUB_ENVIRONMENT"] = "homebrew:sass"

(buildpath/'build/language').install resource("language")

system _dart/"dart", "pub", "get"
ENV["UPDATE_SASS_PROTOCOL"] = "false"
system _dart/"dart", "run", "grinder", "protobuf"
ENV.delete "UPDATE_SASS_PROTOCOL"

# Build a native-code executable on 64-bit systems only. 32-bit Dart
# doesn't support this.
Expand Down

0 comments on commit e2f7ff2

Please sign in to comment.