-
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update to use the Dart Sass binary and the new v2 protocol
E.g. use `sass --embedded`. Note taht this will bumb to a new major version of this library (v2). If you need to support the old protocol/binary, use the v1 (root path) version. It seems to be twice as fast when running in parallel, but slightly slower serialized: ```bash name old time/op new time/op delta Transpiler/SCSS-10 114µs ± 0% 145µs ± 1% +26.40% (p=0.029 n=4+4) Transpiler/Start_and_Execute-10 25.6ms ± 2% 26.0ms ± 3% ~ (p=0.486 n=4+4) Transpiler/SCSS_Parallel-10 89.0µs ± 2% 44.4µs ± 3% -50.12% (p=0.029 n=4+4) name old alloc/op new alloc/op delta Transpiler/SCSS-10 1.33kB ± 1% 1.33kB ± 0% ~ (p=1.000 n=4+4) Transpiler/Start_and_Execute-10 22.4kB ± 1% 22.4kB ± 1% ~ (p=0.886 n=4+4) Transpiler/SCSS_Parallel-10 1.34kB ± 3% 1.33kB ± 1% ~ (p=1.000 n=4+4) name old allocs/op new allocs/op delta Transpiler/SCSS-10 18.0 ± 0% 18.0 ± 0% ~ (all equal) Transpiler/Start_and_Execute-10 144 ± 1% 150 ± 0% +4.16% (p=0.029 n=4+4) Transpiler/SCSS_Parallel-10 18.0 ± 0% 18.0 ± 0% ~ (all equal) ``` See gohugoio/hugo#11059 Fixes #15
- Loading branch information
Showing
11 changed files
with
680 additions
and
725 deletions.
There are no files selected for viewing
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,17 @@ | ||
module github.com/bep/godartsass | ||
module github.com/bep/godartsass/v2 | ||
|
||
go 1.15 | ||
go 1.19 | ||
|
||
require ( | ||
github.com/cli/safeexec v1.0.0 | ||
github.com/frankban/quicktest v1.14.2 | ||
google.golang.org/protobuf v1.25.0 | ||
) | ||
|
||
require ( | ||
github.com/google/go-cmp v0.5.7 // indirect | ||
github.com/kr/pretty v0.3.0 // indirect | ||
github.com/kr/text v0.2.0 // indirect | ||
github.com/rogpeppe/go-internal v1.6.1 // indirect | ||
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 // indirect | ||
) |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
|
||
* Install protobuf: https://github.com/protocolbuffers/protobuf | ||
* Install the Go plugin: go get -u google.golang.org/protobuf/cmd/protoc-gen-go | ||
* Download the correct version of the proto file: https://github.com/sass/embedded-protocol/blob/master/embedded_sass.proto | ||
* Install the Go plugin: go install google.golang.org/protobuf/cmd/protoc-gen-go@latest | ||
* Download the correct version of the proto file: https://github.com/sass/sass/blob/main/spec/embedded_sass.proto | ||
* protoc --go_opt=Membedded_sass.proto=github.com/bep/godartsass/internal/embeddedsass --go_opt=paths=source_relative --go_out=. embedded_sass.proto |
Oops, something went wrong.