Metadata-Version: 2.1
Name: biocommons.example
Version: 0.0.4
Summary: Example Package
Author-email: biocommons contributors <biocommons-dev@googlegroups.com>
Project-URL: Homepage, https://github.com/biocommons/biocommons.example
Project-URL: Bug Tracker, https://github.com/biocommons/biocommons.example/issues
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: coloredlogs~=15.0
Requires-Dist: pyyaml~=6.0
Provides-Extra: dev
Requires-Dist: bandit~=1.7; extra == "dev"
Requires-Dist: black~=22.3; extra == "dev"
Requires-Dist: build~=0.8; extra == "dev"
Requires-Dist: flake8~=4.0; extra == "dev"
Requires-Dist: ipython~=8.4; extra == "dev"
Requires-Dist: isort~=5.10; extra == "dev"
Requires-Dist: mypy; extra == "dev"
Requires-Dist: pre-commit~=3.4; extra == "dev"
Requires-Dist: pylint~=2.14; extra == "dev"
Requires-Dist: pytest-cov~=4.1; extra == "dev"
Requires-Dist: pytest-optional-tests; extra == "dev"
Requires-Dist: pytest~=7.1; extra == "dev"
Requires-Dist: tox~=3.25; extra == "dev"
Requires-Dist: vcrpy; extra == "dev"
Provides-Extra: docs
Requires-Dist: mkdocs; extra == "docs"

# biocommons.example Test Package

[![codecov](https://codecov.io/gh/biocommons/biocommons.example/graph/badge.svg?token=CCUMQQV5R6)](https://codecov.io/gh/biocommons/biocommons.example)

This repo provides a template for biocommons Python packages.  Here's how to use it:

1. Click the [Use this template](https://github.com/biocommons/example/generate)
   button. Name the new repo like "biocommons.something".
1. Clone your repo locally.
1. In the repo, type `make rename`. The new name will be chosen based on the repo name.
1. Remove this header.
1. Commit and push.

## Installation

To install from pypi: ```pip install biocommons.example```

## Developer Setup

Setup like this:

    make devready
    source venv/bin/activate

Code reformatting:

    make reformat

Install pre-commit hook:

    # included in `make devready`, not necessary for new installations
    pre-commit install

Test:

    make test   # for current environment
    make tox    # for Python 3.9 and Python 3.10

Build:

    git tag 0.0.0
    make build

Try it:

    $ python3 -m biocommons.example
    Marvin says:
    There's only one life-form as intelligent as me within thirty parsecs...
           
    $ marvin-quote 
    Marvin says:
    You think you've got problems? What are you supposed to do if you...
    
    $ ipython
    >>> from biocommons.example import __version__, get_quote_from_marvin
    >>> __version__
    '0.1.dev8+gd5519a8.d20211123'
    >>> get_quote()
    "The first ten million years were the worst, ...


# Features

## Code structure and features

* Modern pyproject.toml with setuptools
* Versioning based on git tag (only)
* Easy development setup
* Support for namespaces
* Testing with coverage using pytest; tests may be in `tests/`, embedded in the package, and in doc strings
* Examples for logging and package data
* Command-line with argument parsing with argparse

## DevOps

* Quality tools: Code reformatting with black and isort
* GitHub Actions for testing and packaging
