2022-10-15 02:51:55 -05:00
|
|
|
name: CI windows
|
|
|
|
|
|
|
|
on:
|
|
|
|
workflow_dispatch:
|
|
|
|
schedule:
|
|
|
|
- cron: '5 0 * * SUN'
|
|
|
|
permissions:
|
|
|
|
contents: read
|
|
|
|
jobs:
|
|
|
|
prepare:
|
2022-10-15 02:54:24 -05:00
|
|
|
runs-on: ubuntu-latest
|
2022-10-15 02:51:55 -05:00
|
|
|
name: setup verdaccio
|
|
|
|
services:
|
|
|
|
verdaccio:
|
2023-04-17 00:49:45 -05:00
|
|
|
image: verdaccio/verdaccio:nightly-master
|
2022-10-15 02:51:55 -05:00
|
|
|
ports:
|
|
|
|
- 4873:4873
|
|
|
|
env:
|
|
|
|
NODE_ENV: production
|
|
|
|
steps:
|
2023-10-10 11:24:51 -05:00
|
|
|
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Node
|
2023-12-18 15:38:06 -05:00
|
|
|
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
with:
|
|
|
|
node-version-file: '.nvmrc'
|
|
|
|
- name: Install pnpm
|
2023-04-12 01:23:01 -05:00
|
|
|
run: npm i pnpm@latest-8 -g
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2023-04-12 01:23:01 -05:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Install
|
2023-04-12 01:23:01 -05:00
|
|
|
run: pnpm install --registry http://localhost:4873
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Cache .pnpm-store
|
2023-03-16 01:31:06 -05:00
|
|
|
uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3
|
2022-10-15 02:51:55 -05: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-10-10 11:24:51 -05:00
|
|
|
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Node
|
2023-12-18 15:38:06 -05:00
|
|
|
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
with:
|
|
|
|
node-version-file: '.nvmrc'
|
|
|
|
- name: Install pnpm
|
2023-04-12 01:23:01 -05:00
|
|
|
run: npm i pnpm@latest-8 -g
|
2023-03-16 01:31:06 -05:00
|
|
|
- uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
with:
|
|
|
|
path: ~/.pnpm-store
|
|
|
|
key: pnpm-${{ hashFiles('pnpm-lock.yaml') }}
|
2023-04-12 01:23:01 -05:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Install
|
2023-04-12 01:23:01 -05:00
|
|
|
run: pnpm install --offline --reporter=silence --ignore-scripts
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Lint
|
|
|
|
run: pnpm lint
|
|
|
|
format:
|
|
|
|
runs-on: windows-latest
|
|
|
|
name: Format
|
|
|
|
needs: prepare
|
|
|
|
steps:
|
2023-10-10 11:24:51 -05:00
|
|
|
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Use Node
|
2023-12-18 15:38:06 -05:00
|
|
|
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
with:
|
|
|
|
node-version-file: '.nvmrc'
|
|
|
|
- name: Install pnpm
|
2023-04-12 01:23:01 -05:00
|
|
|
run: npm i pnpm@latest-8 -g
|
2023-03-16 01:31:06 -05:00
|
|
|
- uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
with:
|
|
|
|
path: ~/.pnpm-store
|
|
|
|
key: pnpm-${{ hashFiles('pnpm-lock.yaml') }}
|
2023-04-12 01:23:01 -05:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Install
|
2023-04-12 01:23:01 -05:00
|
|
|
run: pnpm install --offline --reporter=silence --ignore-scripts
|
2022-10-15 02:51:55 -05: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-10-10 11:24:51 -05:00
|
|
|
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Use Node ${{ matrix.node_version }}
|
2023-12-18 15:38:06 -05:00
|
|
|
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
with:
|
|
|
|
node-version: ${{ matrix.node_version }}
|
|
|
|
- name: Install pnpm
|
2023-04-12 01:23:01 -05:00
|
|
|
run: npm i pnpm@latest-8 -g
|
2023-03-16 01:31:06 -05:00
|
|
|
- uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
with:
|
|
|
|
path: ~/.pnpm-store
|
|
|
|
key: pnpm-${{ hashFiles('pnpm-lock.yaml') }}
|
2023-04-12 01:23:01 -05:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Install
|
2023-04-12 01:23:01 -05:00
|
|
|
run: pnpm install --offline --reporter=silence --ignore-scripts --registry http://localhost:4873
|
2022-10-15 02:51:55 -05: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-10-10 11:24:51 -05:00
|
|
|
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
|
2023-12-18 15:38:06 -05:00
|
|
|
- uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
with:
|
|
|
|
node-version-file: '.nvmrc'
|
|
|
|
- name: Install pnpm
|
2023-04-12 01:23:01 -05:00
|
|
|
run: npm i pnpm@latest-8 -g
|
2023-03-16 01:31:06 -05:00
|
|
|
- uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3
|
2022-10-15 02:51:55 -05:00
|
|
|
with:
|
|
|
|
path: ~/.pnpm-store
|
|
|
|
key: pnpm-${{ hashFiles('pnpm-lock.yaml') }}
|
2023-04-12 01:23:01 -05:00
|
|
|
- name: set store
|
|
|
|
run: |
|
|
|
|
mkdir ~/.pnpm-store
|
|
|
|
pnpm config set store-dir ~/.pnpm-store
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: Install
|
2023-04-12 01:23:01 -05:00
|
|
|
run: pnpm install --offline --reporter=silence --registry http://localhost:4873
|
2022-10-15 02:51:55 -05:00
|
|
|
- name: build
|
|
|
|
run: pnpm build
|
|
|
|
- name: Test UI
|
|
|
|
run: pnpm test:e2e:ui
|
|
|
|
# env:
|
|
|
|
# DEBUG: verdaccio:e2e*
|