NO_JIRA Added Pharmacophore generator script to create CrossMiner que… #100
This file contains hidden or 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: Lint Python | |
| on: # yamllint disable-line rule:truthy | |
| pull_request: | |
| paths: | |
| - "**/*.py" | |
| jobs: | |
| flake8: | |
| runs-on: ubuntu-latest | |
| outputs: | |
| changed-files: ${{ steps.file-changes.outputs.changed-files }} | |
| strategy: | |
| matrix: | |
| python_version: ["3.11"] | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| fetch-depth: 0 | |
| - name: Modified files | |
| id: file-changes | |
| run: | | |
| echo \ | |
| "changed-files=$(git diff --name-only -r origin/${GITHUB_BASE_REF} origin/${GITHUB_HEAD_REF} \ | |
| | grep '\.py' \ | |
| | tr '\n' ' ')" \ | |
| >> $GITHUB_OUTPUT | |
| - name: Check GitHub event type to determine reporter type | |
| run: | | |
| if [ "${{ github.event_name }}" == "pull_request" ]; then | |
| echo "REVIEWDOG_REPORTER=github-pr-review" >> $GITHUB_ENV | |
| else | |
| echo "REVIEWDOG_REPORTER=github-check" >> $GITHUB_ENV | |
| fi | |
| - name: Set up Python environment | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ matrix.python_version }} | |
| - name: Lint Python | |
| uses: reviewdog/action-flake8@v3 | |
| with: | |
| fail_level: none | |
| filter_mode: added | |
| level: error | |
| flake8_args: ${{ steps.file-changes.outputs.changed-files }} | |
| reporter: ${{ env.REVIEWDOG_REPORTER }} |