Skip to content

Commit

Permalink
chore: replace yarn to npm
Browse files Browse the repository at this point in the history
  • Loading branch information
solufa committed Aug 3, 2023
1 parent 9692ebe commit 64985b3
Show file tree
Hide file tree
Showing 3 changed files with 7,707 additions and 4,376 deletions.
26 changes: 13 additions & 13 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,17 @@ jobs:
with:
node-version: ${{ matrix.node-version }}
- uses: actions/cache@v2
id: yarn-cache
id: npm-cache
with:
path: "node_modules"
key: ${{ runner.os }}-node-v${{ matrix.node-version }}-yarn-${{ hashFiles('yarn.lock') }}
- run: yarn --frozen-lockfile
if: steps.yarn-cache.outputs.cache-hit != 'true'
- run: yarn lint
key: ${{ runner.os }}-node-v${{ matrix.node-version }}-npm-${{ hashFiles('package-lock.json') }}
- run: npm install
if: steps.npm-cache.outputs.cache-hit != 'true'
- run: npm run lint
if: matrix.os != 'windows-latest'
- run: yarn typecheck
- run: yarn build
- run: yarn test
- run: npm run typecheck
- run: npm run build
- run: npm test

release:
runs-on: ubuntu-latest
Expand All @@ -44,13 +44,13 @@ jobs:
node-version: 18
registry-url: "https://registry.npmjs.org"
- uses: actions/cache@v2
id: yarn-cache
id: npm-cache
with:
path: "node_modules"
key: ${{ runner.os }}-node-v18-yarn-${{ hashFiles('yarn.lock') }}
- run: yarn --frozen-lockfile
if: steps.yarn-cache.outputs.cache-hit != 'true'
- run: yarn build
key: ${{ runner.os }}-node-v18-npm-${{ hashFiles('package-lock.json') }}
- run: npm install
if: steps.npm-cache.outputs.cache-hit != 'true'
- run: npm run build
- run: |
VERSION="$(node -e 'console.log(process.argv[1].match(/^refs\/tags\/v(\d+\.\d+\.\d+)$/)[1])' "${{ github.ref }}")"
node -e 'console.log(JSON.stringify({...require("./package.json"),version:process.argv[1]}, null, 2))' "$VERSION" | tee ./tmp-package.json
Expand Down
Loading

0 comments on commit 64985b3

Please sign in to comment.