More refinements
This commit is contained in:
@@ -1,18 +0,0 @@
|
||||
# Build workflow: runs after lint (shared workspace).
|
||||
# Same triggers as lint: PR, push/tag/manual on main, or manual.
|
||||
when:
|
||||
- event: pull_request
|
||||
- event: push
|
||||
branch: main
|
||||
- event: tag
|
||||
- event: manual
|
||||
|
||||
depends_on:
|
||||
- lint
|
||||
|
||||
steps:
|
||||
- name: build
|
||||
image: node:20-alpine
|
||||
commands:
|
||||
- corepack enable && corepack prepare pnpm@10.28.2 --activate
|
||||
- pnpm run build
|
||||
@@ -1,5 +1,6 @@
|
||||
# Lint workflow: install deps + run lint (shared workspace with build, test).
|
||||
# CI workflow: one clone, one workspace — install → lint → build → test.
|
||||
# Runs on pull requests, push/tag/manual on main, or manual from any branch.
|
||||
# Deploy workflow depends on this (ci) and runs only on main.
|
||||
when:
|
||||
- event: pull_request
|
||||
- event: push
|
||||
@@ -20,3 +21,15 @@ steps:
|
||||
- corepack enable && corepack prepare pnpm@10.28.2 --activate
|
||||
- pnpm run lint
|
||||
- pnpm run lint:css
|
||||
|
||||
- name: build
|
||||
image: node:20-alpine
|
||||
commands:
|
||||
- corepack enable && corepack prepare pnpm@10.28.2 --activate
|
||||
- pnpm run build
|
||||
|
||||
- name: test
|
||||
image: node:20-alpine
|
||||
commands:
|
||||
- corepack enable && corepack prepare pnpm@10.28.2 --activate
|
||||
- pnpm test
|
||||
@@ -1,14 +1,12 @@
|
||||
# Deploy workflow: Docker image → push to registry → Portainer webhook.
|
||||
# Runs on push to main, tag, or manual (only when on main).
|
||||
# Waits for lint, build, and test workflows to succeed first.
|
||||
# Waits for ci workflow (install → lint → build → test) to succeed first.
|
||||
when:
|
||||
branch: main
|
||||
event: [push, tag, manual]
|
||||
|
||||
depends_on:
|
||||
- lint
|
||||
- build
|
||||
- test
|
||||
- ci
|
||||
|
||||
steps:
|
||||
- name: 'Docker image build'
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
# Test workflow: runs after lint and build (shared workspace).
|
||||
# Same triggers as lint: PR, push/tag/manual on main, or manual.
|
||||
when:
|
||||
- event: pull_request
|
||||
- event: push
|
||||
branch: main
|
||||
- event: tag
|
||||
- event: manual
|
||||
|
||||
depends_on:
|
||||
- lint
|
||||
- build
|
||||
|
||||
steps:
|
||||
- name: test
|
||||
image: node:20-alpine
|
||||
commands:
|
||||
- corepack enable && corepack prepare pnpm@10.28.2 --activate
|
||||
- pnpm test
|
||||
Reference in New Issue
Block a user