Skip to content

Commit 445ab80

Browse files
author
Maximiliano Greco
authored
Create pypi_wheel.yml (#20)
* Create pypi_wheel.yml * doc(readme): cleanup badge and license section * bld: update setup metadata * bld: restore removed line which find packages * update makefile
1 parent b6e06dc commit 445ab80

File tree

5 files changed

+53
-15
lines changed

5 files changed

+53
-15
lines changed

.github/workflows/pypi_wheel.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Python package build and publish
2+
3+
on:
4+
release:
5+
types: [created]
6+
7+
jobs:
8+
deploy:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v2
12+
- name: Set up Python
13+
uses: actions/setup-python@v1
14+
with:
15+
python-version: 3.8
16+
- name: Install dependencies
17+
run: |
18+
python -m pip install --upgrade pip
19+
pip install twine flake8
20+
- name: Lint with flake8 for syntax errors
21+
run: |
22+
pip install flake8
23+
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
24+
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
25+
- name: Build manylinux Python wheels
26+
uses: RalfG/[email protected]_x86_64
27+
with:
28+
python-versions: 'cp36-cp36m cp37-cp37m'
29+
build-requirements: 'cython numpy'
30+
- name: Publish wheels to PyPI
31+
env:
32+
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
33+
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
34+
run: |
35+
twine upload dist/*-manylinux*.whl

Makefile

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,4 +30,7 @@ vim:
3030

3131
.PHONY: build
3232
build:
33-
pipenv run python setup.py sdist bdist_wheel
33+
python setup.py sdist bdist_wheel
34+
35+
docker:
36+
docker run -v ${PWD}:/git/$(shell basename ${PWD}) -w /git/$(shell basename ${PWD}) -it python:3.9 /bin/bash

README.md

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
[![Build Status](https://travis-ci.org/mmngreco/IneqPy.svg?branch=master)](https://travis-ci.org/mmngreco/IneqPy)
2-
[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fmmngreco%2FIneqPy.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2Fmmngreco%2FIneqPy?ref=badge_shield)
1+
![Build Status](https://github.com/mmngreco/ineqpy/actions/workflows/python-package.yml/badge.svg)
2+
33

44
IneqPy Package
55
==============
@@ -235,6 +235,3 @@ Statistics:
235235
>>> df.theil(main_var) = 0.156137490566
236236
```
237237

238-
239-
## License
240-
[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fmmngreco%2FIneqPy.svg?type=large)](https://app.fossa.io/projects/git%2Bgithub.com%2Fmmngreco%2FIneqPy?ref=badge_large)

setup.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[metadata]
2-
description-file = README.rst
2+
description-file = README.md
33

44
[versioneer]
55
VCS = git

setup.py

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,33 @@
11
import versioneer
2-
from setuptools import find_packages, setup
2+
from setuptools import setup, find_packages
33

4-
with open("README.md") as f:
4+
5+
with open('README.md') as f:
56
description = f.read()
67

8+
79
setup(
810
name="IneqPy",
911
version=versioneer.get_version(),
12+
cmdclass=versioneer.get_cmdclass(),
1013
description="A Python Package To Quantitative Analysis Of Inequality",
1114
long_description=description,
15+
long_description_content_type='text/markdown',
1216
author="Maximiliano Greco",
1317
author_email="[email protected]",
1418
url="https://github.com/mmngreco/IneqPy",
15-
# download_url='https://github.com/mmngreco/IneqPy/tarball/',
1619
package_dir={'': 'src'},
1720
packages=find_packages("src"),
1821
classifiers=[
1922
"Development Status :: 3 - Alpha",
2023
"Intended Audience :: Science/Research",
2124
"License :: OSI Approved :: MIT License",
2225
"Programming Language :: Python :: 3",
23-
"Programming Language :: Python :: 3.2",
24-
"Programming Language :: Python :: 3.3",
25-
"Programming Language :: Python :: 3.4",
26-
"Programming Language :: Python :: 3.5",
26+
"Programming Language :: Python :: 3.6",
27+
"Programming Language :: Python :: 3.7",
28+
"Programming Language :: Python :: 3.8",
29+
"Programming Language :: Python :: 3.9",
30+
"Programming Language :: Python :: 3.10",
2731
],
2832
install_requires=["numpy", "pandas", "numba"],
29-
cmdclass=versioneer.get_cmdclass(),
3033
)

0 commit comments

Comments
 (0)