From c13d2fd11dc7997e31002d1c1a3faece21136b43 Mon Sep 17 00:00:00 2001 From: LFC <990479+MichaelScofield@users.noreply.github.com> Date: Wed, 13 Dec 2023 17:04:44 +0800 Subject: [PATCH] ci: correctly find the binary in dev-build when using "dev" profile (#2925) --- .github/actions/build-greptime-binary/action.yml | 4 +++- .github/actions/upload-artifacts/action.yml | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/actions/build-greptime-binary/action.yml b/.github/actions/build-greptime-binary/action.yml index 3cd8742d9aa9..268b76275a8b 100644 --- a/.github/actions/build-greptime-binary/action.yml +++ b/.github/actions/build-greptime-binary/action.yml @@ -40,9 +40,11 @@ runs: - name: Upload artifacts uses: ./.github/actions/upload-artifacts if: ${{ inputs.build-android-artifacts == 'false' }} + env: + PROFILE_TARGET: ${{ inputs.cargo-profile == 'dev' && 'debug' || inputs.cargo-profile }} with: artifacts-dir: ${{ inputs.artifacts-dir }} - target-file: ./target/${{ inputs.cargo-profile }}/greptime + target-file: ./target/$PROFILE_TARGET/greptime version: ${{ inputs.version }} working-dir: ${{ inputs.working-dir }} diff --git a/.github/actions/upload-artifacts/action.yml b/.github/actions/upload-artifacts/action.yml index 5c84619bf10a..4322fe7c0db2 100644 --- a/.github/actions/upload-artifacts/action.yml +++ b/.github/actions/upload-artifacts/action.yml @@ -22,7 +22,7 @@ runs: shell: bash run: | mkdir -p ${{ inputs.artifacts-dir }} && \ - mv ${{ inputs.target-file }} ${{ inputs.artifacts-dir }} + cp ${{ inputs.target-file }} ${{ inputs.artifacts-dir }} # The compressed artifacts will use the following layout: # greptime-linux-amd64-pyo3-v0.3.0sha256sum