-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'add-mmh3' of https://github.com/CityOfZion/neo3crypto i…
…nto add-mmh3
- Loading branch information
Showing
4 changed files
with
91 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# Builds Python wheels and create a draft release | ||
name: Build Python release | ||
|
||
on: [workflow_dispatch] | ||
|
||
jobs: | ||
build_wheels: | ||
name: Build wheels on ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-20.04, macos-11, windows-2019] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
submodules: true | ||
- name: Build wheels | ||
uses: pypa/[email protected] | ||
env: | ||
CIBW_BEFORE_BUILD_LINUX: "python3 -m pip install cmake" | ||
CIBW_BUILD: "cp38-macosx_x86_64 cp38-manylinux_x86_64 cp38-win_amd64 cp39-macosx_x86_64 cp39-manylinux_x86_64 cp39-win_amd64 cp310-macosx_x86_64 cp310-win_amd64 cp310-manylinux_x86_64" | ||
- name: Deploy | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
tag_name: Draft | ||
name: Draft | ||
draft: true | ||
files: | | ||
./wheelhouse/*.whl | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.deploy }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# Deploy the latest published release to PyPi or Test PyPi | ||
|
||
name: Release to PyPi | ||
on: | ||
workflow_dispatch: | ||
inputs: | ||
pypi-target: | ||
description: Deploy to PyPi [Main] or [Test] | ||
required: true | ||
default: 'Main' | ||
|
||
jobs: | ||
deploy-pypi: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Set up Python | ||
uses: actions/setup-python@v1 | ||
with: | ||
python-version: '3.x' | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install setuptools wheel twine | ||
- name: Download wheels | ||
uses: robinraju/[email protected] | ||
with: | ||
repository: "CityOfZion/neo3crypto" | ||
# Latest does not work on pre-release versions, it will error with a 404. | ||
latest: true | ||
tarBall: false | ||
zipBall: false | ||
# download all files | ||
fileName: "*" | ||
out-file-path: "dist" | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
- if: github.event.inputs.pypi-target == 'Main' | ||
name: Publish to PyPi | ||
env: | ||
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }} | ||
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} | ||
run: | | ||
twine upload dist/* | ||
- if: github.event.inputs.pypi-target == 'Test' | ||
name: Publish to Test-PyPi | ||
env: | ||
TWINE_USERNAME: ${{ secrets.PYPI_TEST_USERNAME }} | ||
TWINE_PASSWORD: ${{ secrets.PYPI_TEST_PASSWORD }} | ||
run: | | ||
twine upload --repository testpypi dist/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,8 +10,8 @@ | |
from setuptools.command.install_lib import install_lib as install_lib_orig | ||
from distutils.version import LooseVersion | ||
|
||
if sys.version_info < (3, 7): | ||
sys.exit('Python < 3.7 is not supported') | ||
if sys.version_info < (3, 8): | ||
sys.exit('Python < 3.8 is not supported') | ||
|
||
exclude = ['*-obj*', 'tools'] | ||
|
||
|
@@ -61,7 +61,7 @@ def build_extension(self, ext): | |
'-DPYTHON_EXECUTABLE=' + sys.executable] | ||
|
||
# cfg = 'Debug' if self.debug else 'Release' | ||
cfg = 'Debug' | ||
cfg = 'Release' | ||
build_args = ['--config', cfg] | ||
|
||
if platform.system() == "Windows": | ||
|
@@ -89,6 +89,7 @@ def build_extension(self, ext): | |
author='Erik van den Brink', | ||
author_email='[email protected]', | ||
name='neo3crypto', | ||
python_requires='>=3.8.*', | ||
description="Native crypto functions for the NEO 3 Blockchain", | ||
long_description=readme, | ||
long_description_content_type="text/x-rst", | ||
|