Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix release action #623

Merged
merged 16 commits into from
Oct 29, 2024
24 changes: 14 additions & 10 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ jobs:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -29,16 +30,19 @@ jobs:
' > Sources/OpenTelemetrySdk/Version.swift
- name: update Podspec
run: |
sed -i -e 's/spec.version = ".*"/spec.version = "${{ inputs.new_version }}"/' OpenTelemetryApi.podspec
sed -i -e 's/spec.version = ".*"/spec.version = "${{ inputs.new_version }}"/' OpenTelemetrySdk.podspec
sed -i -e 's/spec.version = ".*"/spec.version = "${{ inputs.new_version }}"/' OpenTelemetry-Swift-Api.podspec
sed -i -e 's/spec.version = ".*"/spec.version = "${{ inputs.new_version }}"/' OpenTelemetry-Swift-Sdk.podspec

- uses: stefanzweifel/git-auto-commit-action@v5
- name: Create Pull Request
uses: peter-evans/create-pull-request@v7
with:
commit_message: version bump to ${{inputs.new_version}}
tagging_message: 'v${{ inputs.new_version }}'
- uses: ncipollo/release-action@v1
with:
tag: v${{inputs.new_version}}
prerelease: true
generateReleaseNotes: true
token: ${{ secrets.RELEASE_TOKEN }}
branch: release/${{inputs.new_version}}
commit-message: 'Release v${{inputs.new_version}}'
title: 'Release v${{inputs.new_version}}'
body: >
This PR is auto-generated by
[create-pull-request](https://github.com/peter-evans/create-pull-request).
base: main


Loading