ftdi 0.1.3

A Rust wrapper over libftdi1 library for FTDI devices
Documentation
name: Rust

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

jobs:
  linux:
    strategy:
      matrix:
        include:
        - name: MSRV (minimal)
          toolchain: 1.40.0
          features: ""
        - name: MSRV (vendored)
          toolchain: 1.40.0
          features: vendored
          native_deps: libusb-1.0-0-dev
        - name: MSRV (libusb1-sys)
          toolchain: 1.40.0
          features: libusb1-sys
        - name: vendored,libusb1-sys
          toolchain: 1.40.0
          features: libusb1-sys,vendored
          native_deps: libusb-1.0-0-dev
        - name: Nightly
          toolchain: nightly
          features: libusb1-sys,vendored
          native_deps: libusb-1.0-0-dev
      fail-fast: false

    name: ${{ matrix.name }}
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v2
      with:
        submodules: true
        fetch-depth: 0
    - name: Install toolchain
      uses: actions-rs/toolchain@v1.0.3
      with:
        toolchain: ${{ matrix.toolchain }}
        profile: minimal
        default: true
    - if: ${{ matrix.native_deps || 'libftdi1-dev' }}
      name: Install native packages (${{ matrix.native_deps || 'libftdi1-dev' }})
      run: sudo apt-get install ${{ matrix.native_deps || 'libftdi1-dev' }}
    - run: cargo build --verbose --features=${{ matrix.features }}
    - run: cargo test --verbose --features=${{ matrix.features }}

  windows-msvc:
    runs-on: windows-latest
    env:
      VCPKGRS_DYNAMIC: 1
    steps:
    - uses: actions/checkout@v2
      with:
        fetch-depth: 0
    - name: Install toolchain
      uses: actions-rs/toolchain@v1.0.3
      with:
        toolchain: 1.40.0
        target: x86_64-pc-windows-msvc
        profile: minimal
        default: true
    - name: Restore / setup vcpkg and libftdi1
      uses: lukka/run-vcpkg@v7
      with:
        vcpkgArguments: 'libftdi1:x64-windows'
        vcpkgGitCommitId: '7dbc05515b44bf54d2a42b4da9d1e1f910868b86' # Match probe-rs after cmake 3.21 problems
    - name: Build and run tests (pregenerated)
      run: cargo test --verbose