Skip to content

Commit

Permalink
Add step for testing install of binary package
Browse files Browse the repository at this point in the history
  • Loading branch information
alex1701c committed Nov 3, 2024
1 parent e4bdaca commit 7edd148
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,22 @@ jobs:
cpack | tee cpack.out
filepath=$(sed -nr 's/.*package: (.+) generated\./\1/p' cpack.out)
echo "filepath=$filepath" >> "$GITHUB_OUTPUT"
- name: Test install of binary packages
shell: bash
run: |
binary_file="${{ steps.cpack.outputs.filepath }}"
# Detect and install using the correct package manager
if [[ "${{ matrix.os }}" == "ubuntu" ]]; then
sudo apt update
sudo apt install -y "$binary_file"
elif [[ "${{ matrix.os }}" == "fedora" ]]; then
sudo dnf install -y "$binary_file"
elif [[ "${{ matrix.os }}" == "opensuse" ]]; then
sudo zypper install -y "$binary_file"
else
echo "Unsupported OS"
exit 1
fi
- uses: actions/upload-artifact@v4
if: inputs.publish-version
Expand Down

0 comments on commit 7edd148

Please sign in to comment.