fontfor 0.4.1

find fonts which can show a specified character and preview them in terminal or browser
name: CI

on:
  push:
    branches:
      - master
  pull_request:
    branches:
      - master
  workflow_dispatch:
  workflow_call:

jobs:
  style:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code
        uses: actions/checkout@v4

      - name: Install Rust nightly toolchains
        uses: dtolnay/rust-toolchain@nightly
        with:
          components: rustfmt
      - name: Check code style
        uses: actions-rs/cargo@v1
        with:
          command: fmt
          args: --all -- --check

      - name: Install Rust stable toolchains
        uses: dtolnay/rust-toolchain@stable
        with:
          components: clippy
      - name: Lint code by clippy
        uses: actions-rs/clippy-check@v1
        with:
          token: ${{ secrets.GITHUB_TOKEN }}
          args: --all-targets --all-features -- -D warnings'

  build:
    uses: ./.github/workflows/build.yml
    needs: [style]
    with:
      name: fontfor