Skip to content

Commit 621e34c

Browse files
morri-sonmorrison-sapmatthiasbruns
authored
Correct css.sass warnings (#754)
<!-- markdownlint-disable MD041 --> #### What this PR does / why we need it Add version pinning for dart-sass, so that workflow and netlify preview are in sync. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Chores** * Updated site publication workflow to pin a specific Dart Sass version (bumped to 1.98.0) and switch to a user-local installation approach, ensuring consistent, reproducible builds and removing reliance on system package installs. Added creation of a user-local executable directory and explicit version env settings for more reliable deployments. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Signed-off-by: Gerald Morrison (SAP) <gerald.morrison@sap.com> Co-authored-by: Gerald Morrison (SAP) <gerald.morrison@sap.com> Co-authored-by: Matthias Bruns <git@matthiasbruns.com>
1 parent a8b5449 commit 621e34c

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

.github/workflows/publish-site.yaml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@ jobs:
1515
name: Publish Site
1616
runs-on: ubuntu-latest
1717

18+
env:
19+
DART_SASS_VERSION: 1.98.0
20+
1821
permissions:
1922
contents: write
2023
id-token: write
@@ -44,8 +47,17 @@ jobs:
4447
hugo-version: '0.155.0'
4548
extended: true
4649

50+
# For the installation of dart sass follow https://gohugo.io/functions/css/sass/#dart-sass and
51+
# https://gohugo.io/host-and-deploy/host-on-github-pages/
52+
- name: Create directory for user-specific executable files
53+
run: mkdir -p "${HOME}/.local"
54+
4755
- name: Install Dart Sass
48-
run: sudo snap install dart-sass
56+
run: |
57+
curl -sLJO "https://github.com/sass/dart-sass/releases/download/${DART_SASS_VERSION}/dart-sass-${DART_SASS_VERSION}-linux-x64.tar.gz"
58+
tar -C "${HOME}/.local" -xf "dart-sass-${DART_SASS_VERSION}-linux-x64.tar.gz"
59+
rm "dart-sass-${DART_SASS_VERSION}-linux-x64.tar.gz"
60+
echo "${HOME}/.local/dart-sass" >> "${GITHUB_PATH}"
4961
5062
- name: Install deps and Build
5163
run: |

netlify.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
[build.environment]
2-
DART_SASS_VERSION = "1.97.3"
2+
# For the installation of dart sass follow https://gohugo.io/functions/css/sass/#dart-sass and
3+
# https://gohugo.io/host-and-deploy/host-on-github-pages/
4+
DART_SASS_VERSION = "1.98.0"
35
NODE_VERSION = "25.6.1"
46
NPM_VERSION = "11.9.0"
57

0 commit comments

Comments
 (0)