extension_ci: Fix main repository version bumps (#51515)

Release Notes:

- N/A
This commit is contained in:
Finn Evers authored and GitHub committed 2026-03-13 18:07:56 +00:00
1 parent 49624f4454
commit 466df9e47c
2 files changed
+63 -16

No files matched your search

+25 -3
View File
@@ -83,6 +83,11 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
clean: false
- name: steps::cache_rust_dependencies_namespace
uses: namespacelabs/nscloud-cache-action@v1
with:
cache: rust
path: ~/.rustup
- name: extension_bump::install_bump_2_version
run: pip install bump2version --break-system-packages
- id: bump-version
@@ -139,7 +144,7 @@ jobs:
token: ${{ steps.generate-token.outputs.token }}
sign-commits: true
assignees: ${{ github.actor }}
timeout-minutes: 3
timeout-minutes: 5
defaults:
run:
shell: bash -euxo pipefail {0}
@@ -160,6 +165,21 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
clean: false
- id: determine-tag
name: extension_bump::determine_tag
run: |
EXTENSION_ID="$(sed -n 's/^id = "\(.*\)"/\1/p' < extension.toml | head -1 | tr -d '[:space:]')"
if [[ "$WORKING_DIR" == "." || -z "$WORKING_DIR" ]]; then
TAG="v${CURRENT_VERSION}"
else
TAG="${EXTENSION_ID}-v${CURRENT_VERSION}"
fi
echo "tag=${TAG}" >> "$GITHUB_OUTPUT"
env:
CURRENT_VERSION: ${{ needs.check_version_changed.outputs.current_version }}
WORKING_DIR: ${{ inputs.working-directory }}
- name: extension_bump::create_version_tag
uses: actions/github-script@v7
with:
@@ -167,10 +187,12 @@ jobs:
github.rest.git.createRef({
owner: context.repo.owner,
repo: context.repo.repo,
ref: 'refs/tags/v${{ needs.check_version_changed.outputs.current_version }}',
ref: 'refs/tags/${{ steps.determine-tag.outputs.tag }}',
sha: context.sha
})
github-token: ${{ steps.generate-token.outputs.token }}
outputs:
tag: ${{ steps.determine-tag.outputs.tag }}
timeout-minutes: 1
defaults:
run:
@@ -206,7 +228,7 @@ jobs:
with:
extension-name: ${{ steps.get-extension-id.outputs.extension_id }}
push-to: zed-industries/extensions
tag: v${{ needs.check_version_changed.outputs.current_version }}
tag: ${{ needs.create_version_label.outputs.tag }}
env:
COMMITTER_TOKEN: ${{ steps.generate-token.outputs.token }}
defaults: