-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #16 from capn-freako/5-add-a-makefile
5 add a makefile
- Loading branch information
Showing
18 changed files
with
533 additions
and
507 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
# Makefile for PyChOpMarg project. | ||
# | ||
# Original author: David Banas <[email protected]> | ||
# Original date: November 4, 2024 | ||
# | ||
# Copyright (c) 2024 David Banas; all rights reserved World wide. | ||
|
||
.PHONY: dflt help check tox format lint flake8 type-check docs build upload test clean etags conda-build conda-skeleton chaco enable pyibis-ami pyibis-ami-dev pybert pybert-dev etags | ||
|
||
PROJ_NAME := PyChOpMarg | ||
PROJ_FILE := pyproject.toml | ||
PROJ_INFO := src/PyChOpMarg.egg-info/PKG-INFO | ||
VER_FILE := .proj_ver | ||
VER_GETTER := ./get_proj_ver.py | ||
PYTHON_EXEC := python -I | ||
TOX_EXEC := tox | ||
TOX_SKIP_ENV := format | ||
PYVERS := 310 311 312 313 | ||
PLATFORMS := lin mac win | ||
|
||
# Put it first so that "make" without arguments is like "make help". | ||
dflt: help | ||
|
||
check: | ||
${TOX_EXEC} run -e check | ||
|
||
${VER_FILE}: ${PROJ_INFO} | ||
${PYTHON_EXEC} ${VER_GETTER} ${PROJ_NAME} $@ | ||
|
||
${PROJ_INFO}: ${PROJ_FILE} | ||
${PYTHON_EXEC} -m build | ||
${PYTHON_EXEC} -m pip install -e . | ||
|
||
tox: | ||
TOX_SKIP_ENV="${TOX_SKIP_ENV}" ${TOX_EXEC} -m test | ||
|
||
format: | ||
${TOX_EXEC} run -e format | ||
|
||
lint: | ||
${TOX_EXEC} run -e lint | ||
|
||
flake8: | ||
${TOX_EXEC} run -e flake8 | ||
|
||
type-check: | ||
${TOX_EXEC} run -e type-check | ||
|
||
docs: ${VER_FILE} | ||
source $< && ${TOX_EXEC} run -e docs | ||
|
||
build: ${VER_FILE} | ||
${TOX_EXEC} run -e build | ||
|
||
upload: ${VER_FILE} | ||
source $< && ${TOX_EXEC} run -e upload | ||
|
||
test: | ||
@for V in ${PYVERS}; do \ | ||
for P in ${PLATFORMS}; do \ | ||
${TOX_EXEC} run -e "py$$V-$$P"; \ | ||
done; \ | ||
done | ||
|
||
clean: | ||
rm -rf .tox docs/build/ .mypy_cache .pytest_cache .venv | ||
|
||
help: | ||
@echo "Available targets:" | ||
@echo " tox: Run all Tox environments." | ||
@echo " check: Validate the 'pyproject.toml' file." | ||
@echo " format: Run Tox 'format' environment." | ||
@echo " This will run EXTREME reformatting on the code. Use with caution!" | ||
@echo " lint: Run Tox 'lint' environment. (Runs 'pylint' on the source code.)" | ||
@echo " flake8: Run Tox 'flake8' environment. (Runs 'flake8' on the source code.)" | ||
@echo " type-check: Run Tox 'type-check' environment. (Runs 'mypy' on the source code.)" | ||
@echo " docs: Run Tox 'docs' environment. (Runs 'sphinx' on the source code.)" | ||
@echo " To view the resultant API documentation, open 'docs/build/index.html' in a browser." | ||
@echo " build: Run Tox 'build' environment." | ||
@echo " Builds source tarball and wheel, for installing or uploading to PyPi." | ||
@echo " upload: Run Tox 'upload' environment." | ||
@echo " Uploads source tarball and wheel to PyPi." | ||
@echo " (Only David Banas can do this.)" | ||
@echo " test: Run Tox testing for all supported Python versions." | ||
@echo " clean: Remove all previous build results, virtual environments, and cache contents." |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/usr/bin/env python | ||
|
||
""" | ||
Get the project version from `pyproject.toml`, | ||
and write it to the given (Bash) file. | ||
""" | ||
|
||
import sys | ||
from importlib.metadata import version | ||
|
||
def main(): | ||
proj_name = sys.argv[1] | ||
file_name = sys.argv[2] | ||
with open(file_name, "wt") as f: | ||
f.write(f"export PROJ_VER={version(proj_name)}\n") | ||
|
||
if __name__ == "__main__": | ||
main() |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,7 +9,7 @@ build-backend = "setuptools.build_meta" | |
[project] | ||
name = "PyChOpMarg" | ||
description = "Python implementation of COM, as per IEEE 802.3-22 Annex 93A/178A." | ||
version = "2.0.1" | ||
version = "2.1.1" | ||
authors = [{name = "David Banas", email = "[email protected]"}] | ||
urls = { documentation = "https://pychopmarg.readthedocs.io/en/latest/"} | ||
readme = "README.md" | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,141 +1,133 @@ | ||
alabaster==0.7.16 | ||
anyio==4.3.0 | ||
appnope==0.1.4 | ||
anyio==4.6.2.post1 | ||
argon2-cffi==23.1.0 | ||
argon2-cffi-bindings==21.2.0 | ||
arrow==1.3.0 | ||
asttokens==2.4.1 | ||
async-lru==2.0.4 | ||
attrs==23.2.0 | ||
autodocsumm==0.2.12 | ||
Babel==2.14.0 | ||
attrs==24.2.0 | ||
babel==2.16.0 | ||
beautifulsoup4==4.12.3 | ||
bleach==6.1.0 | ||
build==1.1.1 | ||
cachetools==5.3.3 | ||
certifi==2024.2.2 | ||
cffi==1.16.0 | ||
chardet==5.2.0 | ||
charset-normalizer==3.3.2 | ||
build==1.2.2.post1 | ||
certifi==2024.8.30 | ||
cffi==1.17.1 | ||
charset-normalizer==3.4.0 | ||
click==8.1.7 | ||
colorama==0.4.6 | ||
comm==0.2.1 | ||
contourpy==1.2.0 | ||
comm==0.2.2 | ||
contourpy==1.3.0 | ||
cycler==0.12.1 | ||
Cython==0.29.37 | ||
debugpy==1.8.1 | ||
debugpy==1.8.7 | ||
decorator==5.1.1 | ||
defusedxml==0.7.1 | ||
distlib==0.3.8 | ||
docutils==0.20.1 | ||
executing==2.0.1 | ||
fastjsonschema==2.19.1 | ||
filelock==3.13.1 | ||
fonttools==4.49.0 | ||
docutils==0.21.2 | ||
executing==2.1.0 | ||
fastjsonschema==2.20.0 | ||
fonttools==4.54.1 | ||
fqdn==1.5.1 | ||
h11==0.14.0 | ||
httpcore==1.0.4 | ||
httpx==0.27.0 | ||
idna==3.6 | ||
imagesize==1.4.1 | ||
ipykernel==6.29.3 | ||
ipython==8.22.1 | ||
ipywidgets==8.1.2 | ||
httpcore==1.0.6 | ||
httpx==0.27.2 | ||
idna==3.10 | ||
importlib_metadata==8.5.0 | ||
ipykernel==6.29.5 | ||
ipython==8.28.0 | ||
ipywidgets==8.1.5 | ||
isoduration==20.11.0 | ||
jaraco.classes==3.4.0 | ||
jaraco.context==6.0.1 | ||
jaraco.functools==4.1.0 | ||
jedi==0.19.1 | ||
Jinja2==3.1.3 | ||
json5==0.9.18 | ||
jsonpointer==2.4 | ||
jsonschema==4.21.1 | ||
jsonschema-specifications==2023.12.1 | ||
jupyter==1.0.0 | ||
Jinja2==3.1.4 | ||
json5==0.9.25 | ||
jsonpointer==3.0.0 | ||
jsonschema==4.23.0 | ||
jsonschema-specifications==2024.10.1 | ||
jupyter==1.1.1 | ||
jupyter-console==6.6.3 | ||
jupyter-events==0.9.0 | ||
jupyter-lsp==2.2.3 | ||
jupyter_client==8.6.0 | ||
jupyter_core==5.7.1 | ||
jupyter_server==2.12.5 | ||
jupyter_server_terminals==0.5.2 | ||
jupyterlab==4.1.2 | ||
jupyter-events==0.10.0 | ||
jupyter-lsp==2.2.5 | ||
jupyter_client==8.6.3 | ||
jupyter_core==5.7.2 | ||
jupyter_server==2.14.2 | ||
jupyter_server_terminals==0.5.3 | ||
jupyterlab==4.2.5 | ||
jupyterlab_execute_time==3.2.0 | ||
jupyterlab_pygments==0.3.0 | ||
jupyterlab_server==2.25.3 | ||
jupyterlab_widgets==3.0.10 | ||
kiwisolver==1.4.5 | ||
MarkupSafe==2.1.5 | ||
matplotlib==3.8.3 | ||
matplotlib-inline==0.1.6 | ||
jupyterlab_server==2.27.3 | ||
jupyterlab_widgets==3.0.13 | ||
keyring==25.5.0 | ||
kiwisolver==1.4.7 | ||
markdown-it-py==3.0.0 | ||
MarkupSafe==3.0.2 | ||
matplotlib==3.9.2 | ||
matplotlib-inline==0.1.7 | ||
mdurl==0.1.2 | ||
mistune==3.0.2 | ||
nbclient==0.9.0 | ||
nbconvert==7.16.1 | ||
nbformat==5.9.2 | ||
more-itertools==10.5.0 | ||
nbclient==0.10.0 | ||
nbconvert==7.16.4 | ||
nbformat==5.10.4 | ||
nest-asyncio==1.6.0 | ||
notebook==7.1.1 | ||
nh3==0.2.18 | ||
notebook==7.2.2 | ||
notebook_shim==0.2.4 | ||
numpy==1.23.2 | ||
oldest-supported-numpy==2023.12.21 | ||
numpy==2.1.2 | ||
overrides==7.7.0 | ||
packaging==23.2 | ||
pandas==2.2.1 | ||
packaging==24.1 | ||
pandas==2.2.3 | ||
pandocfilters==1.5.1 | ||
parso==0.8.3 | ||
pexpect==4.9.0 | ||
pillow==10.2.0 | ||
platformdirs==4.2.0 | ||
pluggy==1.4.0 | ||
prometheus_client==0.20.0 | ||
prompt-toolkit==3.0.43 | ||
psutil==5.9.8 | ||
ptyprocess==0.7.0 | ||
pure-eval==0.2.2 | ||
PyChOpMarg @ file:///Users/dbanas/prj/PyChOpMarg | ||
pycparser==2.21 | ||
pyface==8.0.0 | ||
Pygments==2.17.2 | ||
pyparsing==3.1.1 | ||
pyproject-api==1.6.1 | ||
pyproject_hooks==1.0.0 | ||
parso==0.8.4 | ||
pillow==11.0.0 | ||
pkginfo==1.10.0 | ||
platformdirs==4.3.6 | ||
prometheus_client==0.21.0 | ||
prompt_toolkit==3.0.48 | ||
psutil==6.1.0 | ||
pure_eval==0.2.3 | ||
-e git+ssh://[email protected]/capn-freako/PyChOpMarg.git@828247b74cf9db7d4e3438cc2df1363a558b1e36#egg=PyChOpMarg | ||
pycparser==2.22 | ||
Pygments==2.18.0 | ||
pyparsing==3.2.0 | ||
pyproject_hooks==1.2.0 | ||
python-dateutil==2.9.0.post0 | ||
python-json-logger==2.0.7 | ||
pytz==2024.1 | ||
PyYAML==6.0.1 | ||
pyzmq==25.1.2 | ||
qtconsole==5.5.1 | ||
QtPy==2.4.1 | ||
referencing==0.33.0 | ||
requests==2.31.0 | ||
pytz==2024.2 | ||
pywin32==308 | ||
pywin32-ctypes==0.2.3 | ||
pywinpty==2.0.14 | ||
PyYAML==6.0.2 | ||
pyzmq==26.2.0 | ||
readme_renderer==44.0 | ||
referencing==0.35.1 | ||
requests==2.32.3 | ||
requests-toolbelt==1.0.0 | ||
rfc3339-validator==0.1.4 | ||
rfc3986==2.0.0 | ||
rfc3986-validator==0.1.1 | ||
rpds-py==0.18.0 | ||
scikit-rf==0.32.0 | ||
scipy==1.12.0 | ||
Send2Trash==1.8.2 | ||
rich==13.9.3 | ||
rpds-py==0.20.0 | ||
scikit-rf==1.3.0 | ||
scipy==1.14.1 | ||
Send2Trash==1.8.3 | ||
setuptools==75.2.0 | ||
six==1.16.0 | ||
sniffio==1.3.1 | ||
snowballstemmer==2.2.0 | ||
soupsieve==2.5 | ||
Sphinx==7.2.6 | ||
sphinxcontrib-applehelp==1.0.8 | ||
sphinxcontrib-devhelp==1.0.6 | ||
sphinxcontrib-htmlhelp==2.0.5 | ||
sphinxcontrib-jsmath==1.0.1 | ||
sphinxcontrib-qthelp==1.0.7 | ||
sphinxcontrib-serializinghtml==1.1.10 | ||
soupsieve==2.6 | ||
stack-data==0.6.3 | ||
swig==3.0.12 | ||
terminado==0.18.0 | ||
tinycss2==1.2.1 | ||
tornado==6.4 | ||
tox==4.14.2 | ||
traitlets==5.14.1 | ||
traits==6.4.3 | ||
traitsui==8.0.0 | ||
types-python-dateutil==2.8.19.20240106 | ||
tzdata==2024.1 | ||
terminado==0.18.1 | ||
tinycss2==1.3.0 | ||
tornado==6.4.1 | ||
traitlets==5.14.3 | ||
twine==5.1.1 | ||
types-python-dateutil==2.9.0.20241003 | ||
typing_extensions==4.12.2 | ||
tzdata==2024.2 | ||
uri-template==1.3.0 | ||
urllib3==2.2.1 | ||
virtualenv==20.25.1 | ||
urllib3==2.2.3 | ||
wcwidth==0.2.13 | ||
webcolors==1.13 | ||
webcolors==24.8.0 | ||
webencodings==0.5.1 | ||
websocket-client==1.7.0 | ||
widgetsnbextension==4.0.10 | ||
websocket-client==1.8.0 | ||
widgetsnbextension==4.0.13 | ||
zipp==3.20.2 |
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
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
Oops, something went wrong.