|
| 1 | +# Copyright 2025 Enactic, Inc. |
| 2 | +# |
| 3 | +# Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | +# you may not use this file except in compliance with the License. |
| 5 | +# You may obtain a copy of the License at |
| 6 | +# |
| 7 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | +# |
| 9 | +# Unless required by applicable law or agreed to in writing, software |
| 10 | +# distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | +# See the License for the specific language governing permissions and |
| 13 | +# limitations under the License. |
| 14 | + |
| 15 | +name: Release |
| 16 | +on: |
| 17 | + push: |
| 18 | + tags: |
| 19 | + - '**' |
| 20 | +jobs: |
| 21 | + publish: |
| 22 | + name: Publish |
| 23 | + runs-on: ubuntu-latest |
| 24 | + environment: release |
| 25 | + permissions: |
| 26 | + contents: write |
| 27 | + discussions: write |
| 28 | + steps: |
| 29 | + - uses: actions/checkout@v4 |
| 30 | + - name: Create source archive |
| 31 | + run: | |
| 32 | + git archive ${GITHUB_REF_NAME} \ |
| 33 | + --prefix openarm-description-${GITHUB_REF_NAME}/ \ |
| 34 | + --output openarm-description-${GITHUB_REF_NAME}.tar.gz |
| 35 | + sha256sum \ |
| 36 | + openarm-description-${GITHUB_REF_NAME}.tar.gz > \ |
| 37 | + openarm-description-${GITHUB_REF_NAME}.tar.gz.sha256 |
| 38 | + sha512sum \ |
| 39 | + openarm-description-${GITHUB_REF_NAME}.tar.gz > \ |
| 40 | + openarm-description-${GITHUB_REF_NAME}.tar.gz.sha512 |
| 41 | + - name: Create GitHub Release |
| 42 | + env: |
| 43 | + GH_TOKEN: ${{ github.token }} |
| 44 | + run: | |
| 45 | + version=${GITHUB_REF_NAME} |
| 46 | + gh release create ${GITHUB_REF_NAME} \ |
| 47 | + --discussion-category Announcements \ |
| 48 | + --generate-notes \ |
| 49 | + --repo ${GITHUB_REPOSITORY} \ |
| 50 | + --title "OpenArm Description ${version}" \ |
| 51 | + --verify-tag \ |
| 52 | + openarm-description-${GITHUB_REF_NAME}.tar.gz* |
0 commit comments