From d1d1aeb3d5aaa75f262467c5e683e76ce7a844ab Mon Sep 17 00:00:00 2001 From: Oleksii Filonenko Date: Thu, 23 Jul 2020 11:48:56 +0300 Subject: add windows to github actions --- .github/workflows/main.yml | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) (limited to '.github/workflows') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c8ccbae..e2995b8 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -82,3 +82,38 @@ jobs: asset_name: dijo-x86_64-apple tag: ${{ github.ref }} overwrite: true + + build-windows: + runs-on: windows-latest + + steps: + - name: Checkout + uses: actions/checkout@v1 + - name: Cache Rust dependencies + uses: actions/cache@v1.0.1 + with: + path: target + key: ${{ runner.OS }}-build-${{ hashFiles('**/Cargo.lock') }} + restore-keys: | + ${{ runner.OS }}-build- + - name: Install latest rust toolchain + uses: actions-rs/toolchain@v1 + with: + toolchain: beta + target: x86_64-pc-windows-msvc + default: true + override: true + + - name: Build for windows + run: | + cargo build --all --release + strip target/release/dijo + + - name: Upload binaries to release + uses: svenstaro/upload-release-action@v1-release + with: + repo_token: ${{ secrets.GITHUB_TOKEN }} + file: target/release/dijo + asset_name: dijo-x86_64-windows + tag: ${{ github.ref }} + overwrite: true -- cgit v1.2.3 From d7c303dda4750a432478c94b3ed41bca1352d839 Mon Sep 17 00:00:00 2001 From: Akshay Date: Thu, 23 Jul 2020 23:06:22 +0530 Subject: enable feature based compilation to support windows --- .github/workflows/main.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e2995b8..5c3e6f9 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -39,7 +39,7 @@ jobs: && sudo apt-get install -y \ libdbus-1-dev - name: Build - run: cargo build --all --release && strip target/release/dijo + run: cargo build -all --no-default-features --features unix --release && strip target/release/dijo - name: Upload binaries to release uses: svenstaro/upload-release-action@v1-release @@ -72,7 +72,7 @@ jobs: override: true - name: Build for mac - run: cargo build --all --release && strip target/release/dijo + run: cargo build --all --no-default-features --features unix --release && strip target/release/dijo - name: Upload binaries to release uses: svenstaro/upload-release-action@v1-release @@ -106,7 +106,7 @@ jobs: - name: Build for windows run: | - cargo build --all --release + cargo build --all --no-default-features --features windows --release strip target/release/dijo - name: Upload binaries to release -- cgit v1.2.3