Skip to content

Commit 0d64c0f

Browse files
authored
Fix README auto-update workflow to trigger CI with PAT (#2575)
* fix: update GitHub Actions token to use PAT instead of GITHUB_TOKEN * fix: update pre-commit config to include arguments.py for README command help * fix: update workflow paths to include all files in the datamodel_code_generator directory
1 parent 0260876 commit 0d64c0f

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

.github/workflows/readme.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ on:
44
push:
55
branches: [main]
66
paths:
7-
- 'src/datamodel_code_generator/__main__.py'
7+
- 'src/datamodel_code_generator/**'
88
pull_request:
99
branches: [main]
1010
paths:
11-
- 'src/datamodel_code_generator/__main__.py'
11+
- 'src/datamodel_code_generator/**'
1212

1313
permissions:
1414
contents: write
@@ -22,7 +22,7 @@ jobs:
2222
with:
2323
fetch-depth: 0
2424
ref: ${{ github.head_ref || github.ref }}
25-
token: ${{ secrets.GITHUB_TOKEN }}
25+
token: ${{ secrets.PAT }}
2626
- name: Install the latest version of uv
2727
uses: astral-sh/setup-uv@v5
2828
- name: Install tox

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,5 +38,5 @@ repos:
3838
name: Update README command help
3939
entry: bash -c 'test -x .tox/fix/bin/python || tox run -e fix --notest -qq; .tox/fix/bin/python scripts/update_command_help_on_markdown.py'
4040
language: system
41-
files: ^(src/datamodel_code_generator/__main__\.py|README\.md|docs/index\.md)$
41+
files: ^(src/datamodel_code_generator/arguments\.py|README\.md|docs/index\.md)$
4242
pass_filenames: false

0 commit comments

Comments
 (0)