2024-10-23 23:19:53 +00:00
|
|
|
name: Build
|
|
|
|
|
|
|
|
on:
|
|
|
|
workflow_dispatch:
|
|
|
|
pull_request:
|
|
|
|
types:
|
|
|
|
- opened
|
|
|
|
- ready_for_review
|
|
|
|
- synchronize
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
|
|
|
|
env:
|
|
|
|
CARGO_TERM_COLOR: always
|
|
|
|
PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/.cargo/bin
|
|
|
|
RUSTFLAGS: -C target-feature=-crt-static
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
checkfmt:
|
|
|
|
name: Check format
|
2024-10-24 03:03:33 +00:00
|
|
|
runs-on: ubuntu
|
2024-10-23 23:19:53 +00:00
|
|
|
container:
|
|
|
|
image: alpine
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
toolchain:
|
|
|
|
- nightly
|
|
|
|
steps:
|
|
|
|
- name: Install packages
|
|
|
|
run: apk add --no-cache rustup nodejs git
|
|
|
|
- name: Checkout repository
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Install rustup
|
|
|
|
run: rustup-init -y --default-toolchain none
|
|
|
|
- name: Install toolchain
|
|
|
|
run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
|
|
|
|
- name: Check format
|
|
|
|
run: cargo fmt --check
|
|
|
|
lint:
|
|
|
|
name: Lint Uketoru
|
2024-10-24 03:03:33 +00:00
|
|
|
runs-on: ubuntu
|
2024-10-23 23:19:53 +00:00
|
|
|
container:
|
|
|
|
image: alpine
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
toolchain:
|
|
|
|
- stable
|
|
|
|
steps:
|
|
|
|
- name: Install packages
|
|
|
|
run: apk add --no-cache rustup nodejs git build-base openssl-dev pkgconfig
|
|
|
|
- name: Checkout repository
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Initialize rustup
|
|
|
|
run: rustup-init -y --default-toolchain none
|
|
|
|
- name: Install toolchain
|
|
|
|
run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
|
|
|
|
- name: Lint Uketoru
|
|
|
|
run: cargo clippy --release -- -Dwarnings
|
|
|
|
build:
|
|
|
|
name: Build Uketoru
|
2024-10-24 03:03:33 +00:00
|
|
|
runs-on: ubuntu
|
2024-10-23 23:19:53 +00:00
|
|
|
container:
|
|
|
|
image: alpine
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
toolchain:
|
|
|
|
- stable
|
|
|
|
steps:
|
|
|
|
- name: Install packages
|
|
|
|
run: apk add --no-cache rustup nodejs git build-base pkgconfig openssl-dev
|
|
|
|
- name: Checkout repository
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Initialize rustup
|
|
|
|
run: rustup-init -y --default-toolchain none
|
|
|
|
- name: Install toolchain
|
|
|
|
run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
|
|
|
|
- name: Build Uketoru
|
|
|
|
run: cargo build --release
|