Skip to content

Specified more values in toolchain file #96

Specified more values in toolchain file

Specified more values in toolchain file #96

Workflow file for this run

on:
workflow_dispatch:
workflow_call:
push:
branches: [main]
pull_request:
branches: [main]
name: βœ” Validate
jobs:
fmt:
name: πŸ“‘ Rustfmt
if: |
!startsWith(github.event.head_commit.message, 'ci:')
&& !startsWith(github.event.head_commit.message, 'ci(')
runs-on: ubuntu-latest
steps:
- name: 🎟 Checkout Git Repository
id: checkout_repository_step
uses: actions/checkout@v2
- name: 🧰 Install Rust Toolchain
id: install_toolchain_step
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
components: rustfmt
- name: πŸ—‚ Set up cargo cache
id: setup_cache_step
uses: actions/cache@v3
continue-on-error: false
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: ${{ runner.os }}-cargo-
- name: πŸ“‘ Cargo Fmt
id: cargo_fmt_step
uses: actions-rs/cargo@v1
with:
command: fmt
args: --verbose -- --check
clippy:
name: πŸ“Ž Clippy
if: |
!startsWith(github.event.head_commit.message, 'ci:')
&& !startsWith(github.event.head_commit.message, 'ci(')
&& !startsWith(github.event.head_commit.message, 'style:')
&& !startsWith(github.event.head_commit.message, 'style(')
strategy:
fail-fast: false
matrix:
target:
- x86_64-unknown-linux-gnu
- x86_64-pc-windows-msvc
- x86_64-apple-darwin
- aarch64-unknown-linux-gnu
# - aarch64-apple-darwin
include:
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
- target: x86_64-pc-windows-msvc
os: windows-latest
- target: x86_64-apple-darwin
os: macos-latest
- target: aarch64-unknown-linux-gnu
os: ubuntu-latest
# - target: aarch64-apple-darwin
# os: macos-latest
continue-on-error: true
runs-on: ${{ matrix.os }}
env:
IS_CROSS: ${{ matrix.target == 'aarch64-unknown-linux-gnu' }}
steps:
- name: 🎟 Checkout Git Repository
id: checkout_repository_step
uses: actions/checkout@v2
- name: 🧰 Install Rust Toolchain
id: install_toolchain_step
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
components: clippy
- name: πŸ—‚ Set up cargo cache
id: setup_cache_step
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: ${{ runner.os }}-cargo-
- name: πŸ“Ž Clippy
id: clippy_step
uses: actions-rs/cargo@v1
with:
command: clippy
use-cross: ${{ env.IS_CROSS }}
args: --workspace --target ${{ matrix.target }} -- -D warnings
check:
name: βœ… Check
if: |
!startsWith(github.event.head_commit.message, 'ci:')
&& !startsWith(github.event.head_commit.message, 'ci(')
&& !startsWith(github.event.head_commit.message, 'docs:')
&& !startsWith(github.event.head_commit.message, 'docs(')
&& !startsWith(github.event.head_commit.message, 'style:')
&& !startsWith(github.event.head_commit.message, 'style(')
strategy:
fail-fast: false
matrix:
target:
- x86_64-unknown-linux-gnu
- x86_64-pc-windows-msvc
- x86_64-apple-darwin
- aarch64-unknown-linux-gnu
# - aarch64-apple-darwin
include:
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
- target: x86_64-pc-windows-msvc
os: windows-latest
- target: x86_64-apple-darwin
os: macos-latest
- target: aarch64-unknown-linux-gnu
os: ubuntu-latest
# - target: aarch64-apple-darwin
# os: macos-latest
runs-on: ${{ matrix.os }}
env:
IS_CROSS: ${{ matrix.target == 'aarch64-unknown-linux-gnu' }}
steps:
- name: 🎟 Checkout Git Repository
id: checkout_repository_step
uses: actions/checkout@v2
- name: 🧰 Install Rust Toolchain
id: install_toolchain_step
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
target: ${{ matrix.target }}
- name: Install OpenSSl
id: install_openssl
run: apt-get install libssl-dev openssl
- name: πŸ—‚ Set up cargo cache
id: setup_cache_step
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: ${{ runner.os }}-cargo-
- name: βœ… Cargo Check
id: cargo_check_step
uses: actions-rs/cargo@v1
with:
command: check
use-cross: ${{ env.IS_CROSS }}
args: --workspace --target ${{ matrix.target }}
test:
name: πŸ§ͺ Test
if: |
!startsWith(github.event.head_commit.message, 'ci:')
&& !startsWith(github.event.head_commit.message, 'ci(')
&& !startsWith(github.event.head_commit.message, 'docs:')
&& !startsWith(github.event.head_commit.message, 'docs(')
&& !startsWith(github.event.head_commit.message, 'style:')
&& !startsWith(github.event.head_commit.message, 'style(')
strategy:
fail-fast: false
matrix:
target:
- x86_64-unknown-linux-gnu
- x86_64-pc-windows-msvc
- x86_64-apple-darwin
- aarch64-unknown-linux-gnu
# - aarch64-apple-darwin
include:
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
- target: x86_64-pc-windows-msvc
os: windows-latest
- target: x86_64-apple-darwin
os: macos-latest
- target: aarch64-unknown-linux-gnu
os: ubuntu-latest
# - target: aarch64-apple-darwin
# os: macos-latest
runs-on: ${{ matrix.os }}
env:
IS_CROSS: ${{ matrix.target == 'aarch64-unknown-linux-gnu' }}
steps:
- name: 🎟 Checkout Git Repository
id: checkout_repository_step
uses: actions/checkout@v2
- name: 🧰 Install Rust Toolchain
id: install_toolchain_step
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
target: ${{ matrix.target }}
- name: Install OpenSSl
id: install_openssl
run: apt-get install libssl-dev openssl
- name: πŸ—‚ Set up cargo cache
id: setup_cache_step
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: ${{ runner.os }}-cargo-
- name: πŸ§ͺ Cargo Test
id: cargo_test_step
uses: actions-rs/cargo@v1
with:
command: test
use-cross: ${{ env.IS_CROSS }}
args: --workspace --target ${{ matrix.target }}