-
Notifications
You must be signed in to change notification settings - Fork 432
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
7 additions
and
89 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
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 |
---|---|---|
|
@@ -6,9 +6,6 @@ on: | |
branches: | ||
- "main" | ||
pull_request: | ||
pull_request_target: | ||
types: | ||
- closed | ||
schedule: | ||
- cron: "0 8 * * *" | ||
concurrency: | ||
|
@@ -88,66 +85,3 @@ jobs: | |
name: pipx.pyz | ||
path: pipx.pyz | ||
retention-days: 3 | ||
|
||
create-release: | ||
name: >- | ||
Create a release on GitHub's UI | ||
which triggers the actual release | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
if: >- | ||
github.event.pull_request.merged == true | ||
&& contains(github.event.pull_request.labels.*.name, 'release-version') | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Extract version to be released | ||
env: | ||
TITLE: ${{ github.event.pull_request.title }} | ||
run: | | ||
echo "VERSION=${TITLE##bump changelog for }" >> "$GITHUB_ENV" | ||
- name: Create release | ||
uses: ncipollo/release-action@v1 | ||
with: | ||
generateReleaseNotes: true | ||
tag: "${{ env.VERSION }}" | ||
commit: ${{ github.event.pull_request.merge_commit_sha }} | ||
|
||
pypi-publish: | ||
name: Publish pipx to PyPI on release | ||
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | ||
needs: [tests, man, zipapp] | ||
runs-on: ubuntu-latest | ||
environment: | ||
name: release | ||
url: https://pypi.org/p/pipx | ||
permissions: | ||
id-token: write | ||
steps: | ||
- name: Checkout ${{ github.ref }} | ||
uses: actions/checkout@v4 | ||
- name: Set up Python ${{ env.default-python }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ env.default-python }} | ||
cache: "pip" | ||
- name: Install nox | ||
run: pip install nox | ||
- name: Build sdist and wheel | ||
run: nox --error-on-missing-interpreters --non-interactive --session build | ||
- name: Publish to PyPi | ||
uses: pypa/[email protected] | ||
|
||
upload-zipapp: | ||
name: Upload zipapp to GitHub Release on release | ||
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | ||
needs: [tests, man, zipapp] | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
name: pipx.pyz | ||
- name: Upload to release | ||
uses: softprops/action-gh-release@v2 | ||
with: | ||
files: pipx.pyz |
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