1 #!/usr/bin/env nix-shell
2 #!nix-shell -i bash -p yq ripgrep common-updater-scripts dart
6 PACKAGE_DIR
="$(realpath "$
(dirname "$0")")"
8 while ! test -f default.nix
; do cd ..
; done
12 list-git-tags --url=https://github.com/sass/dart-sass \
14 | sort --version-sort \
18 embedded_protocol_version
="$(
19 list-git-tags --url=https://github.com/sass/sass \
20 | rg '^embedded-protocol-(.*)' -r '$1' \
21 | sort --version-sort \
26 update-source-version dart-sass
"$dart_sass_version"
27 update-source-version dart-sass
"$embedded_protocol_version" \
28 --version-key=embedded-protocol-version \
29 --source-key=embedded-protocol
34 src
="$(nix-build --no-link "$NIXPKGS_DIR" -A dart-sass.src)"
37 # Maybe one day upstream will ship a pubspec.lock,
38 # until then we must generate a fresh one
39 if ! test -f pubspec.lock
; then
43 yq . pubspec.lock
> "$PACKAGE_DIR/pubspec.lock.json"