-
Notifications
You must be signed in to change notification settings - Fork 158
44 lines (40 loc) · 1.28 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
name: Framework Release
on:
workflow_dispatch:
inputs:
new_version:
description: "New sdk version"
required: true
jobs:
Release:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
- name: update version file
run: |
echo '//
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0
//
import Foundation
extension Resource {
public static let OTEL_SWIFT_SDK_VERSION : String = "${{ inputs.new_version }}"
}
' > 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
- uses: stefanzweifel/git-auto-commit-action@v5
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