From 8818d934d9fe36b5ecada8e00868b0309f490c02 Mon Sep 17 00:00:00 2001 From: Natalie Weizenbaum Date: Mon, 13 Jan 2025 23:00:39 +0000 Subject: [PATCH] Properly override the sass-parser dependency on sass during release (#2487) Previously we were loading the version variable after running `npm install sass@$version`, which caused the local path dependency not to be overwritten and consequently made the sass-parser package impossible to install. --- .github/workflows/release.yml | 9 +++++---- pkg/sass-parser/CHANGELOG.md | 10 +++++----- pkg/sass-parser/package.json | 2 +- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 28fc39218..acd870538 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -127,6 +127,11 @@ jobs: check-latest: true registry-url: 'https://registry.npmjs.org' + - name: Get version + id: version + run: | + echo "version=$(jq .version pkg/sass-parser/package.json)" | tee --append "$GITHUB_OUTPUT" + # The repo package has a file dependency, but the released version needs # a real dependency on the released version of Sass. - run: npm install sass@${{ steps.version.outputs.version }} @@ -137,10 +142,6 @@ jobs: NODE_AUTH_TOKEN: '${{ secrets.NPM_TOKEN }}' working-directory: pkg/sass-parser/ - - name: Get version - id: version - run: | - echo "version=$(jq .version pkg/sass-parser/package.json)" | tee --append "$GITHUB_OUTPUT" - run: git tag sass-parser/${{ steps.version.outputs.version }} - run: git push --tag diff --git a/pkg/sass-parser/CHANGELOG.md b/pkg/sass-parser/CHANGELOG.md index af044c012..4ce6ba2e1 100644 --- a/pkg/sass-parser/CHANGELOG.md +++ b/pkg/sass-parser/CHANGELOG.md @@ -1,14 +1,14 @@ ## 0.4.9 -* No user-visible changes. +* Add support for parsing the `@include` rule. -## 0.4.8 +* Add support for parsing declarations. -Add support for parsing the `@include` rule. +## 0.4.8 -Add support for parsing the `@mixin` rule. +* Add support for parsing the `@mixin` rule. -Add support for parsing the `@return` rule. +* Add support for parsing the `@return` rule. ## 0.4.7 diff --git a/pkg/sass-parser/package.json b/pkg/sass-parser/package.json index d23090d84..cba6c2257 100644 --- a/pkg/sass-parser/package.json +++ b/pkg/sass-parser/package.json @@ -32,7 +32,7 @@ }, "dependencies": { "postcss": ">=8.4.41 <8.5.0", - "sass": "file:../../build/npm" + "sass": "^1.83.1" }, "devDependencies": { "@types/jest": "^29.5.12",