Skip to content

Commit

Permalink
fix(ci): artifact building
Browse files Browse the repository at this point in the history
Signed-off-by: vados <[email protected]>
  • Loading branch information
t3hmrman committed Dec 10, 2023
1 parent 6b23299 commit 8f55448
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
11 changes: 9 additions & 2 deletions .github/workflows/build-and-test/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -127,13 +127,20 @@ runs:

# Run cargo test
- name: Build a package
if: ${{ inputs.artifact-upload }}
id: package
if: ${{ github.event_name == 'workflow_call' }}
shell: bash
env:
CARGO_HOME: ${{ inputs.cargo-home-dir }}
CARGO_TARGET_DIR: ${{ inputs.cargo-target-dir }}
SCCACHE_DIR: ${{ inputs.sccache-dir }}
CARGO_BUILD_RUSTC_WRAPPER: ${{ inputs.cargo-build-rustc-wrapper }}
CARGO_INCREMENTAL: ${{ inputs.cargo-env-incrmental }}
CARGO_PROFILE: ${{ inputs.cargo-profile }}
run: |
su idkit -c "just package"
tar -cvf pg_idkit-$(just print-version).zip $(just print-pkg-output-dir)
echo filename=pg_idkit-$(just print-version).zip >> $GITHUB_OUTPUT
echo filename=pg_idkit-v$(just print-version).zip >> $GITHUB_OUTPUT
# Upload artifact
- name: Upload artifact
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
uses: ./.github/workflows/build-rpm
with:
artifact-upload: true
artifact-name: pg_idkit-v${{ steps.version.outputs.value }}.rpm
artifact-name: pg_idkit-v${{ steps.detect-version.outputs.value }}.rpm

build-zip:
runs-on: ubuntu-latest
Expand All @@ -42,7 +42,7 @@ jobs:
uses: ./.github/workflows/build-and-test
with:
artifact-upload: true
artifact-name: pg_idkit-v${{ steps.version.outputs.value }}.zip
artifact-name: pg_idkit-v${{ steps.detect-version.outputs.value }}.zip

release:
runs-on: ubuntu-latest
Expand Down

0 comments on commit 8f55448

Please sign in to comment.