Skip to content

Commit

Permalink
Preparation for release on PyPI (#87)
Browse files Browse the repository at this point in the history
* Update Python Versions (#82)

* Update python minimum to 3.10 in pyproject.toml.

* Add notes to README and docs to detail minimum python version as 3.10

* Update workflows to use 3.10 as minimum python version, add 3.12 as latest, and update actions to latest versions.

* Fix linting issue (use strict in zip) that arises with minimum version being 3.10.

* Update to explicit TypeAlias in targets, with note thqat this is deprecated in favour of  in python 3.12+.

* Update ready for PyPI upload.

* Set version to 1.0.0

* Update License to use real name instead of GitHub username.

* Update README with badges.

* Fix location specifier for a local install.
  • Loading branch information
jatkinson1000 committed Jun 8, 2024
1 parent 0698980 commit bdece30
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 22 deletions.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2022 jatkinson1000
Copyright (c) 2022 Jack Atkinson

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
# archeryutils

[![PyPI - Version](https://img.shields.io/pypi/v/archeryutils)](https://pypi.org/project/archeryutils)
![GitHub](https://img.shields.io/github/license/jatkinson1000/archeryutils)
[![Documentation Status](https://readthedocs.org/projects/archeryutils/badge/?version=latest)](https://archeryutils.readthedocs.io/en/latest/?badge=latest)
![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/jatkinson1000/archeryutils/testing.yaml)
[![codecov](https://codecov.io/gh/jatkinson1000/archeryutils/branch/main/graph/badge.svg?token=AZU7G6H8T0)](https://codecov.io/gh/jatkinson1000/archeryutils)
[![Python 3.10+](https://img.shields.io/badge/python-3.10+-blue.svg)](https://www.python.org/downloads/)
[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
[![Python 3.10+](https://img.shields.io/badge/python-3.10+-blue.svg)](https://www.python.org/downloads/)
[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/jatkinson1000/archeryutils/main?labpath=examples.ipynb)

A collection of archery code and utilities in python.\
Expand Down Expand Up @@ -37,14 +38,14 @@ It is appreciated if visible credit is given by any projects using `archeryutils
### Installation
To install the library via pip for use in a project you can run:

python -m pip install git+https://github.com/jatkinson1000/archeryutils.git
pip install archeryutils

It is recommended to use a virtual environment.

If you want a local install that you can edit instead, clone the repository,
navigate to `/archeryutils`, and run:
navigate to `archeryutils/`, and run:

python3 -m pip install .
python3 -m pip install -e .[test,lint,docs]

Please refer to the online documentation for
[full installation guidance](https://archeryutils.readthedocs.io/en/latest/getting-started/installation.html).
Expand Down
4 changes: 2 additions & 2 deletions docs/getting-started/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Installation Instructions
archeryutils is a pure python package.
It can be installed using pip by executing::

python -m pip install git+https://github.com/jatkinson1000/archeryutils.git
pip install archeryutils

Development Installation
------------------------
Expand All @@ -27,7 +27,7 @@ install as an editable package::

git clone [email protected]:jatkinson1000/archeryutils.git
cd archeryutils
pip install -e .
pip install -e .[test,int,docs]

Testing
~~~~~~~
Expand Down
24 changes: 9 additions & 15 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ build-backend = "setuptools.build_meta"

[project]
name = "archeryutils"
version = "0.1.1"
description = "A collection of archery utilities in python"
version = "1.0.0"
description = "A collection of archery utilities in python."
authors = [
{ name="Jack Atkinson", email="[email protected]" },
]
Expand All @@ -14,18 +14,15 @@ license = {file = "LICENSE"}
requires-python = ">=3.10"
classifiers = [
"License :: OSI Approved :: MIT License",
"Development Status :: 3 - Alpha",
"Development Status :: 5 - Production/Stable",
"Natural Language :: English",
"Programming Language :: Python :: 3",
"Programming Language :: Python",
"Programming Language :: Python :: 3 :: Only",
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Typing :: Typed',
"Operating System :: OS Independent",
'Operating System :: Unix',
'Operating System :: MacOS',
'Operating System :: Microsoft :: Windows',
# "Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
"numpy>=1.20.0",
Expand Down Expand Up @@ -57,15 +54,15 @@ docs = [

[project.urls]
"Homepage" = "https://github.com/jatkinson1000/archeryutils"
"Bug Tracker" = "https://github.com/jatkinson1000/archeryutils/Issues"
"Bug Tracker" = "https://github.com/jatkinson1000/archeryutils/issues"
"Documentation" = "https://archeryutils.readthedocs.io/"
"Repository" = "https://github.com/jatkinson1000/archeryutils"

[tool.setuptools]
# By default, include-package-data is true in pyproject.toml, so you do
# NOT have to specify this line.
include-package-data = true

#[tool.setuptools.packages]
#find = {}
[tool.setuptools.packages.find]
where = ["."] # list of folders that contain the packages (["."] by default)
include = ["archeryutils", "archeryutils.*"] # package names should match these glob patterns (["*"] by default)
Expand All @@ -75,9 +72,6 @@ namespaces = false # to disable scanning PEP 420 namespaces (true by default)
[tool.setuptools.package-data]
archeryutils = ["*.json", "round_data_files/*.json", "classifications/*.json"]

#[options.extras_require]
#tests = pytest

[tool.mypy]
warn_unused_configs = true
plugins = ["numpy.typing.mypy_plugin"]
Expand Down Expand Up @@ -113,5 +107,5 @@ convention = "numpy"

[tool.ruff.lint.per-file-ignores]
# Ignore S101 (use of assert) in tests
# Ignore PLR2004 (magic values) in tests as we regularly want to compare to a numerical value
# Ignore PLR2004 (magic values) in tests as we regularly compare to a numerical value
"**/tests/*" = ["S101", "PLR2004"]

0 comments on commit bdece30

Please sign in to comment.