Skip to content

Commit

Permalink
Fix version regex for cosign and annotate (#2669)
Browse files Browse the repository at this point in the history
Signed-off-by: Scott Rigby <scott@r6by.com>
  • Loading branch information
scottrigby authored Nov 10, 2022
1 parent 391bf7e commit ec6ca81
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,9 @@ jobs:
break
fi
helm push "${pkg}" oci://ghcr.io/"${GITHUB_REPOSITORY_OWNER}"/charts
file=${pkg##*/}
name=${file%-*}
version=${file%.*}
version=${version#*-}
file=${pkg##*/} # extracts file name from full directory path
name=${file%-*} # extracts chart name from filename
noext=${file%.tgz} # extracts string (NAME-1.2.3) without extension to get version below
version=${noext##*-} # extracts version
cosign sign ghcr.io/"${GITHUB_REPOSITORY_OWNER}"/charts/"${name}":"${version}"
done

0 comments on commit ec6ca81

Please sign in to comment.