Skip to content

Commit 7aa3359

Browse files
authored
Merge branch 'main' into resource-type-slug-support
2 parents e37c377 + 6eca10c commit 7aa3359

File tree

9 files changed

+116
-156
lines changed

9 files changed

+116
-156
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ jobs:
1919
matrix:
2020
python: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13", "3.14"]
2121
steps:
22-
- uses: actions/checkout@v6
23-
- uses: astral-sh/setup-uv@v7
22+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
23+
- uses: astral-sh/setup-uv@eac588ad8def6316056a12d4907a9d4d84ff7a3b # v7.3.0
2424
with:
2525
python-version: ${{ matrix.python }}
2626
enable-cache: true
@@ -42,15 +42,15 @@ jobs:
4242

4343
smoke-test:
4444
name: Smoke test (Python ${{ matrix.python }})
45-
if: github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'version-bump')
45+
if: github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'autorelease: pending')
4646
runs-on: ubuntu-latest
4747
strategy:
4848
fail-fast: false
4949
matrix:
5050
python: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13", "3.14"]
5151
steps:
52-
- uses: actions/checkout@v6
53-
- uses: astral-sh/setup-uv@v7
52+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
53+
- uses: astral-sh/setup-uv@eac588ad8def6316056a12d4907a9d4d84ff7a3b # v7.3.0
5454
with:
5555
python-version: ${{ matrix.python }}
5656

.github/workflows/coana-analysis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616

1717
steps:
1818
- name: Checkout code
19-
uses: actions/checkout@v6
19+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2020

2121
- name: Run Coana CLI
2222
id: coana-cli

.github/workflows/coana-guardrail.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88

99
steps:
1010
- name: Checkout the ${{github.base_ref}} branch
11-
uses: actions/checkout@v6
11+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
1212
with:
1313
ref: ${{github.base_ref}} # checkout the base branch (usually master/main).
1414

@@ -22,7 +22,7 @@ jobs:
2222
echo "all_changed_files=$(git diff --name-only ${{ github.base_ref }} ${{ github.head_ref }} | tr '\n' ' ')" >> $GITHUB_OUTPUT
2323
2424
- name: Use Node.js 24.x
25-
uses: actions/setup-node@v4
25+
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
2626
with:
2727
node-version: 24.x
2828

@@ -44,7 +44,7 @@ jobs:
4444
run: sudo chown -R $USER:$USER .
4545

4646
- name: Checkout the current branch
47-
uses: actions/checkout@v6
47+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
4848
with:
4949
clean: true
5050

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Lint PR Title
2+
3+
on:
4+
pull_request_target:
5+
types:
6+
- opened
7+
- edited
8+
- synchronize
9+
10+
permissions:
11+
pull-requests: read
12+
13+
jobs:
14+
main:
15+
name: Validate PR title
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: amannn/action-semantic-pull-request@v5
19+
env:
20+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
defaults:
9+
run:
10+
shell: bash
11+
12+
jobs:
13+
release-please:
14+
runs-on: ubuntu-latest
15+
permissions:
16+
contents: write
17+
pull-requests: write
18+
outputs:
19+
release_created: ${{ steps.release.outputs.release_created }}
20+
steps:
21+
- name: Generate token
22+
id: generate-token
23+
uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf # v2.2.1
24+
with:
25+
app-id: ${{ vars.SDK_BOT_APP_ID }}
26+
private-key: ${{ secrets.SDK_BOT_PRIVATE_KEY }}
27+
28+
- name: Run release-please
29+
id: release
30+
uses: googleapis/release-please-action@7987652d64b4581673a76e33ad5e98e3dd56832f # v4.2.0
31+
with:
32+
token: ${{ steps.generate-token.outputs.token }}
33+
34+
- name: Checkout release PR branch
35+
if: steps.release.outputs.prs_created == 'true'
36+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
37+
with:
38+
ref: ${{ fromJSON(steps.release.outputs.prs)[0].headBranchName }}
39+
token: ${{ steps.generate-token.outputs.token }}
40+
41+
- name: Install uv
42+
if: steps.release.outputs.prs_created == 'true'
43+
uses: astral-sh/setup-uv@eac588ad8def6316056a12d4907a9d4d84ff7a3b # v7.3.0
44+
45+
- name: Update lockfile
46+
if: steps.release.outputs.prs_created == 'true'
47+
run: |
48+
uv lock
49+
git config user.name "workos-bot[bot]"
50+
git config user.email "workos-bot[bot]@users.noreply.github.com"
51+
git add uv.lock
52+
git diff --staged --quiet || git commit -m "chore: update uv.lock"
53+
git push
54+
55+
publish:
56+
needs: release-please
57+
if: needs.release-please.outputs.release_created == 'true'
58+
runs-on: ubuntu-latest
59+
permissions:
60+
id-token: write
61+
contents: read
62+
steps:
63+
- name: Checkout
64+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
65+
66+
- name: Install uv
67+
uses: astral-sh/setup-uv@eac588ad8def6316056a12d4907a9d4d84ff7a3b # v7.3.0
68+
69+
- name: Build
70+
run: uv build
71+
72+
- name: Publish to PyPI
73+
run: uv publish

.github/workflows/release.yml

Lines changed: 0 additions & 61 deletions
This file was deleted.

.github/workflows/version-bump.yml

Lines changed: 0 additions & 86 deletions
This file was deleted.

.release-please-manifest.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
".": "5.42.1"
3+
}

release-please-config.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"packages": {
3+
".": {
4+
"release-type": "python",
5+
"bump-minor-pre-major": true,
6+
"bump-patch-for-minor-pre-major": true,
7+
"changelog-path": "CHANGELOG.md"
8+
}
9+
},
10+
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json"
11+
}

0 commit comments

Comments
 (0)