if_empty 0.3.0

Replace if/else checks for emptyness with a simple method call
Documentation
name: CI

on:
  push:
    branches: [ master ]
  pull_request:
    branches: [ master ]

env:
  CARGO_TERM_COLOR: always

jobs:
  check:
    name: Check
    runs-on: ubuntu-latest
    steps:
      - name: Checkout sources
        uses: actions/checkout@v2

      - name: Install stable toolchain
        uses: actions-rs/toolchain@v1
        with:
          profile: minimal
          toolchain: stable
          override: true

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

      - name: Run doc
        uses: actions-rs/cargo@v1
        with:
          command: doc

      - name: Deploy derive_macro dry run
        uses: actions-rs/cargo@v1
        with:
          command: publish
          args: --dry-run --manifest-path ./derive_macro/Cargo.toml
      - name: Deploy if_empty dry run
        uses: actions-rs/cargo@v1
        with:
          command: publish
          args: --dry-run

  test:
    name: Test
    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
        os: [ubuntu-latest, macos-latest, windows-latest]
    steps:
      - name: Checkout sources
        uses: actions/checkout@v2

      - name: Install stable toolchain
        uses: actions-rs/toolchain@v1
        with:
          profile: minimal
          toolchain: stable
          override: true

      - name: Test if_empty
        uses: actions-rs/cargo@v1
        with:
          command: test
      - name: Test derive macro
        uses: actions-rs/cargo@v1
        with:
          command: test
          args: --manifest-path ./derive_macro/Cargo.toml

  lint:
    name: Lint
    runs-on: ubuntu-latest
    steps:
      - name: Checkout sources
        uses: actions/checkout@v2

      - name: Install nightly toolchain
        uses: actions-rs/toolchain@v1
        with:
          profile: minimal
          toolchain: nightly
          override: true
          components: rustfmt, clippy

      - name: Run cargo fmt
        uses: actions-rs/cargo@v1
        with:
          command: fmt
          args: --all -- --check

      - name: Run cargo clippy
        uses: actions-rs/cargo@v1
        with:
          command: clippy
          args: -- -D warnings