Skip to content

Commit

Permalink
add pypi publish and bump version number
Browse files Browse the repository at this point in the history
  • Loading branch information
LukasHedegaard committed Mar 19, 2020
1 parent 90b9194 commit 4ce9d33
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 4 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Publish to TestPyPI

on:
push:
branches:
- master

jobs:
build-n-publish:
name: Build and publish to PyPI
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags')
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@master
- name: Set up Python 3.7
uses: actions/setup-python@v1
with:
python-version: 3.7
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install .[build]
- name: Build
run: |
python setup.py sdist bdist_wheel
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@v1.1.0
with:
user: __token__
password: ${{ secrets.PYPI_PASSWORD }}
6 changes: 5 additions & 1 deletion .github/workflows/publishtest.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: Publish to TestPyPI

on: push
on:
push:
branches:
- master

jobs:
build-n-publish:
Expand All @@ -22,5 +25,6 @@ jobs:
- name: Publish to Test PyPI
uses: pypa/gh-action-pypi-publish@v1.1.0
with:
user: __token__
password: ${{ secrets.TEST_PYPI_PASSWORD }}
repository_url: https://test.pypi.org/legacy/
8 changes: 6 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,13 @@ build:
python setup.py sdist bdist_wheel


## Upload to PyPI
publish:
## Upload to TestPyPI
test-publish:
python -m twine upload --repository-url https://test.pypi.org/legacy/ dist/*


publish:
python -m twine upload dist/*


#################################################################################
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

setup(
name="datasetops",
version="0.0.3",
version="0.0.4",
author="Lukas Hedegaard",
description="Friendly dataset operations for your data science needs",
long_description=long_description,
Expand Down

0 comments on commit 4ce9d33

Please sign in to comment.