mirror of
https://github.com/lune-org/lune.git
synced 2024-12-13 21:40:40 +00:00
100 lines
2.1 KiB
YAML
100 lines
2.1 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
pull_request:
|
|
workflow_dispatch:
|
|
|
|
defaults:
|
|
run:
|
|
shell: bash
|
|
|
|
jobs:
|
|
|
|
fmt:
|
|
name: Check formatting
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Install Rust
|
|
uses: dtolnay/rust-toolchain@stable
|
|
with:
|
|
components: rustfmt
|
|
|
|
- name: Install Just
|
|
uses: extractions/setup-just@v1
|
|
|
|
- name: Install Tooling
|
|
uses: ok-nick/setup-aftman@v0.4.2
|
|
|
|
- name: Check Formatting
|
|
run: just fmt-check
|
|
|
|
analyze:
|
|
needs: ["fmt"]
|
|
name: Analyze and lint Luau files
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Install Just
|
|
uses: extractions/setup-just@v1
|
|
|
|
- name: Install Tooling
|
|
uses: ok-nick/setup-aftman@v0.4.2
|
|
|
|
- name: Analyze
|
|
run: just analyze
|
|
|
|
ci:
|
|
needs: ["fmt"]
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
include:
|
|
- name: Windows x86_64
|
|
runner-os: windows-latest
|
|
cargo-target: x86_64-pc-windows-msvc
|
|
|
|
- name: Linux x86_64
|
|
runner-os: ubuntu-latest
|
|
cargo-target: x86_64-unknown-linux-gnu
|
|
|
|
- name: macOS x86_64
|
|
runner-os: macos-latest
|
|
cargo-target: x86_64-apple-darwin
|
|
timeout-minutes: 10
|
|
name: CI - ${{ matrix.name }}
|
|
runs-on: ${{ matrix.runner-os }}
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
with:
|
|
submodules: true
|
|
|
|
- name: Install Rust
|
|
uses: dtolnay/rust-toolchain@stable
|
|
with:
|
|
components: clippy
|
|
targets: ${{ matrix.cargo-target }}
|
|
|
|
- name: Build
|
|
run: |
|
|
cargo build \
|
|
--locked --all-features \
|
|
--target ${{ matrix.cargo-target }}
|
|
|
|
- name: Lint
|
|
run: |
|
|
cargo clippy \
|
|
--locked --all-features \
|
|
--target ${{ matrix.cargo-target }}
|
|
|
|
- name: Test
|
|
run: |
|
|
cargo test \
|
|
--locked --all-features \
|
|
--target ${{ matrix.cargo-target }}
|