krz/orgo

Lightning fast org-mode static site generator. fast go org-mode static-site-generator

.gitbay/ci.yml

34 lines · 1378 bytes

 1# gitbay CI. Each job becomes one build per push; the runner clones this
 2# repository at the pushed commit and runs every step with `sh -c`, stopping at
 3# the first failure. Repository secrets arrive as environment variables.
 4#
 5# Jobs run in localhost/orgo-ci, built from .gitbay/Containerfile.ci on the
 6# runner host. Publishing goes over SSH as the orgo-ci account; see
 7# .gitbay/bot-ssh.sh.
 8#
 9# The runner is Linux, and `runner next` claims the oldest pending build with no
10# platform targeting, so a second runner could not be aimed at macOS jobs. The
11# darwin tarballs are therefore built on a Mac by .githooks/pre-push at tag time
12# and uploaded to the same release; see RELEASING.org.
13jobs:
14  test:
15    image: localhost/orgo-ci:1
16    steps:
17      - cargo test --locked
18      - cargo clippy --all-targets --locked -- -D warnings
19      - cargo run --locked -- build docs -o "/tmp/orgo-docs-$GITBAY_SHA" --strict
20      - rm -rf "/tmp/orgo-docs-$GITBAY_SHA"
21
22  # Publishes the documentation site by force-pushing the built output to the
23  # `pages` branch, which gitbay serves at https://orgo.krz.sh. A no-op off main.
24  pages:
25    image: localhost/orgo-ci:1
26    steps:
27      - sh .gitbay/pages.sh
28
29  # The tag push is the release: binaries, the gitbay release, and crates.io.
30  release:
31    tags: "v*"
32    image: localhost/orgo-ci:1
33    steps:
34      - sh .gitbay/release.sh