From 5e670907ae3a167e7731703e0a4e2591d6d983c6 Mon Sep 17 00:00:00 2001 From: Trevor Royer Date: Mon, 4 Nov 2024 11:25:28 -0700 Subject: [PATCH] update version extraction --- .github/workflows/workflow-build-image.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/workflow-build-image.yaml b/.github/workflows/workflow-build-image.yaml index 821556d..a8d9d50 100644 --- a/.github/workflows/workflow-build-image.yaml +++ b/.github/workflows/workflow-build-image.yaml @@ -61,7 +61,7 @@ jobs: run: | PYPROJECT_FILE="${{ inputs.context }}/pyproject.toml" if [ -f ${PYPROJECT_FILE} ]; then - VERSION=$(awk 'NR==3 {print $3}' ${PYPROJECT_FILE} | tr -d '"') + VERSION=$(awk -F' = ' '/^version/ {gsub(/"/, "", $2); print $2}' ${PYPROJECT_FILE} | tr -d '"') echo "version=$VERSION" | tee -a $GITHUB_OUTPUT fi