From 1549edfd5529852f2945e6c534d1c15e9ccefc2e Mon Sep 17 00:00:00 2001 From: Trenton Holmes Date: Sat, 12 Mar 2022 16:36:55 -0800 Subject: [PATCH] Changes codestyle and documentation steps to use cache as well --- .github/workflows/ci.yml | 42 ++++++++++++++-------------------------- 1 file changed, 14 insertions(+), 28 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4adc9854a..bd322147c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -18,32 +18,25 @@ jobs: - name: Checkout uses: actions/checkout@v2 + - + name: Install pipenv + run: pipx install pipenv - name: Set up Python uses: actions/setup-python@v2 with: python-version: 3.9 - - - name: Get pip cache dir - id: pip-cache - run: | - echo "::set-output name=dir::$(pip cache dir)" - - - name: Persistent Github pip cache - uses: actions/cache@v2 - with: - path: ${{ steps.pip-cache.outputs.dir }} - key: ${{ runner.os }}-pip3.8} + cache: "pipenv" + cache-dependency-path: 'Pipfile.lock' - name: Install dependencies run: | - pip install --upgrade pipenv - pipenv install --system --dev --ignore-pipfile + pipenv install --dev --ignore-pipfile - name: Make documentation run: | cd docs/ - make html + pipenv run make html - name: Upload artifact uses: actions/upload-artifact@v2 @@ -57,32 +50,25 @@ jobs: - name: Checkout uses: actions/checkout@v2 + - + name: Install pipenv + run: pipx install pipenv - name: Set up Python uses: actions/setup-python@v2 with: python-version: 3.9 - - - name: Get pip cache dir - id: pip-cache - run: | - echo "::set-output name=dir::$(pip cache dir)" - - - name: Persistent Github pip cache - uses: actions/cache@v2 - with: - path: ${{ steps.pip-cache.outputs.dir }} - key: ${{ runner.os }}-pip${{ matrix.python-version }} + cache: "pipenv" + cache-dependency-path: 'Pipfile.lock' - name: Install dependencies run: | - pip install --upgrade pipenv - pipenv install --system --dev --ignore-pipfile + pipenv install --dev --ignore-pipfile - name: Codestyle run: | cd src/ - pycodestyle --max-line-length=88 --ignore=E121,E123,E126,E226,E24,E704,W503,W504,E203 + pipenv run pycodestyle --max-line-length=88 --ignore=E121,E123,E126,E226,E24,E704,W503,W504,E203 codeformatting: runs-on: ubuntu-20.04 steps: