constellation/.github/actions/pseudo_version/action.yml

25 lines
823 B
YAML
Raw Normal View History

name: Determine pseudo version
description: "Determine go-like pseudo version to use as container image tag."
outputs:
2023-03-14 09:53:33 -04:00
version:
description: "Version based on branch name"
value: ${{ steps.pseudo-version.outputs.version }}
branchName:
description: "Branch name"
value: ${{ steps.pseudo-version.outputs.branchName }}
runs:
using: "composite"
steps:
2023-03-14 09:53:33 -04:00
- name: get version
id: pseudo-version
shell: bash
env:
WORKSPACE_STATUS_TOOL: ${{ github.workspace }}/tools/workspace_status.sh
run: |
version=$(${WORKSPACE_STATUS_TOOL} | grep STABLE_STAMP_VERSION | cut -d ' ' -f2)
branchName=$(git branch --show-current | tr '/' '-')
echo "version=v${version}" | tee -a "$GITHUB_OUTPUT"
echo "branchName=${branchName}" | tee -a "$GITHUB_OUTPUT"