Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
73 changes: 73 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@

name: Release

on:
push:
tags:
- '*.*.*'

jobs:

########################
# RELEASE CREATION JOB #
########################
job_release:
name: Create Release
runs-on: ubuntu-latest
outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
tag: ${{ steps.tag.outputs.tag }}
steps:
- name: Get tag
id: tag
run: |
echo ::set-output name=tag::${GITHUB_REF#refs/tags/}
- uses: actions/checkout@v2
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.tag.outputs.tag }}
release_name: vpype ${{ steps.tag.outputs.tag }}
draft: true
prerelease: false


##################
# UPLOAD TO PYPI #
##################
job_pypi:
name: Upload to PyPI
runs-on: ubuntu-latest
needs: job_release
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.9
uses: actions/setup-python@v2
with:
python-version: 3.9
- name: Build
id: build
run: |
pip install -r dev-requirements.txt
pip install .
python setup.py sdist bdist_wheel
echo ::set-output name=version::`python -c "import vnoise;print(vnoise.__version__)"`
- name: Upload File Assets
uses: actions/upload-release-asset@v1.0.2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.job_release.outputs.upload_url }}
asset_path: dist/vnoise-${{ steps.build.outputs.version }}.tar.gz
asset_name: vnoise-${{ steps.build.outputs.version }}.tar.gz
asset_content_type: application/gzip
- name: pypi-publish
uses: pypa/gh-action-pypi-publish@v1.4.1
with:
# repository_url: https://test.pypi.org/legacy/
password: ${{ secrets.PYPI_TOKEN }}
# skip_existing: true
verbose: true
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Change log

#### 0.1.0 (2021-02-24)

* Initial release
4 changes: 3 additions & 1 deletion dev-requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
black
isort
mypy
pytest
pytest
setuptools
wheel
22 changes: 14 additions & 8 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
from setuptools import setup
import pathlib

with open("README.md") as f:
readme = f.read()
from setuptools import setup

with open("LICENSE") as f:
license_file = f.read()
HERE = pathlib.Path(__file__).parent
readme = (HERE / "README.md").read_text()

setup(
name="vnoise",
Expand All @@ -13,13 +12,20 @@
long_description=readme,
long_description_content_type="text/markdown",
author="Antoine Beyeler",
email="abeyeler@ab-ware.com",
url="https://github.com/vpype/vnoise",
license=license_file,
author_email="abeyeler@ab-ware.com",
url="https://github.com/plottertools/vnoise",
license="MIT",
packages=["vnoise"],
python_requires=">=3.6",
install_requires=[
"numpy>=1.19",
"setuptools",
],
classifiers=[
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Topic :: Multimedia :: Graphics",
"Typing :: Typed",
],
)