-
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.
* Bump version to v0.1.0-alpha * Fix warning * Add relaese action * Fix publish.yml * Fix publish.yml * Skip test CI when tags pushed * Fix publish.yml * Fix publish.yml * Fix publish.yml * Fix publish.yml * Fix publish.yml * Fix publish.yml * Fix publish.yml * Change repository * verbose * Debug * Debug * Debug * Skip test of numpy.ipynb * Fix * Remove redundant import
- Loading branch information
Ryosuke Kamesawa
authored
Mar 21, 2020
1 parent
c4f4899
commit 71b2d82
Showing
7 changed files
with
114 additions
and
14 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,96 @@ | ||
name: Publish | ||
|
||
on: | ||
release: | ||
types: [created] | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu-latest, macos-latest] | ||
python: [3.6, 3.7, 3.8] | ||
include: | ||
- python: 3.6 | ||
python-name: cp36 | ||
- python: 3.7 | ||
python-name: cp37 | ||
- python: 3.8 | ||
python-name: cp38 | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Setup Python environment | ||
uses: actions/setup-python@v1.1.1 | ||
with: | ||
# Version range or exact version of a Python version to use, using semvers version range syntax. | ||
python-version: ${{ matrix.python }} # optional, default is 3.x | ||
# The target architecture (x86, x64) of the Python interpreter. | ||
architecture: x64 # optional, default is x64 | ||
- name: Set up a Rust toolchain | ||
uses: hecrj/setup-rust-action@v1.3.1 | ||
with: | ||
# The toolchain name, such as stable, nightly, or 1.8.0 | ||
rust-version: nightly # optional, default is stable | ||
# The toolchain components to install, comma-separated | ||
components: clippy # optional, default is | ||
# The toolchain targets to add, comma-separated | ||
# targets: # optional, default is | ||
- name: Install build dependencies | ||
run: pip install maturin jupyter numpy twine | ||
- name: Build wheel | ||
id: build-wheel | ||
run: | | ||
maturin build --release | ||
wheel=`ls target/wheels/*${{ matrix.python-name }}*.whl` | ||
echo $wheel | ||
echo "::set-output name=wheel::$wheel" | ||
- uses: actions/upload-artifact@v1 | ||
with: | ||
name: wheels-${{ matrix.os }}-${{ matrix.python-name}} | ||
path: target/wheels | ||
|
||
upload: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, macos-latest] | ||
python-name: [cp36, cp37, cp38] | ||
|
||
needs: build | ||
steps: | ||
- name: Setup Python environment | ||
uses: actions/setup-python@v1.1.1 | ||
# with: | ||
# Version range or exact version of a Python version to use, using semvers version range syntax. | ||
# python-version: ${{ matrix.python }} # optional, default is 3.x | ||
# The target architecture (x86, x64) of the Python interpreter. | ||
# architecture: x64 # optional, default is x64 | ||
- name: Install twine | ||
run: pip install twine | ||
- name: Download artifact | ||
uses: actions/download-artifact@v1.0.0 | ||
with: | ||
name: wheels-${{ matrix.os }}-${{ matrix.python-name }} | ||
- name: Get wheel name | ||
id: wheel-name | ||
run: | | ||
ls | ||
wheel=`ls */*${{ matrix.python-name }}*.whl` | ||
echo $wheel | ||
echo "::set-output name=wheel-path::$wheel" | ||
- name: Upload to Release | ||
uses: JasonEtco/upload-to-release@v0.1.1 | ||
with: | ||
args: ${{ steps.wheel-name.outputs.wheel-path }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Upload to PyPI | ||
# run: twine upload --repository-url https://test.pypi.org/legacy/ -u emakryo ${{ steps.wheel-name.outputs.wheel-path }} | ||
run: twine upload -u emakryo ${{ steps.wheel-name.outputs.wheel-path }} | ||
env: | ||
# TWINE_PASSWORD: ${{ secrets.TEST_PYPI_PASSWORD }} | ||
TWINE_PASSWORD: $ {{ secrets.PYPI_PASSWORD }} |
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
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