Skip to content
This repository has been archived by the owner on Aug 8, 2024. It is now read-only.

Merge pull request #90 from JackalLabs/reports #2

Merge pull request #90 from JackalLabs/reports

Merge pull request #90 from JackalLabs/reports #2

Workflow file for this run

name: Release
on:
push:
tags:
- "v[0-9]+.[0-9]+.[0-9]+.?[0-9]*" # Push events to matching v*, i.e. v1.0, v20.15.10, v20.15.10.1
- "v[0-9]+.[0-9]+.[0-9]+-alpha.[0-9]+" # Push events to matching alpha releases
- "v[0-9]+.[0-9]+.[0-9]+-beta.[0-9]+" # Push events to matching beta releases
jobs:
native-build-cli:
runs-on: ${{matrix.os}}
strategy:
matrix:
os: [ubuntu-20.04, macos-latest]
steps:
- uses: actions/checkout@v3.5.3
- uses: actions/setup-go@v4
with:
go-version: 1.18.1 # The Go version to download (if necessary) and use.
- name: Build CLI
shell: bash
run: |
make build
cp "build/jprovd" "jprovd-$RUNNER_OS"
- uses: actions/upload-artifact@v3
with:
name: jprovd-${{runner.os}}
path: jprovd-${{runner.os}}
# MacOS-ARM64-CLI:
# runs-on: ubuntu-20.04
# steps:
# - uses: actions/checkout@v3.5.3
# - uses: actions/setup-go@v4
# with:
# go-version: 1.19 # The Go version to download (if necessary) and use.
# - name: Install xgo
# run: |
# go install github.com/crazy-max/xgo@v0.17.0
# xgo || true # check installation
# - name: Build MacOS CLI
# shell: bash
# run: |
# make build_macos_arm64_cli
# cp "jprovd-macos-arm64" "jprovd-MacOS-arm64"
# - uses: actions/upload-artifact@v3
# with:
# name: jprovd-MacOS-arm64
# path: jprovd-MacOS-arm64
Release:
needs:
[native-build-cli]
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3.5.3
- name: Get the version
id: get_version
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\/v/}
- name: Declare Commit Variables
id: is_pre_release
shell: bash
run: |
echo "::set-output name=IS_PRE_RELEASE::$(echo "${{ steps.get_version.outputs.VERSION }}" | awk 'BEGIN{prerelease="false"} /beta|alpha/{prerelease="true"} END{print prerelease}')"
- uses: actions/download-artifact@v3
with:
name: jprovd-Linux
- uses: actions/download-artifact@v3
with:
name: jprovd-macOS
- name: Release
uses: softprops/action-gh-release@v1
with:
prerelease: ${{ steps.is_pre_release.outputs.IS_PRE_RELEASE }}
files: |
jprovd-macOS
jprovd-Linux