Merge pull request #4 from dave-shawley/release-time

Release time
This commit is contained in:
dave-shawley 2021-04-08 11:24:39 -04:00 committed by GitHub
commit cfd166c667
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 39 additions and 2 deletions

29
.github/workflows/build.yml vendored Normal file
View file

@ -0,0 +1,29 @@
name: Distribution
on:
push:
branches-ignore: ["*"]
tags: ["*"]
jobs:
upload-package:
name: "Build & upload package"
runs-on: ubuntu-latest
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') && github.repository == 'sprockets/sprockets-statsd'
steps:
- uses: actions/checkout@v2
- name: Install python
uses: actions/setup-python@v2
with:
python-version: 3.7 # use 3.7 for wheel compatibility
- name: Install builder
run: |
python -m pip install --upgrade build pip setuptools twine
- name: Build distributions
run: |
python -m build --sdist --wheel --outdir dist/ .
- name: Upload packages
uses: pypa/gh-action-pypi-publish@v1.4.2
with:
user: __token__
password: ${{ secrets.PYPI_PASSWORD }}
skip_existing: true # just in case...

3
pyproject.toml Normal file
View file

@ -0,0 +1,3 @@
[build-system]
requires = ["setuptools>=42"]
build-backend = "setuptools.build_meta"

View file

@ -3,6 +3,7 @@ name = sprockets-statsd
version = attr: sprockets_statsd.version
description = Asynchronously send metrics to a statsd instance.
long_description = file: README.rst
long_description_content_type = text/x-rst
license = BSD 3-Clause License
url = https://sprockets-statsd.readthedocs.io/
project_urls:
@ -13,7 +14,7 @@ author = Dave Shawley
author_email = daveshawley@gmail.com
classifiers =
Development Status :: 1 - Planning
Indended Audience :: Developers
Intended Audience :: Developers
License :: OSI Approved :: BSD License
Natural Language :: English
Operating System :: OS Independent
@ -51,6 +52,10 @@ readthedocs =
exclude =
tests
[options.package_data]
sprockets_statsd =
py.typed
[build_sphinx]
build_dir = build/sphinx
nitpicky = 1

View file

@ -1,2 +1,2 @@
version_info = (0, 0, 0)
version_info = (0, 0, 1)
version = '.'.join(str(c) for c in version_info)

View file