Skip to content

Commit

Permalink
Merge pull request pypa#1469 from rffontenelle/add-problem-matcher
Browse files Browse the repository at this point in the history
Add problem matcher for test-translations.yml
  • Loading branch information
webknjaz authored Jan 26, 2024
2 parents bba3413 + 0145ba5 commit dafefbc
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 1 deletion.
15 changes: 15 additions & 0 deletions .github/sphinx_lint_matcher.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"problemMatcher": [
{
"owner": "sphinx-lint-problem-matcher",
"pattern": [
{
"regexp": "^(.*):(\\d+):\\s+(.*)$",
"file": 1,
"line": 2,
"message": 3
}
]
}
]
}
10 changes: 9 additions & 1 deletion .github/workflows/test-translations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,16 +58,24 @@ jobs:
ref: ${{ env.I18N_BRANCH }}

- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: >-
3.10
- name: Install Python tooling
run: python -m pip install --upgrade nox virtualenv sphinx-lint

- name: Set Sphinx problem matcher
uses: sphinx-doc/github-problem-matcher@v1.0

- name: Build translated docs in ${{ matrix.language }}
run: nox -s build -- -q -D language=${{ matrix.language }}

- name: Set Sphinx Lint problem matcher
if: always()
run: echo '::add-matcher::.github/sphinx_lint_matcher.json'

- name: Lint translation file
if: always()
run: sphinx-lint locales/${{ matrix.language }}/LC_MESSAGES/messages.po

0 comments on commit dafefbc

Please sign in to comment.