1
0
mirror of https://github.com/woodpecker-ci/woodpecker.git synced 2024-11-30 08:06:52 +02:00
woodpecker/.woodpecker/web.yml
qwerty287 516bc475b6
Speed up pipelines (#2127)
- Use workflow-global conditions to also skip the `clone` step for
`docs` and `web` workflows
- never run `test` and `web` for pushes (they're running for PRs and
every change we do must pass checks on PRs, so they're unnecessary)

https://github.com/woodpecker-ci/woodpecker/issues/1910
2023-08-07 10:58:42 +02:00

53 lines
892 B
YAML

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