From 63233b2c197180cef2006a4324c22cac3ac0f98d Mon Sep 17 00:00:00 2001 From: Windel Bouwman Date: Wed, 1 Jul 2020 19:06:14 +0200 Subject: [PATCH] Add archive artifact step. --- .github/workflows/ci.yml | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d9e793e..589f277 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,13 +21,14 @@ jobs: name: Build on windows runs-on: windows-latest steps: - - uses: actions/checkout@v2 - - name: Rust toolchain installation + - name: Checkout source code + uses: actions/checkout@v2 + - name: Install rust toolchain uses: actions-rs/toolchain@v1 with: toolchain: stable profile: minimal - - name: Install vcpkg dependencies + - name: Install vcpkg and dependencies env: vcpkgResponseFile: ${{github.workspace}}/.github/workflows/response_file.txt uses: lukka/run-vcpkg@v3 @@ -36,5 +37,23 @@ jobs: vcpkgGitCommitId: 6185aa76504a5025f36754324abf307cc776f3da vcpkgArguments: '@${{env.vcpkgResponseFile}}' appendedCacheKey: ${{hashFiles(env.vcpkgResponseFile)}} - - run: cargo build --release -p lognplot + - name: Fix gtk lib files + run: | + Copy-Item ${{github.workspace}}\vcpkg\installed\x64-windows\lib\gtk-3.0.lib -Destination ${{github.workspace}}\vcpkg\installed\x64-windows\lib\gtk-3.lib + Copy-Item ${{github.workspace}}\vcpkg\installed\x64-windows\lib\gdk-3.0.lib -Destination ${{github.workspace}}\vcpkg\installed\x64-windows\lib\gdk-3.lib + Copy-Item ${{github.workspace}}\vcpkg\installed\x64-windows\bin\gtk-3.0.dll -Destination ${{github.workspace}}\vcpkg\installed\x64-windows\bin\gtk-3.dll + Copy-Item ${{github.workspace}}\vcpkg\installed\x64-windows\bin\gdk-3.0.dll -Destination ${{github.workspace}}\vcpkg\installed\x64-windows\bin\gdk-3.dll + - name: Add vcpkg bin folder to path + run: echo "::add-path::${{github.workspace}}\vcpkg\installed\x64-windows\bin" + - name: Build rust code + env: + HDF5_DIR: ${{github.workspace}}\vcpkg\installed\x64-windows + GTK_LIB_DIR: ${{github.workspace}}\vcpkg\installed\x64-windows\lib + LIB: ${{github.workspace}}\vcpkg\installed\x64-windows\lib + run: cargo build --release -p lognplotgtk -p lognplot -p clognplot - run: cargo test -p lognplot + - name: Archive executable + uses: actions/upload-artifact@v2 + with: + name: app + path: target/release/*.exe \ No newline at end of file