Add windows support

This commit is contained in:
Dheepak Krishnamurthy 2020-07-27 02:36:54 -06:00
parent c3a87b4f3f
commit 50dce6379d

View file

@ -6,7 +6,7 @@ jobs:
strategy: strategy:
fail-fast: false fail-fast: false
matrix: matrix:
os: [ubuntu-latest, macos-latest] os: [ubuntu-latest, windows-latest, macos-latest]
include: include:
- os: ubuntu-latest - os: ubuntu-latest
target: x86_64-unknown-linux-musl target: x86_64-unknown-linux-musl
@ -14,9 +14,9 @@ jobs:
- os: macOS-latest - os: macOS-latest
target: x86_64-apple-darwin target: x86_64-apple-darwin
rust_flags: '' rust_flags: ''
# - os: windows-latest - os: windows-latest
# target: x86_64-pc-windows-msvc target: x86_64-pc-windows-msvc
# rust_flags: -C target-feature=+crt-static rust_flags: -C target-feature=+crt-static
env: env:
RUSTFLAGS: ${{ matrix.rust_flags }} RUSTFLAGS: ${{ matrix.rust_flags }}
MACOSX_DEPLOYMENT_TARGET: 10.7 MACOSX_DEPLOYMENT_TARGET: 10.7
@ -28,9 +28,15 @@ jobs:
target: ${{ matrix.target }} target: ${{ matrix.target }}
default: true default: true
- uses: actions-rs/cargo@v1 - uses: actions-rs/cargo@v1
if: matrix.os != 'windows-latest'
with: with:
command: build command: build
args: --release --target=${{ matrix.target }} args: --release --target=${{ matrix.target }}
- uses: actions-rs/cargo@v1
if: matrix.os == 'windows-latest'
with:
command: build
args: --release --features=crossterm-backend --target=${{ matrix.target }}
# - uses: actions-rs/cargo@v1 # - uses: actions-rs/cargo@v1
# with: # with:
# command: test # command: test