Trying to figure out RCA #42

Merged
hitanshu merged 1 commits from hitanshu/CFTunnels:tags into test 2025-06-05 20:34:40 +00:00

View File

@ -23,15 +23,17 @@ jobs:
run: | run: |
export "VERSION=$(git describe --tags --abbrev=0)" >> $GITEA_ENV export "VERSION=$(git describe --tags --abbrev=0)" >> $GITEA_ENV
echo "${VERSION}" echo "${VERSION}"
export "MAJOR=$(echo ${VERSION} | /usr/bin/cut -d "." -f 1)" export "MAJOR=$(echo ${VERSION} | /usr/bin/cut -d "." -f 1)" >> $GITEA_ENV
echo "MAJOR=${MAJOR}" echo "MAJOR=${MAJOR}"
export "MINOR=$(echo ${VERSION} | cut -d "." -f 2)" export "MINOR=$(echo ${VERSION} | cut -d "." -f 2)" >> $GITEA_ENV
echo "MINOR=${MINOR}" echo "MINOR=${MINOR}"
export "PATCH=$(echo ${VERSION} | cut -d "." -f 3)" export "PATCH=$(echo ${VERSION} | cut -d "." -f 3)" >> $GITEA_ENV
echo "PATCH=${PATCH}" echo "PATCH=${PATCH}"
- name: Increment version - name: Increment version
run: | run: |
cat $GITEA_ENV export "PATCH=$((${PATCH} + 1))" >> $GITEA_ENV
export "NEW_VERSION=$(echo ${MAJOR}.${MINOR}.${PATCH})" >> $GITEA_ENV
echo "NEW_VERSION=${NEW_VERSION}"
- name: Extract commit message - name: Extract commit message
run: echo "COMMIT_MESSAGE=$(git log -1 --pretty=%B)" run: echo "COMMIT_MESSAGE=$(git log -1 --pretty=%B)"
- name: Create and push tag - name: Create and push tag