Compare commits

...

4 Commits

Author SHA1 Message Date
Jordan Harband
69075e99b0 [actions] continuation of f9e254e 2025-09-05 13:16:01 -07:00
Jordan Harband
5c15110981 [actions] add new github asset domain to harden-runner 2025-09-05 09:41:11 -07:00
Jordan Harband
3fa9d53dc6 [Fix] sh lacks -O; thanks shellcheck 2025-09-05 09:37:06 -07:00
Jordan Harband
f9e254e647 [actions] temporary fix for WSL issue
See https://github.com/Vampire/setup-wsl/issues/76
2025-09-05 09:20:08 -07:00
3 changed files with 23 additions and 1 deletions

View File

@@ -17,6 +17,7 @@ jobs:
api.github.com:443
objects.githubusercontent.com:443
raw.githubusercontent.com:443
release-assets.githubusercontent.com:443
registry.npmjs.org:443
- uses: actions/checkout@v4
with:

View File

@@ -133,6 +133,16 @@ jobs:
with:
distribution: ${{ matrix.wsl-distrib }}
additional-packages: bash git curl ca-certificates wget
# see https://github.com/Vampire/setup-wsl/issues/76#issuecomment-3258201135
- shell: 'wsl-bash {0}'
run: 'sed -i s/ftp.debian.org/archive.debian.org/'
- uses: Vampire/setup-wsl@v3
with:
distribution: ${{ matrix.wsl-distrib }}
additional-packages: bash git curl ca-certificates wget
update: 'true'
- name: Retrieve nvm on WSL
run: |
if [ -z "${{ matrix.method }}" ]; then
@@ -176,6 +186,16 @@ jobs:
with:
distribution: ${{ matrix.wsl-distrib }}
additional-packages: bash git curl ca-certificates wget
# see https://github.com/Vampire/setup-wsl/issues/76#issuecomment-3258201135
- shell: 'wsl-bash {0}'
run: 'sed -i s/ftp.debian.org/archive.debian.org/'
- uses: Vampire/setup-wsl@v3
with:
distribution: ${{ matrix.wsl-distrib }}
additional-packages: bash git curl ca-certificates wget
update: 'true'
- name: Retrieve nvm on WSL
run: |
if [ -z "${{ matrix.method }}" ]; then

3
nvm.sh
View File

@@ -2985,7 +2985,8 @@ nvm_check_file_permissions() {
if [ ! -L "${FILE}" ] && ! nvm_check_file_permissions "${FILE}"; then
return 2
fi
elif [ -e "$FILE" ] && [ ! -w "$FILE" ] && [ ! -O "$FILE" ]; then
elif [ -e "$FILE" ] && [ ! -w "$FILE" ] && [ -z "$(command find "${FILE}" -prune -user "$(command id -u)")" ]; then
# ^ file ownership check from https://www.shellcheck.net/wiki/SC3067
nvm_err "file is not writable or self-owned: $(nvm_sanitize_path "$FILE")"
return 1
fi