woodpecker/.woodpecker/web.yml
6543 c24eea494b
lint en.json locales file (#2108)
make sure we don't have another  #2107
2023-08-03 23:11:52 +02:00

67 lines
1.2 KiB
YAML

when:
- event: [pull_request, tag]
- event: push
branch:
- ${CI_REPO_DEFAULT_BRANCH}
- release/*
variables:
- &node_image 'node:18-alpine'
- &when
- path: &when_path
# related config files
- ".woodpecker/web.yml"
# web source code
- "web/**"
# api source code
- "server/api/**"
branch:
exclude: ${CI_REPO_DEFAULT_BRANCH}
event: push
- path: *when_path
event: [pull_request, tag, deployment]
steps:
deps:
image: *node_image
directory: web/
commands:
- corepack enable
- pnpm install --frozen-lockfile
when: *when
lint:
group: test
image: *node_image
directory: web/
commands:
- corepack enable
- pnpm lint
when: *when
formatcheck:
group: test
image: *node_image
directory: web/
commands:
- corepack enable
- pnpm format:check
when: *when
typecheck:
group: test
image: *node_image
directory: web/
commands:
- corepack enable
- pnpm typecheck
when: *when
test:
group: test
image: *node_image
directory: web/
commands:
- corepack enable
- pnpm test
when: *when