Skip to content

Commit

Permalink
compare versions
Browse files Browse the repository at this point in the history
  • Loading branch information
Angelyr committed Jan 4, 2025
1 parent f848e13 commit 46ddb88
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions .github/workflows/updateCmakeVersion.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,16 @@ jobs:
uses: actions/checkout@v4
with:
path: master
ref: ''
ref: 'master'

- name: Check out current
uses: actions/checkout@v4
with:
path: current
path: branch

- name: Compare Version
run: |
version1=$(grep -oP 'project\(\s*[\w-]+\s+VERSION\s+\K[0-9]+\.[0-9]+\.[0-9]+' master/CMakeLists.txt)
version2=$(grep -oP 'project\(\s*[\w-]+\s+VERSION\s+\K[0-9]+\.[0-9]+\.[0-9]+' current/CMakeLists.txt)
echo $version1
echo $version2
masterVersion=$(grep -oP 'project\(\s*[\w-]+\s+VERSION\s+\K[0-9]+\.[0-9]+\.[0-9]+' master/CMakeLists.txt)
branchVersion=$(grep -oP 'project\(\s*[\w-]+\s+VERSION\s+\K[0-9]+\.[0-9]+\.[0-9]+' branch/CMakeLists.txt)
[ "$masterVersion" != "$branchVersion" ]

0 comments on commit 46ddb88

Please sign in to comment.