Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
vkedwardli committed Jan 12, 2025
1 parent ed23e98 commit e30fa87
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/c-cpp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,23 @@ jobs:
hdiutil detach /Volumes/VulkanSDK
echo "VULKAN_SDK=$HOME/VulkanSDK/macOS" >> $GITHUB_ENV
if: runner.os == 'macOS'

- name: test semver
run: |
VERSION=$(git describe --tags --always --match "gdxsv-*" | sed -E "s/-([0-9]+)-g(.+)$/-dev.\\1+\\2/g")
echo $VERSION
# Check if the version is a dev version and increment the patch number
if [[ "$VERSION" =~ -dev\.([0-9]+) ]]; then
# Extract the current patch version
PATCH_VERSION="${BASH_REMATCH[1]}"
# Increment the patch version
PATCH_VERSION=$((PATCH_VERSION + 1))
# Replace the old patch version with the new one
VERSION=$(echo "$VERSION" | sed -E "s/-dev\.[0-9]+/-dev.${PATCH_VERSION}/")
fi
echo $VERSION
shell: bash

- name: Set up build environment (Linux)
run: |
Expand Down

0 comments on commit e30fa87

Please sign in to comment.