ds4/.woodpecker/checks.yaml

63 lines
1.2 KiB
YAML
Raw Normal View History

2023-06-29 21:53:50 +02:00
# SPDX-FileCopyrightText: 2023 Johannes Loher
#
# SPDX-License-Identifier: MIT
$schema: https://raw.githubusercontent.com/woodpecker-ci/woodpecker/master/pipeline/schema/schema.json
variables:
- &bun_image oven/bun:latest
2023-06-29 21:53:50 +02:00
when:
2023-07-22 00:16:14 +02:00
- event: push
branch: ${CI_REPO_DEFAULT_BRANCH}
- event: pull_request
- event: tag
- event: manual
2023-06-29 21:53:50 +02:00
steps:
2023-07-22 00:16:14 +02:00
install:
image: *bun_image
2023-07-22 00:16:14 +02:00
commands:
- bun install --frozen-lockfile
2023-07-22 00:16:14 +02:00
lint:
group: check
image: *bun_image
2023-07-22 00:16:14 +02:00
commands:
- bun run lint
2023-07-22 00:16:14 +02:00
formatcheck:
group: check
image: *bun_image
2023-07-22 00:16:14 +02:00
commands:
- bun run format:check
2023-07-22 00:16:14 +02:00
typecheck:
group: check
image: *bun_image
2023-07-22 00:16:14 +02:00
commands:
- bun run typecheck
2023-07-22 00:16:14 +02:00
test:
group: check
image: *bun_image
2023-07-22 00:16:14 +02:00
commands:
- bun run test
2023-07-22 00:16:14 +02:00
reuse:
group: check
image: fsfe/reuse:latest
commands:
- reuse lint
commitlint:
group: check
image: *bun_image
2023-07-22 00:16:14 +02:00
commands:
- apt-get update
- apt-get install git -y
- git fetch origin ${CI_COMMIT_TARGET_BRANCH}
- bunx commitlint --from origin/${CI_COMMIT_TARGET_BRANCH}
2023-07-22 00:16:14 +02:00
when:
event: pull_request
build:
group: build
image: *bun_image
2023-07-22 00:16:14 +02:00
commands:
- export APPDATA=$(pwd)
- bun run build