From 3deb6983b0e3d41a81d034eba4664360b5e1d681 Mon Sep 17 00:00:00 2001 From: kdeng00 Date: Tue, 22 Jul 2025 21:41:26 -0400 Subject: [PATCH 1/5] Added release workflow --- .github/workflows/release.yaml | 51 ++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 .github/workflows/release.yaml diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml new file mode 100644 index 0000000..ab56f2a --- /dev/null +++ b/.github/workflows/release.yaml @@ -0,0 +1,51 @@ +name: Release Tagging + +on: + push: + branches: + - v0.2 + +jobs: + release: + runs-on: ubuntu-24.04 + steps: + - name: Checkout code + uses: actions/checkout@v3 + with: + fetch-depth: 0 # Important for git describe --tags + + - name: Install Rust + uses: actions-rs/toolchain@v1 + with: + toolchain: 1.88.0 + components: cargo + + - name: Extract Version from Cargo.toml + id: version + run: | + VERSION=$(grep '^version = "' Cargo.toml | sed -E 's/version = "([^"]+)"/\1/') + PROJECT_COMMIT_HASH=$(git rev-parse HEAD | cut -c 1-10) + BRANCH_REF="${GITHUB_REF}" + BRANCH_NAME=$(echo "$BRANCH_REF" | cut -d '/' -f 3) + PROJECT_TAG_RELEASE="v$VERSION-$BRANCH_NAME-$PROJECT_COMMIT_HASH" + echo "::set-output name=project_tag_release::$PROJECT_TAG_RELEASE-961" + echo "Version: $VERSION" + echo "Hash: $PROJECT_COMMIT_HASH" + echo "Branch: $BRANCH_NAME" + echo "Tag Release: $PROJECT_TAG_RELEASE" + + - name: Print version + id: Version + run: | + echo "Printing version" + echo "Version: ${{ steps.version.outputs.project_tag_release }}" + + - name: Create GitHub Release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ steps.version.outputs.project_tag_release }} + release_name: Release ${{ steps.version.outputs.project_tag_release }} + body: | + Release of version ${{ steps.version.outputs.project_tag_release }} -- 2.47.3 From c8108cfb395639ac703831c394ca4ae3717e2d99 Mon Sep 17 00:00:00 2001 From: kdeng00 Date: Tue, 22 Jul 2025 21:43:25 -0400 Subject: [PATCH 2/5] Temp change --- .github/workflows/release.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index ab56f2a..7e34ddd 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -2,8 +2,9 @@ name: Release Tagging on: push: - branches: - - v0.2 + branches: [ "v0.2" ] + pull_request: + branches: [ "v0.2" ] jobs: release: -- 2.47.3 From 226a475e757f8ef94a5b7c257d61052adc17c9f5 Mon Sep 17 00:00:00 2001 From: kdeng00 Date: Tue, 22 Jul 2025 21:46:18 -0400 Subject: [PATCH 3/5] File extension change --- .github/workflows/{release.yaml => release.yml} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/workflows/{release.yaml => release.yml} (100%) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yml similarity index 100% rename from .github/workflows/release.yaml rename to .github/workflows/release.yml -- 2.47.3 From ecd5705272867c6ae00dd3ff1c41afe639157660 Mon Sep 17 00:00:00 2001 From: kdeng00 Date: Tue, 22 Jul 2025 21:48:40 -0400 Subject: [PATCH 4/5] Syntax change --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 7e34ddd..5b2a48f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -36,7 +36,7 @@ jobs: echo "Tag Release: $PROJECT_TAG_RELEASE" - name: Print version - id: Version + id: print_version run: | echo "Printing version" echo "Version: ${{ steps.version.outputs.project_tag_release }}" -- 2.47.3 From e9e098902a48468a7b15146895a1c96e88bb71a1 Mon Sep 17 00:00:00 2001 From: kdeng00 Date: Tue, 22 Jul 2025 21:50:54 -0400 Subject: [PATCH 5/5] Removing that temp change --- .github/workflows/release.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 5b2a48f..f67ddac 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -3,8 +3,6 @@ name: Release Tagging on: push: branches: [ "v0.2" ] - pull_request: - branches: [ "v0.2" ] jobs: release: -- 2.47.3