bstringify 0.1.2

stringify! that yields byte string literals instead
name: CI

on:
  push:
    branches:
      - master
  pull_request:

jobs:
  # == CHECK == #
  check:
    name: Check nightly stable and MSRV
    runs-on: ubuntu-latest
    strategy:
      matrix:
        rust-toolchains:
          - 1.45.0
          - stable
          - nightly
    steps:
      - name: Install Rust toolchain
        uses: actions-rs/toolchain@v1
        with:
          profile: minimal
          toolchain: ${{ matrix.rust-toolchains }}
          override: true

      # - name: Install LLVM
      #   if: runner.os == 'Windows'
      #   shell: powershell
      #   run: |
      #     iwr -useb get.scoop.sh | iex
      #     scoop install llvm --global

      - name: Clone repo
        uses: actions/checkout@v2

      - name: Cargo check
        uses: actions-rs/cargo@v1
        with:
          command: check

  # == BUILD & TEST == #
  build-and-test:
    name: Build and test
    runs-on: ${{ matrix.os }}
    needs:
      - check
    strategy:
      fail-fast: false
      matrix:
        os:
          - ubuntu-latest
          - macos-latest
          - windows-latest
        rust-toolchains:
          - 1.45.0
          - stable
          - nightly
    steps:
      - name: Install Rust toolchain
        uses: actions-rs/toolchain@v1
        with:
          profile: default
          override: true
          toolchain: ${{ matrix.rust-toolchains }}

      - name: Clone repo
        uses: actions/checkout@v2

      - name: Downstream crate run
        uses: actions-rs/cargo@v1
        with:
          command: test

  # Deploy to Github pages #
  deploy:
    if: github.ref == 'refs/heads/master'
    runs-on: ubuntu-18.04  # Fixed version to guarantee robustness of the deployment
    needs:
      - build-and-test
    steps:
      - name: Install Rust toolchain
        uses: actions-rs/toolchain@v1
        with:
          profile: default
          override: true
          toolchain: nightly

      - name: Clone repo
        uses: actions/checkout@v2

      - name: Pre-process for docs
        run: bash ./scripts/pre_doc.sh

      - name: Build docs
        uses: actions-rs/cargo@v1
        with:
          command: doc
          args: --all-features

      - name: Post-process for docs
        run: bash ./scripts/post_doc.sh

      - name: Deploy to Github Pages
        uses: peaceiris/actions-gh-pages@v3
        with:
          github_token: ${{ secrets.GITHUB_TOKEN }}
          publish_dir: ./target/doc