2022-10-15 09:51:55 +02:00
|
|
|
name: CI windows
|
|
|
|
|
|
|
|
on:
|
|
|
|
workflow_dispatch:
|
|
|
|
schedule:
|
|
|
|
- cron: '5 0 * * SUN'
|
|
|
|
permissions:
|
|
|
|
contents: read
|
|
|
|
jobs:
|
|
|
|
prepare:
|
2022-10-15 09:54:24 +02:00
|
|
|
runs-on: ubuntu-latest
|
2022-10-15 09:51:55 +02:00
|
|
|
name: setup verdaccio
|
|
|
|
services:
|
|
|
|
verdaccio:
|
2023-04-17 07:49:45 +02:00
|
|
|
image: verdaccio/verdaccio:nightly-master
|
2022-10-15 09:51:55 +02:00
|
|
|
ports:
|
|
|
|
- 4873:4873
|
|
|
|
env:
|
|
|
|
NODE_ENV: production
|
|
|
|
steps:
|
2023-06-12 03:36:44 +02:00
|
|
|
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Node
|
2023-08-21 16:51:37 +02:00
|
|
|
uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # tag=v3
|
2022-10-15 09:51:55 +02:00
|
|
|
with:
|
|
|
|
node-version-file: '.nvmrc'
|
|
|
|
- name: Install pnpm
|
2023-04-12 08:23:01 +02:00
|
|
|
run: npm i pnpm@latest-8 -g
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2023-04-12 08:23:01 +02:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Install
|
2023-04-12 08:23:01 +02:00
|
|
|
run: pnpm install --registry http://localhost:4873
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Cache .pnpm-store
|
2023-03-16 07:31:06 +01:00
|
|
|
uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3
|
2022-10-15 09:51:55 +02:00
|
|
|
with:
|
|
|
|
path: ~/.pnpm-store
|
|
|
|
key: pnpm-${{ hashFiles('pnpm-lock.yaml') }}
|
|
|
|
restore-keys: |
|
|
|
|
pnpm-
|
|
|
|
lint:
|
|
|
|
runs-on: windows-latest
|
|
|
|
name: Lint
|
|
|
|
needs: prepare
|
|
|
|
steps:
|
2023-06-12 03:36:44 +02:00
|
|
|
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Node
|
2023-08-21 16:51:37 +02:00
|
|
|
uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # tag=v3
|
2022-10-15 09:51:55 +02:00
|
|
|
with:
|
|
|
|
node-version-file: '.nvmrc'
|
|
|
|
- name: Install pnpm
|
2023-04-12 08:23:01 +02:00
|
|
|
run: npm i pnpm@latest-8 -g
|
2023-03-16 07:31:06 +01:00
|
|
|
- uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3
|
2022-10-15 09:51:55 +02:00
|
|
|
with:
|
|
|
|
path: ~/.pnpm-store
|
|
|
|
key: pnpm-${{ hashFiles('pnpm-lock.yaml') }}
|
2023-04-12 08:23:01 +02:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Install
|
2023-04-12 08:23:01 +02:00
|
|
|
run: pnpm install --offline --reporter=silence --ignore-scripts
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Lint
|
|
|
|
run: pnpm lint
|
|
|
|
format:
|
|
|
|
runs-on: windows-latest
|
|
|
|
name: Format
|
|
|
|
needs: prepare
|
|
|
|
steps:
|
2023-06-12 03:36:44 +02:00
|
|
|
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Use Node
|
2023-08-21 16:51:37 +02:00
|
|
|
uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # tag=v3
|
2022-10-15 09:51:55 +02:00
|
|
|
with:
|
|
|
|
node-version-file: '.nvmrc'
|
|
|
|
- name: Install pnpm
|
2023-04-12 08:23:01 +02:00
|
|
|
run: npm i pnpm@latest-8 -g
|
2023-03-16 07:31:06 +01:00
|
|
|
- uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3
|
2022-10-15 09:51:55 +02:00
|
|
|
with:
|
|
|
|
path: ~/.pnpm-store
|
|
|
|
key: pnpm-${{ hashFiles('pnpm-lock.yaml') }}
|
2023-04-12 08:23:01 +02:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Install
|
2023-04-12 08:23:01 +02:00
|
|
|
run: pnpm install --offline --reporter=silence --ignore-scripts
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Lint
|
|
|
|
run: pnpm format:check
|
|
|
|
build:
|
|
|
|
needs: [format, lint]
|
|
|
|
strategy:
|
|
|
|
fail-fast: true
|
|
|
|
matrix:
|
|
|
|
os: [windows-latest]
|
|
|
|
node_version: [18]
|
|
|
|
name: ${{ matrix.os }} / Node ${{ matrix.node_version }}
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
steps:
|
2023-06-12 03:36:44 +02:00
|
|
|
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Use Node ${{ matrix.node_version }}
|
2023-08-21 16:51:37 +02:00
|
|
|
uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # tag=v3
|
2022-10-15 09:51:55 +02:00
|
|
|
with:
|
|
|
|
node-version: ${{ matrix.node_version }}
|
|
|
|
- name: Install pnpm
|
2023-04-12 08:23:01 +02:00
|
|
|
run: npm i pnpm@latest-8 -g
|
2023-03-16 07:31:06 +01:00
|
|
|
- uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3
|
2022-10-15 09:51:55 +02:00
|
|
|
with:
|
|
|
|
path: ~/.pnpm-store
|
|
|
|
key: pnpm-${{ hashFiles('pnpm-lock.yaml') }}
|
2023-04-12 08:23:01 +02:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Install
|
2023-04-12 08:23:01 +02:00
|
|
|
run: pnpm install --offline --reporter=silence --ignore-scripts --registry http://localhost:4873
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: build
|
|
|
|
run: pnpm build
|
|
|
|
- name: Test
|
|
|
|
run: pnpm test
|
|
|
|
ci-e2e-ui:
|
|
|
|
needs: [format, lint]
|
|
|
|
runs-on: windows-latest
|
|
|
|
name: UI Test E2E
|
|
|
|
steps:
|
2023-06-12 03:36:44 +02:00
|
|
|
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
|
2023-08-21 16:51:37 +02:00
|
|
|
- uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # tag=v3
|
2022-10-15 09:51:55 +02:00
|
|
|
with:
|
|
|
|
node-version-file: '.nvmrc'
|
|
|
|
- name: Install pnpm
|
2023-04-12 08:23:01 +02:00
|
|
|
run: npm i pnpm@latest-8 -g
|
2023-03-16 07:31:06 +01:00
|
|
|
- uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3
|
2022-10-15 09:51:55 +02:00
|
|
|
with:
|
|
|
|
path: ~/.pnpm-store
|
|
|
|
key: pnpm-${{ hashFiles('pnpm-lock.yaml') }}
|
2023-04-12 08:23:01 +02:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: Install
|
2023-04-12 08:23:01 +02:00
|
|
|
run: pnpm install --offline --reporter=silence --registry http://localhost:4873
|
2022-10-15 09:51:55 +02:00
|
|
|
- name: build
|
|
|
|
run: pnpm build
|
|
|
|
- name: Test UI
|
|
|
|
run: pnpm test:e2e:ui
|
|
|
|
# env:
|
|
|
|
# DEBUG: verdaccio:e2e*
|