mirror of
https://github.com/bitwarden/server.git
synced 2025-02-16 01:51:21 +01:00
Updating the version check to the new Github action (#2024)
* Updating the grep version check to be more strict on the new version convention * updating the way we check the version with the new github release * Fixed the release-type * switching master branch name for commit
This commit is contained in:
parent
131e6cb44e
commit
a0c049dbce
18
.github/workflows/release.yml
vendored
18
.github/workflows/release.yml
vendored
@ -38,19 +38,11 @@ jobs:
|
|||||||
|
|
||||||
- name: Check Release Version
|
- name: Check Release Version
|
||||||
id: version
|
id: version
|
||||||
run: |
|
uses: bitwarden/gh-actions@ea9fab01d76940267b4147cc1c4542431246b9f6
|
||||||
version=$( grep -o "<Version>.*</Version>" Directory.Build.props | grep -o "[0-9]*\.[0-9]*\.[0-9]*")
|
with:
|
||||||
previous_release_tag_version=$(
|
release-type: ${{ github.event.inputs.release_type }}
|
||||||
curl -sL https://api.github.com/repos/$GITHUB_REPOSITORY/releases/latest | jq -r ".tag_name"
|
project-type: csharp
|
||||||
)
|
file: Directory.Build.props
|
||||||
|
|
||||||
if [ "v$version" == "$previous_release_tag_version" ] && \
|
|
||||||
[ "${{ github.event.inputs.release_type }}" == "Initial Release" ]; then
|
|
||||||
echo "[!] Already released v$version. Please bump version to continue"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "::set-output name=package::$version"
|
|
||||||
|
|
||||||
- name: Get branch name
|
- name: Get branch name
|
||||||
id: branch
|
id: branch
|
||||||
|
Loading…
Reference in New Issue
Block a user