|
9 | 9 |
|
10 | 10 | jobs: |
11 | 11 | release: |
| 12 | + name: Create Github Release |
| 13 | + runs-on: ubuntu-latest |
| 14 | + steps: |
| 15 | + - name: Download Python Build Artifacts |
| 16 | + uses: actions/download-artifact@v4 |
| 17 | + with: |
| 18 | + name: Source Tarball |
| 19 | + path: dist |
| 20 | + |
| 21 | + - name: Download Python Build Artifacts |
| 22 | + uses: actions/download-artifact@v4 |
| 23 | + with: |
| 24 | + name: Python Wheel |
| 25 | + path: dist |
| 26 | + |
| 27 | + - name: Download Artifacts |
| 28 | + uses: actions/download-artifact@v4 |
| 29 | + with: |
| 30 | + name: ${{ matrix.python }}-${{ matrix.arch }}-${{ matrix.platform }}.tar.xz |
| 31 | + path: release-artifacts/ |
| 32 | + |
| 33 | + - name: Create Release |
| 34 | + id: create_release |
| 35 | + uses: actions/create-release@v1 |
| 36 | + env: |
| 37 | + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token |
| 38 | + with: |
| 39 | + tag_name: "v${{ inputs.version }}" |
| 40 | + release_name: "Release v${{ inputs.version }}" |
| 41 | + body: | |
| 42 | + Release ${{ needs.build-python-package.outputs.version }} |
| 43 | + draft: false |
| 44 | + prerelease: false |
| 45 | + |
| 46 | + - name: Upload Source Tarball |
| 47 | + id: upload-release-asset-source |
| 48 | + uses: actions/upload-release-asset@v1 |
| 49 | + env: |
| 50 | + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 51 | + with: |
| 52 | + upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps |
| 53 | + asset_path: dist/relenv-${{ inputs.version }}.tar.gz |
| 54 | + asset_name: relenv-${{ inputs.version }}.tar.gz |
| 55 | + asset_content_type: application/tar+gzip |
| 56 | + |
| 57 | + - name: Upload Wheel |
| 58 | + id: upload-release-asset-x86_64 |
| 59 | + uses: actions/upload-release-asset@v1 |
| 60 | + env: |
| 61 | + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 62 | + with: |
| 63 | + upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps |
| 64 | + asset_path: dist/relenv-${{ inputs.version }}-py3-none-any.whl |
| 65 | + asset_name: relenv-${{ inputs.version }}-py3-none-any.whl |
| 66 | + asset_content_type: application/zip |
| 67 | + |
| 68 | + |
| 69 | + upload-artifacts: |
12 | 70 | name: Create Github Release |
13 | 71 | runs-on: ubuntu-latest |
14 | 72 | strategy: |
@@ -88,65 +146,12 @@ jobs: |
88 | 146 | - platform: macos |
89 | 147 | arch: arm64 |
90 | 148 | python: 3.13.0 |
91 | | - |
92 | 149 | steps: |
93 | | - - name: Download Python Build Artifacts |
94 | | - uses: actions/download-artifact@v4 |
95 | | - with: |
96 | | - name: Source Tarball |
97 | | - path: dist |
98 | | - |
99 | | - - name: Download Python Build Artifacts |
100 | | - uses: actions/download-artifact@v4 |
101 | | - with: |
102 | | - name: Python Wheel |
103 | | - path: dist |
104 | | - |
105 | | - - name: Download Artifacts |
106 | | - uses: actions/download-artifact@v4 |
107 | | - with: |
108 | | - name: ${{ matrix.python }}-${{ matrix.arch }}-${{ matrix.platform }}.tar.xz |
109 | | - path: release-artifacts/ |
110 | | - |
111 | | - - name: Create Release |
112 | | - id: create_release |
113 | | - uses: actions/create-release@v1 |
114 | | - env: |
115 | | - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token |
116 | | - with: |
117 | | - tag_name: "v${{ inputs.version }}" |
118 | | - release_name: "Release v${{ inputs.version }}" |
119 | | - body: | |
120 | | - Release ${{ needs.build-python-package.outputs.version }} |
121 | | - draft: false |
122 | | - prerelease: false |
123 | | - |
124 | | - - name: Upload Source Tarball |
125 | | - id: upload-release-asset-source |
126 | | - uses: actions/upload-release-asset@v1 |
127 | | - env: |
128 | | - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
129 | | - with: |
130 | | - upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps |
131 | | - asset_path: dist/relenv-${{ inputs.version }}.tar.gz |
132 | | - asset_name: relenv-${{ inputs.version }}.tar.gz |
133 | | - asset_content_type: application/tar+gzip |
134 | | - |
135 | | - - name: Upload Wheel |
136 | | - id: upload-release-asset-x86_64 |
137 | | - uses: actions/upload-release-asset@v1 |
138 | | - env: |
139 | | - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
140 | | - with: |
141 | | - upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps |
142 | | - asset_path: dist/relenv-${{ inputs.version }}-py3-none-any.whl |
143 | | - asset_name: relenv-${{ inputs.version }}-py3-none-any.whl |
144 | | - asset_content_type: application/zip |
145 | | - |
146 | | - - name: Upload Release artifacts |
| 150 | + - name: Upload ${{ matrix.python }}-${{ matrix.arch }}-${{ matrix.platform }}.tar.xz |
147 | 151 | id: upload-python-build-assets |
148 | 152 | uses: actions/upload-release-asset@v1 |
149 | 153 | with: |
| 154 | + upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps |
150 | 155 | name: ${{ matrix.python }}-${{ matrix.arch }}-${{ matrix.platform }}.tar.xz |
151 | 156 | path: release-artifacts/ |
152 | 157 | asset_content_type: application/tar+xz |
0 commit comments