Merge pull request #240 from nasa/bug/pf_ordering #28
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: Release | |
on: | |
push: | |
branches: | |
- 'release/**' | |
- 'master' | |
jobs: | |
analysis: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: ['3.9'] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install prog_models | |
run: | | |
python -m pip install git+https://github.com/nasa/prog_models.git@dev | |
- name: Lint with flake8 | |
run: | | |
python -m pip install flake8 | |
# stop the build if there are Python syntax errors or undefined names | |
flake8 src/prog_algs --count --select=E9,F63,F7,F82 --show-source --statistics | |
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide | |
flake8 src/prog_algs --count --benchmark --exit-zero --show-source --max-complexity=10 --max-line-length=127 --statistics --tee --output-file=lint_results_${{ matrix.python-version }}.txt | |
- name: Upload Lint Results | |
uses: actions/upload-artifact@v2 | |
with: | |
name: lint_results_${{matrix.python-version}} | |
path: lint_results_${{matrix.python-version}}.txt | |
- name: Initialize CodeQL | |
uses: github/codeql-action/init@v1 | |
with: | |
languages: 'python' | |
- name: Perform CodeQL Analysis | |
uses: github/codeql-action/analyze@v1 |