Skip to content

Commit

Permalink
ci: recursive search of pnpm.cjs files to be fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
akopachov committed Feb 22, 2024
1 parent ebc0422 commit 9bd386c
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions .github/workflows/create-new-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,17 @@ jobs:
pnpm config set node-linker hoisted --location project
pnpm install
# - name: Fix PNPM to run build
# shell: pwsh
# run: |
# $pnpmcjs = "${{steps.install-pnpm.outputs.bin_dest}}/pnpm.cjs"
# (Get-Content $pnpmcjs -Raw) -replace '#!/usr/bin/env node', '#!node' | Set-Content $pnpmcjs -NoNewline
# if: ${{ matrix.os == 'windows-latest' }}
- name: Fix PNPM to run build
shell: pwsh
run: |
C:\Users\runneradmin\setup-pnpm\node_modules\.bin\
C:\Users\runneradmin\setup-pnpm\node_modules\.pnpm\pnpm@8.15.3\node_modules\pnpm\bin\pnpm.cjs
$root_path = "${{steps.install-pnpm.outputs.bin_dest}}/../.pnpm/"
Get-ChildItem -Path $root_path -Recurse -Filter "pnpm.cjs" | ForEach-Object {
$pnpmcjs = $_.FullName
(Get-Content $pnpmcjs -Raw) -replace '#!/usr/bin/env node', '#!node' | Set-Content $pnpmcjs -NoNewline
}
if: ${{ matrix.os == 'windows-latest' }}

- name: Build
run: |
Expand Down

0 comments on commit 9bd386c

Please sign in to comment.