Skip to content

Commit

Permalink
Add check for coverage.xml file and fail job if it doesn't exist
Browse files Browse the repository at this point in the history
  • Loading branch information
jkaeske committed Dec 28, 2023
1 parent 9e6fd51 commit 408e3f8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,16 @@ jobs:
- name: Run tests with tox
run: tox -e py${{ matrix.python-version }}

- name: List files
run: ls -la

- name: Check coverage.xml
- name: Check for coverage.xml file
run: |
if [ -f coverage.xml ]; then
echo "coverage.xml exists at $(pwd)"
else
echo "coverage.xml does not exist in $(pwd)"
ls -la # List files to debug
exit 1 # Fail the job if coverage.xml does not exist
fi
shell: bash

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@
dist/*
.venv
.env
coverage.xml
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Django i18n Lint

[![codecov](https://codecov.io/gh/jkaeske/django-i18n-lint/graph/badge.svg?token=8t1WWUxxav)](https://codecov.io/gh/jkaeske/django-i18n-lint)

A simple script to find non-i18n text in a Django template.

Note: Since Django 3.1 the template tag was update from `{% trans "" %}` to `{% translate "" %}` and from `{% blocktrans "" %}` to `{% blocktranslate "" %}`.
Expand Down

0 comments on commit 408e3f8

Please sign in to comment.