Skip to content

Commit

Permalink
Replace setup.py with pyproject.toml, update CI (#182)
Browse files Browse the repository at this point in the history
* update ci workflows and env file

* uncomment mambaforge version

* replace Mambaforge with Miniforge

* Fix Miniforge name

* fix version

* update unit tests

* fix variable name

* add python 3.12 to test matrix

* Replace setup.py with pyproject.toml file

* update version in pyproject.toml, use mamba runner instead of miniconda

* add comma

* put version in __init__.py
  • Loading branch information
chrisjonesBSU authored Jan 24, 2025
1 parent c2ad068 commit 0376b05
Show file tree
Hide file tree
Showing 5 changed files with 52 additions and 127 deletions.
17 changes: 7 additions & 10 deletions .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,11 @@ jobs:
uses: actions/checkout@v4

- name: Build environment
uses: conda-incubator/setup-miniconda@v3
uses: mamba-org/setup-micromamba@v2
with:
environment-file: environment-dev.yml
python-version: ${{ matrix.python-version }}
miniforge-variant: Miniforge3
miniforge-version: 24.11.0-0
use-mamba: true
create-args: >-
python=${{ matrix.python-version }}
- name: Install package
shell: bash -l {0}
Expand All @@ -56,7 +54,7 @@ jobs:
run: python -m pytest -rs -v --cov=./ --cov-report=xml

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
Expand Down Expand Up @@ -99,12 +97,11 @@ jobs:
uses: actions/checkout@v4

- name: Build environment
uses: conda-incubator/setup-miniconda@v3
uses: mamba-org/setup-micromamba@v2
with:
environment-file: environment-dev.yml
miniforge-variant: Miniforge3
miniforge-version: 24.11.0-0
use-mamba: true
create-args: >-
python=3.12
- name: Install package
shell: bash -l {0}
Expand Down
2 changes: 2 additions & 0 deletions flowermd/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,5 @@
Simulation,
System,
)

__version__ = "1.3.1"
3 changes: 0 additions & 3 deletions flowermd/__version__.py

This file was deleted.

43 changes: 43 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
[build-system]
requires = ["setuptools>=61.2", "versioningit"]
build-backend = "setuptools.build_meta"

[project]
name = "flowermd"
description = "Framework for building and running coplex simulaiton workflows with MosDeF and HOOMD-Blue."
readme = "README.md"
authors = [
{name = "Chris Jones", email = "[email protected]"},
{name = "Marjan Albooyeh", email = "[email protected]"},
{name = "Eric Jankowski", email = "[email protected]"}
]
license= {text = "GPLv3"}
classifiers=[
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
]
urls = {Homepage = "https://github.com/cmelab/flowermd"}
requires-python = ">=3.10"
dynamic = ["version"]

[tool.setuptools]
zip-safe = false
include-package-data = true
license-files = ["LICENSE"]

[tool.setuptools.packages]
find = {namespaces = false}

[tool.setuptools.package-data]
flowermd = [
'"modules/**"',
'"library/**"',
'"assets/forcefields/**"',
'"assets/molecule_files/**"',
'"utils/**"',
'"internal/**"',
]

[tool.setuptools.dynamic]
version = {attr = "flowermd.__version__"}
114 changes: 0 additions & 114 deletions setup.py

This file was deleted.

0 comments on commit 0376b05

Please sign in to comment.