Skip to content

Commit

Permalink
Install all dependency extras where required
Browse files Browse the repository at this point in the history
  • Loading branch information
pkalita-lbl committed Dec 17, 2024
1 parent e3a1a73 commit 93d15a6
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 34 deletions.
31 changes: 9 additions & 22 deletions .github/workflows/deploy_documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,37 +17,24 @@ jobs:

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
#----------------------------------------------
# check-out repo and set-up python
#----------------------------------------------
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
# persist-credentials: false # otherwise, the token used is the GITHUB_TOKEN, instead of your personal token
fetch-depth: 0 # otherwise, you will failed to push refs to dest repo
fetch-depth: 0

- name: Install Poetry
run: pipx install poetry

- name: Set up Python3
uses: actions/setup-python@v3
uses: actions/setup-python@v5
with:
python-version: 3.9
cache: 'poetry'

#----------------------------------------------
# install & configure poetry
#----------------------------------------------
- name: Install Poetry
uses: snok/install-poetry@v1.3

#----------------------------------------------
# install dependencies if cache does not exist
#----------------------------------------------
- name: Install dependencies
# if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true'
run: poetry install --no-interaction
run: poetry install

#----------------------------------------------
# Create documentation and deploy.
#----------------------------------------------
- name: Create local docs
- name: Generate and deploy docs
run: |
mkdir docs
touch docs/.nojekyll
Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,16 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'

- name: Install dependencies
run: |
pip install tox
- name: Check code quality with flake8
run: tox -e flake8

Expand All @@ -45,7 +48,7 @@ jobs:
cache: 'poetry'

- name: Install dependencies
run: poetry install
run: poetry install --all-extras

- name: Run test suite
run: make test
18 changes: 8 additions & 10 deletions .github/workflows/pypi-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,21 +16,19 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Install Poetry
run: |
pipx install poetry
pipx inject poetry "poetry-dynamic-versioning[plugin]"
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.9
cache: pip
cache-dependency-path: '**/pyproject.toml'

- name: Install Poetry
run: pip install poetry poetry-dynamic-versioning
python-version: '3.12'
cache: poetry

- name: Install dependencies
run: poetry install --no-interaction

- name: Add dynamic versioning plugin
run: poetry self add "poetry-dynamic-versioning[plugin]"
run: poetry install --all-extras

- name: Build source and wheel archives
run: poetry build
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ status: check-config
setup: install gen-project gendoc git-init-add

install:
poetry install
poetry install --all-extras
.PHONY: install

all: gen-project gendoc
Expand Down

0 comments on commit 93d15a6

Please sign in to comment.