Skip to content

Commit b8e3a84

Browse files
ci: align versions from generated branch output (mistralai#514)
1 parent 109ee43 commit b8e3a84

3 files changed

Lines changed: 18 additions & 9 deletions

File tree

.github/workflows/sdk_generation_mistralai_azure_sdk.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ jobs:
4444
set_version: ${{ github.event.inputs.set_version }}
4545
speakeasy_version: ${{ needs.resolve-speakeasy-version.outputs.version }}
4646
target: mistralai-azure-sdk
47+
feature_branch: speakeasy-sdk-regen-${{ github.run_id }}
4748
secrets:
4849
github_access_token: ${{ secrets.CLIENT_PIPELINE }}
4950
pypi_token: ${{ secrets.PYPI_TOKEN }}
@@ -57,10 +58,12 @@ jobs:
5758
id: find-pr
5859
env:
5960
GH_TOKEN: ${{ secrets.CLIENT_PIPELINE }}
61+
SPEAKEASY_BRANCH: speakeasy-sdk-regen-${{ github.run_id }}
6062
run: |
61-
PR_BRANCH=$(gh pr list --repo ${{ github.repository }} --author "app/github-actions" \
62-
--json headRefName,updatedAt --jq 'sort_by(.updatedAt) | reverse | .[0].headRefName // empty')
63-
echo "branch=$PR_BRANCH" >> $GITHUB_OUTPUT
63+
set -euo pipefail
64+
PR_BRANCH="$SPEAKEASY_BRANCH"
65+
echo "Using Speakeasy generated branch: $PR_BRANCH"
66+
echo "branch=$PR_BRANCH" >> "$GITHUB_OUTPUT"
6467
6568
- name: Checkout PR branch
6669
if: steps.find-pr.outputs.branch != ''

.github/workflows/sdk_generation_mistralai_gcp_sdk.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ jobs:
4444
set_version: ${{ github.event.inputs.set_version }}
4545
speakeasy_version: ${{ needs.resolve-speakeasy-version.outputs.version }}
4646
target: mistralai-gcp-sdk
47+
feature_branch: speakeasy-sdk-regen-${{ github.run_id }}
4748
secrets:
4849
github_access_token: ${{ secrets.CLIENT_PIPELINE }}
4950
pypi_token: ${{ secrets.PYPI_TOKEN }}
@@ -57,10 +58,12 @@ jobs:
5758
id: find-pr
5859
env:
5960
GH_TOKEN: ${{ secrets.CLIENT_PIPELINE }}
61+
SPEAKEASY_BRANCH: speakeasy-sdk-regen-${{ github.run_id }}
6062
run: |
61-
PR_BRANCH=$(gh pr list --repo ${{ github.repository }} --author "app/github-actions" \
62-
--json headRefName,updatedAt --jq 'sort_by(.updatedAt) | reverse | .[0].headRefName // empty')
63-
echo "branch=$PR_BRANCH" >> $GITHUB_OUTPUT
63+
set -euo pipefail
64+
PR_BRANCH="$SPEAKEASY_BRANCH"
65+
echo "Using Speakeasy generated branch: $PR_BRANCH"
66+
echo "branch=$PR_BRANCH" >> "$GITHUB_OUTPUT"
6467
6568
- name: Checkout PR branch
6669
if: steps.find-pr.outputs.branch != ''

.github/workflows/sdk_generation_mistralai_sdk.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ jobs:
4444
set_version: ${{ github.event.inputs.set_version }}
4545
speakeasy_version: ${{ needs.resolve-speakeasy-version.outputs.version }}
4646
target: mistralai-sdk
47+
feature_branch: speakeasy-sdk-regen-${{ github.run_id }}
4748
secrets:
4849
github_access_token: ${{ secrets.CLIENT_PIPELINE }}
4950
pypi_token: ${{ secrets.PYPI_TOKEN }}
@@ -57,10 +58,12 @@ jobs:
5758
id: find-pr
5859
env:
5960
GH_TOKEN: ${{ secrets.CLIENT_PIPELINE }}
61+
SPEAKEASY_BRANCH: speakeasy-sdk-regen-${{ github.run_id }}
6062
run: |
61-
PR_BRANCH=$(gh pr list --repo ${{ github.repository }} --author "app/github-actions" \
62-
--json headRefName,updatedAt --jq 'sort_by(.updatedAt) | reverse | .[0].headRefName // empty')
63-
echo "branch=$PR_BRANCH" >> $GITHUB_OUTPUT
63+
set -euo pipefail
64+
PR_BRANCH="$SPEAKEASY_BRANCH"
65+
echo "Using Speakeasy generated branch: $PR_BRANCH"
66+
echo "branch=$PR_BRANCH" >> "$GITHUB_OUTPUT"
6467
6568
- name: Checkout PR branch
6669
if: steps.find-pr.outputs.branch != ''

0 commit comments

Comments
 (0)