Fix key error on getting the "testing" key on older contexts #1005
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: copyright | |
on: | |
pull_request: | |
paths: | |
- 'src/**' | |
- '!**.md' | |
push: | |
paths: | |
- 'src/**' | |
- '!**.md' | |
workflow_dispatch: | |
permissions: | |
contents: read | |
jobs: | |
main: | |
name: Enforce copyright notices | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1 | |
- name: Set up Python | |
uses: actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5.2.0 | |
with: | |
python-version: 3 | |
- name: Run copyright checker | |
run: | | |
bash ./src/build_utils/license/apply_copyright | |
if [[ "$(git status | grep modified)" != "" ]]; then | |
echo "Some sourcefiles are missing copyright notice!" 1>&2 | |
echo "Run ./src/build_utils/license/apply_copyright to apply." 1>&2 | |
exit 1 | |
fi |