Version 0.8.47 #291
  
    
      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
    
  
  
    
  | --- | |
| on: | |
| push: | |
| tags: | |
| - '[0-9]+.[0-9]+.[0-9]+' | |
| - '[0-9]+.[0-9]+.[0-9]+.post[0-9]+' | |
| - '[0-9]+.[0-9]+.[0-9]+[a-b][0-9]+' | |
| - '[0-9]+.[0-9]+.[0-9]+rc[0-9]+' | |
| branches: | |
| - 'main' | |
| defaults: | |
| run: | |
| shell: 'bash' | |
| jobs: | |
| prepare-python-artifacts: | |
| name: 'Job to build wheel and source distribution files' | |
| runs-on: 'ubuntu-latest' | |
| environment: 'release' | |
| steps: | |
| - name: 'Checkout code' | |
| uses: 'actions/checkout@v5' | |
| with: | |
| fetch-depth: 0 | |
| - name: 'Install build frontend' | |
| run: 'pip install hatch' | |
| - name: 'Create packages in dist/ with hatch' | |
| run: 'hatch build' | |
| - name: 'Upload package artifacts to GitHub' | |
| uses: 'actions/[email protected]' | |
| with: | |
| name: 'python-artifacts' | |
| path: 'dist/*' | |
| if-no-files-found: 'error' | |
| pypi-publish: | |
| name: 'Upload release to PyPI' | |
| if: 'github.event_name == ''push'' && startsWith(github.event.ref, ''refs/tags'')' | |
| needs: | |
| - 'prepare-python-artifacts' | |
| runs-on: 'ubuntu-latest' | |
| permissions: | |
| contents: 'write' | |
| id-token: 'write' | |
| environment: | |
| name: 'pypi' | |
| url: 'https://pypi.org/p/ciscoconfparse2' | |
| steps: | |
| - name: 'Download artifacts from python-artifacts job' | |
| uses: 'actions/download-artifact@v6' # v6.0.0 | |
| with: | |
| name: 'python-artifacts' | |
| path: 'dist' | |
| - name: 'Upload packages to PYPI' | |
| uses: 'pypa/[email protected]' |