Modify Python version and update PyPI URL #2
This file contains hidden or 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
| name: Upload Python Package | ||
|
Check failure on line 1 in .github/workflows/python-publish.yml
|
||
| on: | ||
| release: | ||
| types: [published] | ||
| permissions: | ||
| contents: read | ||
| jobs: | ||
| release-build: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: "3.12" # Apne Python version ke hisab se update kar sakte ho | ||
| - name: Build release distributions | ||
| run: | | ||
| python -m pip install --upgrade build | ||
| python -m build | ||
| - name: Upload distributions | ||
| uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: release-dists | ||
| path: dist/ | ||
| pypi-publish: | ||
| runs-on: ubuntu-latest | ||
| needs: | ||
| - release-build | ||
| permissions: | ||
| id-token: write | ||
| environment: | ||
| name: pypi | ||
| url: https://pypi.org/project/mad-proxy/ # Apne PyPI project URL se replace karna | ||
| steps: | ||
| - name: Retrieve release distributions | ||
| uses: actions/download-artifact@v4 | ||
| with: | ||
| name: release-dists | ||
| path: dist/ | ||
| - name: Publish release distributions to PyPI | ||
| uses: pypa/gh-action-pypi-publish@release/v1 | ||
| with: | ||
| packages-dir: dist/ | ||
| token: ${{ secrets.80b58c36-7077-4cbd-9509-b32244e2336c }} | ||