mirror of
https://github.com/logos-messaging/examples.waku.org.git
synced 2026-01-09 16:23:07 +00:00
ci: only use pnpm
This commit is contained in:
parent
03abebd641
commit
b234b496f8
34
.github/workflows/ci.yml
vendored
34
.github/workflows/ci.yml
vendored
@ -29,43 +29,17 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
version: 7
|
version: 7
|
||||||
|
|
||||||
- name: Check what package manager is used
|
|
||||||
id: pm
|
|
||||||
shell: bash
|
|
||||||
run: |
|
|
||||||
if [ -f yarn.lock ]; then
|
|
||||||
export PM="yarn"
|
|
||||||
elif [ -f pnpm-lock.yaml ]; then
|
|
||||||
export PM="pnpm"
|
|
||||||
elif [ -f package-lock.json ]; then
|
|
||||||
export PM="npm"
|
|
||||||
fi
|
|
||||||
echo "Package manager: ${PM}"
|
|
||||||
echo "::set-output name=pm::${PM}"
|
|
||||||
working-directory: ${{ matrix.example }}
|
|
||||||
|
|
||||||
- name: Install NodeJS
|
- name: Install NodeJS
|
||||||
uses: actions/setup-node@v2
|
uses: actions/setup-node@v2
|
||||||
with:
|
with:
|
||||||
node-version: "16"
|
node-version: "16"
|
||||||
cache: ${{ steps.pm.outputs.pm }}
|
cache: "pnpm"
|
||||||
cache-dependency-path: "*/pnpm-lock.yaml"
|
cache-dependency-path: "*/pnpm-lock.yaml"
|
||||||
|
|
||||||
- name: (npm) ${{ matrix.example }} install using npm ci
|
- name: install
|
||||||
if: steps.pm.outputs.pm == 'npm'
|
|
||||||
run: npm ci
|
|
||||||
working-directory: ${{ matrix.example }}
|
|
||||||
|
|
||||||
- name: (yarn) ${{ matrix.example }} install using yarn
|
|
||||||
if: steps.pm.outputs.pm == 'yarn'
|
|
||||||
run: yarn install --frozen-lockfile
|
|
||||||
working-directory: ${{ matrix.example }}
|
|
||||||
|
|
||||||
- name: (pnpm) ${{ matrix.example }} install using pnpm
|
|
||||||
if: steps.pm.outputs.pm == 'pnpm'
|
|
||||||
run: pnpm install --frozen-lockfile
|
run: pnpm install --frozen-lockfile
|
||||||
working-directory: ${{ matrix.example }}
|
working-directory: ${{ matrix.example }}
|
||||||
|
|
||||||
- name: ${{ matrix.example }} test
|
- name: test
|
||||||
run: npm run test
|
run: pnpm run test
|
||||||
working-directory: ${{ matrix.example }}
|
working-directory: ${{ matrix.example }}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user