-
-
Notifications
You must be signed in to change notification settings - Fork 617
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ci] migrate stable binaries release to github actions (#1458)
* Update setup.cfg * [ci] create binaries-release.yml * align with nightly release * Update binaries-release.yml * Update binaries-release.yml * merge master * Update binaries-release.yml * Update docs.yml Co-authored-by: vfdev <[email protected]>
- Loading branch information
Showing
2 changed files
with
41 additions
and
1 deletion.
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,41 @@ | ||
name: Stable Releases | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
build-publish: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Setup Miniconda | ||
uses: conda-incubator/setup-miniconda@v2 | ||
with: | ||
miniconda-version: "latest" | ||
python-version: 3.7 | ||
|
||
- name: Install dependencies | ||
shell: bash -l {0} | ||
run: | | ||
conda install -y pytorch torchvision cpuonly -c pytorch | ||
pip install -r requirements-dev.txt | ||
pip install --upgrade --no-cache-dir twine | ||
python setup.py install | ||
- name: Build and Publish Conda binaries | ||
shell: bash -l {0} | ||
env: | ||
ANACONDA_TOKEN: ${{ secrets.ANACONDA_TOKEN }} | ||
UPLOAD_USER: "pytorch" | ||
run: | | ||
chmod +x ./conda.recipe/build_and_upload.sh | ||
./conda.recipe/build_and_upload.sh | ||
- name: Build and Publish PyPI binaries | ||
shell: bash -l {0} | ||
run: | | ||
python setup.py sdist bdist_wheel | ||
twine check dist/* | ||
TWINE_USERNAME="${{ secrets.PYPI_USER }}" TWINE_PASSWORD="${{ secrets.PYPI_TOKEN }}" twine upload --verbose 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,6 @@ name: Build docs | |
on: | ||
push: | ||
branches: [master] | ||
tags: ["v*"] | ||
release: | ||
types: [published] | ||
|
||
|