json-toolkit 0.1.1

An utility library providing pointer facilities and extending 3rd-parties JSON types
Documentation
name: CI

on:
  push:
    branches:
      - main
    tags-ignore:
      - v*
  pull_request:
    branches:
      - develop

jobs:
  lints:
    name: Lints
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v2

      - name: Install stable toolchain
        uses: dtolnay/rust-toolchain@stable
        with:
          components: "clippy,rustfmt"

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

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

      - name: Run cargo clippy
        uses: actions-rs/clippy-check@v1
        with:
          token: ${{ secrets.GITHUB_TOKEN }}
          args: --all-features
          name: Clippy Output

  build:
    name: Build
    needs: [lints]
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v2

      - name: Install stable toolchain
        uses: dtolnay/rust-toolchain@stable

      - name: Run cargo build
        uses: actions-rs/cargo@v1
        with:
          command: build
          args: --all-features

      - name: Run cargo test
        uses: actions-rs/cargo@v1
        with:
          command: test
          args: --all-features

  build-nightly:
    name: Nightly build
    runs-on: ubuntu-latest
    needs: [lints]
    steps:
      - name: Checkout repository
        uses: actions/checkout@v2

      - name: Install nightly toolchain
        uses: dtolnay/rust-toolchain@nightly

      - name: Run cargo build
        uses: actions-rs/cargo@v1
        with:
          command: build
          args: --all-features

      - name: Run cargo test
        uses: actions-rs/cargo@v1
        with:
          command: test
          args: --all-features

  build-target:
    name: Build on ${{ matrix.os }} for ${{ matrix.target }} target
    needs: [lints]
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: true
      matrix:
        os: [macos-latest, windows-latest, ubuntu-latest]
        target: ['']
        include:
          - os: macos-latest
            target: x86_64-apple-darwin
          - os: macos-latest
            target: aarch64-apple-darwin
          - os: macos-latest
            target: x86_64-apple-ios
          - os: macos-latest
            target: aarch64-apple-ios
          - os: windows-latest
            target: x86_64-pc-windows-gnu
          - os: windows-latest
            target: x86_64-pc-windows-msvc
          - os: windows-latest
            target: i686-pc-windows-gnu
          - os: windows-latest
            target: i686-pc-windows-msvc
          - os: ubuntu-latest
            target: aarch64-unknown-linux-gnu
          - os: ubuntu-latest
            target: i686-unknown-linux-gnu
          - os: ubuntu-latest
            target: x86_64-unknown-linux-gnu
          - os: ubuntu-latest
            target: aarch64-linux-android
          - os: ubuntu-latest
            target: armv7-linux-androideabi
    steps:
      - name: Checkout repository
        uses: actions/checkout@v2

      - name: Install stable toolchain
        uses: dtolnay/rust-toolchain@stable
        with:
          targets: "${{ matrix.target }}"

      - name: Run cargo build
        uses: actions-rs/cargo@v1
        with:
          command: build
          args: --all-features

      - name: Run cargo test
        uses: actions-rs/cargo@v1
        with:
          command: test
          args: --all-features

  coverage:
    name: Code coverage
    needs: [build]
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v2

      - name: Install stable toolchain
        uses: dtolnay/rust-toolchain@stable

      - name: Run cargo-tarpaulin
        uses: actions-rs/tarpaulin@v0.1
        with:
          args: --all-features

      - name: Upload to codecov.io
        uses: codecov/codecov-action@v1.0.2
        with:
          token: ${{secrets.CODECOV_TOKEN}}

      - name: Archive code coverage results
        uses: actions/upload-artifact@v1
        with:
          name: code-coverage-report
          path: cobertura.xml