Skip to content

Commit

Permalink
chore: dev install with environment.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
mdtanker committed Dec 12, 2024
1 parent 6b6affc commit 74b9afd
Show file tree
Hide file tree
Showing 4 changed files with 75 additions and 9 deletions.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ print-% : ; @echo $* = $($*)
####

create:
mamba create --name $(PROJECT) --yes --force --channel conda-forge pygmt geopandas python=3.11
mamba env create --file environment.yml

install:
pip install -e .[all]
pip install --no-deps -e .

remove:
mamba remove --name $(PROJECT) --all
mamba env remove --name $(PROJECT) --yes

pip_install:
pip install $(PROJECT)[all]==$(VERSION)
Expand Down
1 change: 1 addition & 0 deletions docs/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -396,6 +396,7 @@ Now, when submitting a PR, RTD will automatically build the docs and update the
* wait for a PR to be opened in the [feedstock](https://github.com/conda-forge/polartoolkit-feedstock)
* update any changed dependencies in the feedstock PR and merge
* wait for `conda` to publish the new version [here](https://anaconda.org/conda-forge/polartoolkit)
* manually add dependency changes to `environment.yml`
* update backup `env/environment.yml`
* update polartoolkit version in `environment.yml` in [PolarToolkit-Binder repo](https://github.com/mdtanker/polartoolkit-binder/blob/main/environment.yml)
* test `PyPI` version with:
Expand Down
65 changes: 65 additions & 0 deletions environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: polartoolkit
channels:
- conda-forge
- nodefaults
dependencies:
- python=3.12
# Required dependencies
- pandas
- openpyxl
- pooch
- tqdm
- verde>=1.8.0
- xarray
- harmonica>=0.6.0
- pyproj
- rioxarray
- scipy
- numpy
- pygmt>=0.10.0
- geopandas<1.0
- zarr
- python-dotenv
- requests
- deprecation
- earthaccess
# Optional dependencies
# interactive
- geoviews
- cartopy
- ipyleaflet
- ipython
# test
- pytest>=6
- pytest-cov>=3
- deepdiff
# docs
- sphinx>=4.0
- sphinx-book-theme>=0.3
- nbsphinx
- nbconvert
- sphinxcontrib-bibtex
# - ipython # repeat
# included with pip below
# - myst_parser
# - sphinx_copybutton
# - sphinx_autoapi
# - sphinx_autodoc_typehints
# - sphinx_design
# dev
- nox
- pre-commit
- pylint>=3.2
- python-semantic-release>=8
- ipykernel
- jupyterlab
- mypy
- pathspec
# below packages need to be installed with pip
- pip
- pip:
- sphinx_design
- sphinx_copybutton
- sphinx_autodoc_typehints
- sphinx_autoapi
- myst_parser
12 changes: 6 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ keywords = ["cryosphere", "antarctica", "arctic", "greenland", "maps", "plotting

dependencies = [
"pandas",
"openpyxl",
"openpyxl", # needed for fetch.ghf to read an excel file into pandas
"pooch",
"tqdm",
"verde>=1.8.0",
Expand Down Expand Up @@ -68,16 +68,16 @@ test = [
]
docs = [
"sphinx>=4.0",
"myst_parser",
"sphinx_copybutton",
"sphinx_autoapi",
"sphinx_autodoc_typehints",
"sphinx-book-theme>=0.3",
"sphinx_design",
"nbsphinx",
"nbconvert",
"sphinxcontrib-bibtex",
"ipython",
"myst_parser",
"sphinx_copybutton",
"sphinx_autoapi",
"sphinx_autodoc_typehints",
"sphinx_design",
]
dev = [
"polartoolkit[interactive,test,docs]",
Expand Down

0 comments on commit 74b9afd

Please # to comment.