[DVT-911] Add database id (#118) #54
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: polycli-releaser | |
on: | |
push: | |
# run only against tags | |
tags: | |
- "*" | |
permissions: | |
contents: write | |
# packages: write | |
# issues: write | |
env: | |
GO_VERSION: "1.20" | |
jobs: | |
manual-release: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-go@v3 | |
with: | |
go-version: ${{ env.GO_VERSION }} | |
- name: perform cross build and compress binaries | |
shell: bash | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y gcc-aarch64-linux-gnu | |
pwd | |
make cross | |
pushd out | |
echo -n "${{github.ref_name}}" | sed 's/^v//' | tee ref_name.txt | |
readonly tag_name="$(cat ref_name.txt)" | |
echo "$tag_name" | |
mkdir polycli_${tag_name}_darwin_amd64/ | |
mv darwin-amd64-polycli polycli_${tag_name}_darwin_amd64/polycli | |
tar czf polycli_${tag_name}_darwin_amd64.tar.gz polycli_${tag_name}_darwin_amd64/ | |
mkdir polycli_${tag_name}_darwin_arm64/ | |
mv darwin-arm64-polycli polycli_${tag_name}_darwin_arm64/polycli | |
tar czf polycli_${tag_name}_darwin_arm64.tar.gz polycli_${tag_name}_darwin_arm64/ | |
mkdir polycli_${tag_name}_linux_amd64/ | |
mv linux-amd64-polycli polycli_${tag_name}_linux_amd64/polycli | |
tar czf polycli_${tag_name}_linux_amd64.tar.gz polycli_${tag_name}_linux_amd64/ | |
mkdir polycli_${tag_name}_linux_arm64/ | |
mv linux-arm64-polycli polycli_${tag_name}_linux_arm64/polycli | |
tar czf polycli_${tag_name}_linux_arm64.tar.gz polycli_${tag_name}_linux_arm64/ | |
popd | |
- name: publish binaries | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: out/*.tar.gz | |
tag: ${{ github.ref }} | |
overwrite: true | |
file_glob: true |