Files
Polaris/.github/workflows/ci.yml
dependabot[bot] 613d66ba3b Bump yogstation13/DreamAnnotate from 2 to 3
Bumps [yogstation13/DreamAnnotate](https://github.com/yogstation13/dreamannotate) from 2 to 3.
- [Release notes](https://github.com/yogstation13/dreamannotate/releases)
- [Commits](https://github.com/yogstation13/dreamannotate/compare/8ef04ef7fbb4ac63ee2daca222af91599e0af5e1...67354dcd99fe4f980d9887f04e0109472de0fccb)

---
updated-dependencies:
- dependency-name: yogstation13/DreamAnnotate
  dependency-version: '3'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-05-15 09:04:10 +00:00

131 lines
3.3 KiB
YAML

name: CI
permissions:
contents: read
on:
push: # any push (direct, merge, etc)
pull_request: # any pull request open / update
workflow_dispatch: # manual trigger
env:
BASENAME: "polaris"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
pre_flight:
runs-on: ubuntu-24.04
steps:
- name: checkout
uses: actions/checkout@v6
- name: paths-filter
uses: dorny/paths-filter@fbd0ab8f3e69293af611ebaee6363fc25e6d187d
id: filter
with:
filters: .github/workflow-config/preflight-filters.yml
outputs:
dm: ${{ steps.filter.outputs.dm }}
tgui: ${{ steps.filter.outputs.tgui }}
file_tests:
name: Run Linters
runs-on: ubuntu-24.04
needs: pre_flight
steps:
- uses: actions/checkout@v6
- name: Ensure +x on CI directory
run: chmod -R +x ./tools/ci
- name: Install Tools
run: bash tools/ci/install_build_deps.sh
- name: Run DM Tests
if: needs.pre_flight.outputs.dm == 'true'
run: tools/ci/validate_files.sh
- name: Run TGUI Tests
if: needs.pre_flight.outputs.tgui == 'true'
run: tools/ci/build_tgui.sh
dreamchecker:
name: DreamChecker
runs-on: ubuntu-24.04
needs: pre_flight
if: needs.pre_flight.outputs.dm == 'true'
steps:
- uses: actions/checkout@v6
- name: Cache SpacemanDMM
uses: actions/cache@v5
with:
path: ~/SpacemanDMM
key: ${{ runner.os }}-dreamchecker-${{ hashFiles('dependencies.sh')}}
restore-keys: ${{ runner.os }}-dreamchecker
- name: Install Dependencies
run: |
tools/ci/install_spaceman_dmm.sh dreamchecker
- name: Run Linter
id: linter
run: |
~/dreamchecker > ${GITHUB_WORKSPACE}/output-annotations.txt 2>&1
- name: Annotate Linter
uses: yogstation13/DreamAnnotate@67354dcd99fe4f980d9887f04e0109472de0fccb
if: always()
with:
outputFile: output-annotations.txt
unit_tests:
name: Integration Tests
runs-on: ubuntu-24.04
needs: pre_flight
if: needs.pre_flight.outputs.dm == 'true'
steps:
- uses: actions/checkout@v6
- name: Ensure +x on CI directory
run: |
chmod -R +x ./tools/ci
- name: Setup Cache
uses: actions/cache@v5
with:
path: $HOME/BYOND
key: ${{ runner.os }}-byond
- name: Install RUST_G
run: |
./tools/ci/install_rustg.sh
sudo dpkg --add-architecture i386
sudo apt update || true
sudo apt install zlib1g-dev:i386
- name: Unit Tests
run: |
tools/ci/install_byond.sh
tools/ci/compile_and_run.sh
env:
TEST_DEFINE: "UNIT_TEST"
TEST_FILE: "code/_unit_tests.dm"
RUN: "1"
- name: Compile POIs (no run)
run: |
tools/ci/install_byond.sh
tools/ci/compile_and_run.sh
env:
TEST_DEFINE: "MAP_TEST"
TEST_FILE: "code/_map_tests.dm"
RUN: "0"
- name: Compile away missions (no run)
run: |
tools/ci/install_byond.sh
tools/ci/compile_and_run.sh
env:
TEST_DEFINE: "AWAY_MISSION_TEST"
TEST_FILE: "code/_away_mission_tests.dm"
RUN: "0"