Skip to content

Commit 278945c

Browse files
committed
Initial commit
0 parents  commit 278945c

29 files changed

Lines changed: 1541 additions & 0 deletions

.coveragerc

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# .coveragerc to control coverage.py
2+
[run]
3+
branch = True
4+
source = celldex
5+
# omit = bad_file.py
6+
7+
[paths]
8+
source =
9+
src/
10+
*/site-packages/
11+
12+
[report]
13+
# Regexes for lines to exclude from consideration
14+
exclude_lines =
15+
# Have to re-enable the standard pragma
16+
pragma: no cover
17+
18+
# Don't complain about missing debug-only code:
19+
def __repr__
20+
if self\.debug
21+
22+
# Don't complain if tests don't hit defensive assertion code:
23+
raise AssertionError
24+
raise NotImplementedError
25+
26+
# Don't complain if non-runnable code isn't run:
27+
if 0:
28+
if __name__ == .__main__.:

.github/workflows/pypi-publish.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# This workflow will install Python dependencies, run tests and lint with a single version of Python
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
3+
4+
name: Publish to PyPI
5+
6+
on:
7+
push:
8+
tags: "*"
9+
10+
jobs:
11+
build:
12+
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- uses: actions/checkout@v2
17+
- name: Set up Python 3.9
18+
uses: actions/setup-python@v2
19+
with:
20+
python-version: 3.9
21+
- name: Install dependencies
22+
run: |
23+
python -m pip install --upgrade pip
24+
pip install flake8 pytest tox
25+
# - name: Lint with flake8
26+
# run: |
27+
# # stop the build if there are Python syntax errors or undefined names
28+
# flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
29+
# # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
30+
# # flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
31+
- name: Test with tox
32+
run: |
33+
tox
34+
- name: Build docs
35+
run: |
36+
tox -e docs
37+
- run: touch ./docs/_build/html/.nojekyll
38+
- name: GH Pages Deployment
39+
uses: JamesIves/github-pages-deploy-action@4.1.3
40+
with:
41+
branch: gh-pages # The branch the action should deploy to.
42+
folder: ./docs/_build/html
43+
clean: true # Automatically remove deleted files from the deploy branch
44+
- name: Build Project and Publish
45+
run: |
46+
python -m tox -e clean,build
47+
- name: Publish package
48+
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
49+
with:
50+
user: __token__
51+
password: ${{ secrets.PYPI_PASSWORD }}

.github/workflows/pypi-test.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Test the library
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
pull_request:
7+
branches: [ master ]
8+
9+
jobs:
10+
build:
11+
12+
runs-on: ubuntu-latest
13+
strategy:
14+
matrix:
15+
python-version: [ '3.8', '3.9', '3.10', '3.11', '3.12' ]
16+
17+
name: Python ${{ matrix.python-version }}
18+
steps:
19+
- uses: actions/checkout@v2
20+
- name: Setup Python
21+
uses: actions/setup-python@v2
22+
with:
23+
python-version: ${{ matrix.python-version }}
24+
cache: 'pip'
25+
- name: Install dependencies
26+
run: |
27+
python -m pip install --upgrade pip
28+
pip install flake8 pytest tox
29+
# - name: Lint with flake8
30+
# run: |
31+
# # stop the build if there are Python syntax errors or undefined names
32+
# flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
33+
# # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
34+
# # flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
35+
- name: Test with tox
36+
run: |
37+
tox

.gitignore

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# Temporary and binary files
2+
*~
3+
*.py[cod]
4+
*.so
5+
*.cfg
6+
!.isort.cfg
7+
!setup.cfg
8+
*.orig
9+
*.log
10+
*.pot
11+
__pycache__/*
12+
.cache/*
13+
.*.swp
14+
*/.ipynb_checkpoints/*
15+
.DS_Store
16+
17+
# Project files
18+
.ropeproject
19+
.project
20+
.pydevproject
21+
.settings
22+
.idea
23+
.vscode
24+
tags
25+
26+
# Package files
27+
*.egg
28+
*.eggs/
29+
.installed.cfg
30+
*.egg-info
31+
32+
# Unittest and coverage
33+
htmlcov/*
34+
.coverage
35+
.coverage.*
36+
.tox
37+
junit*.xml
38+
coverage.xml
39+
.pytest_cache/
40+
41+
# Build and docs folder/files
42+
build/*
43+
dist/*
44+
sdist/*
45+
docs/api/*
46+
docs/_rst/*
47+
docs/_build/*
48+
cover/*
49+
MANIFEST
50+
51+
# Per-project virtualenvs
52+
.venv*/
53+
.conda*/
54+
.python-version

.pre-commit-config.yaml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
exclude: '^docs/conf.py'
2+
3+
repos:
4+
- repo: https://github.com/pre-commit/pre-commit-hooks
5+
rev: v4.6.0
6+
hooks:
7+
- id: trailing-whitespace
8+
- id: check-added-large-files
9+
- id: check-ast
10+
- id: check-json
11+
- id: check-merge-conflict
12+
- id: check-xml
13+
- id: check-yaml
14+
- id: debug-statements
15+
- id: end-of-file-fixer
16+
- id: requirements-txt-fixer
17+
- id: mixed-line-ending
18+
args: ['--fix=auto'] # replace 'auto' with 'lf' to enforce Linux/Mac line endings or 'crlf' for Windows
19+
20+
- repo: https://github.com/PyCQA/docformatter
21+
rev: v1.7.5
22+
hooks:
23+
- id: docformatter
24+
additional_dependencies: [tomli]
25+
args: [--in-place, --wrap-descriptions=120, --wrap-summaries=120]
26+
# --config, ./pyproject.toml
27+
28+
- repo: https://github.com/psf/black
29+
rev: 24.4.0
30+
hooks:
31+
- id: black
32+
language_version: python3
33+
34+
- repo: https://github.com/astral-sh/ruff-pre-commit
35+
# Ruff version.
36+
rev: v0.3.7
37+
hooks:
38+
- id: ruff
39+
args: [--fix, --exit-non-zero-on-fix]
40+
41+
## If like to embrace black styles even in the docs:
42+
# - repo: https://github.com/asottile/blacken-docs
43+
# rev: v1.13.0
44+
# hooks:
45+
# - id: blacken-docs
46+
# additional_dependencies: [black]
47+
48+
## Check for misspells in documentation files:
49+
# - repo: https://github.com/codespell-project/codespell
50+
# rev: v2.2.5
51+
# hooks:
52+
# - id: codespell

.readthedocs.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Read the Docs configuration file
2+
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
3+
4+
# Required
5+
version: 2
6+
7+
# Build documentation in the docs/ directory with Sphinx
8+
sphinx:
9+
configuration: docs/conf.py
10+
11+
# Build documentation with MkDocs
12+
#mkdocs:
13+
# configuration: mkdocs.yml
14+
15+
# Optionally build your docs in additional formats such as PDF
16+
formats:
17+
- pdf
18+
19+
build:
20+
os: ubuntu-22.04
21+
tools:
22+
python: "3.11"
23+
24+
python:
25+
install:
26+
- requirements: docs/requirements.txt
27+
- {path: ., method: pip}

AUTHORS.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Contributors
2+
3+
* Jayaram Kancherla [jayaram.kancherla@gmail.com](mailto:jayaram.kancherla@gmail.com)

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Changelog
2+
3+
## Version 0.1 (development)
4+
5+
- Feature A added
6+
- FIX: nasty bug #1729 fixed
7+
- add your changes here!

0 commit comments

Comments
 (0)