Skip to content

Commit

Permalink
Revert "ci: Separate the release and publish jobs"
Browse files Browse the repository at this point in the history
This reverts commit 893c27d.
  • Loading branch information
alexandermentormate committed Apr 10, 2024
1 parent 893c27d commit c54435f
Showing 1 changed file with 7 additions and 32 deletions.
39 changes: 7 additions & 32 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,31 +8,11 @@ on:
- completed

jobs:

release:
runs-on: ubuntu-latest
permissions:
id-token: write
contents: write

steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
concurrency: release

- name: Check for new Relase and ...release
uses: python-semantic-release/python-semantic-release@master
with:
github_token: ${{ secrets.ACCESS_TOKEN }}

- name: Store the distribution packages
uses: actions/upload-artifact@v3
if: ${{ hashFiles('dist/') != '' }}
with:
name: python-package-distributions
path: dist/

publish:
runs-on: ubuntu-latest
permissions:
id-token: write
contents: write
Expand All @@ -42,19 +22,14 @@ jobs:
url: https://test.pypi.org/p/python-project-cli

steps:
- name: Check if dist exists
uses: xSAVIKx/artifact-exists-action@v0
id: check_python_package
- uses: actions/checkout@v3
with:
name: python-package-distributions
path: dist/
fetch-depth: 0

- name: Download all the dists
if: steps.check_python_package.outputs.files_exists == 'true'
uses: actions/download-artifact@v3
- name: Check for new Relase and ...release
uses: python-semantic-release/python-semantic-release@master
with:
name: python-package-distributions
path: dist/
github_token: ${{ secrets.ACCESS_TOKEN }}

- name: Publish package to TestPyPI if new release available
uses: pypa/gh-action-pypi-publish@release/v1
Expand Down

0 comments on commit c54435f

Please sign in to comment.