-
Notifications
You must be signed in to change notification settings - Fork 84
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci/cd: publishing nightly packages with
devYYYYMMMDD
- Loading branch information
Showing
3 changed files
with
83 additions
and
2 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,47 @@ | ||
name: Nightly packages | ||
|
||
on: | ||
pull_request: # this shall test only the part of workflow before publishing | ||
branches: [main, "release/*"] | ||
types: [opened, reopened, ready_for_review, synchronize] | ||
paths: | ||
- ".github/workflows/release-nightly.yml" | ||
schedule: | ||
- cron: "0 0 * * 0" # on Sundays | ||
workflow_dispatch: {} | ||
|
||
defaults: | ||
run: | ||
shell: bash | ||
|
||
jobs: | ||
releasing-nightly: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: "3.10" | ||
|
||
- name: Install dependencies | ||
run: python -m pip install --user --upgrade setuptools wheel | ||
- name: Build | ||
env: | ||
CONVERT_VERSION2NIGHTLY: "1" | ||
run: python setup.py sdist bdist_wheel | ||
|
||
# We do this, since failures on test.pypi aren't that bad | ||
- name: Publish to Test PyPI | ||
if: startsWith(github.event.ref, 'refs/tags') || github.event_name == 'release' | ||
uses: pypa/[email protected] | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.test_pypi_password }} | ||
repository_url: https://test.pypi.org/legacy/ | ||
|
||
- name: Publish distribution 📦 to PyPI | ||
if: startsWith(github.event.ref, 'refs/tags') || github.event_name == 'release' | ||
uses: pypa/[email protected] | ||
with: | ||
user: __token__ | ||
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
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