Skip to content

Commit 2c4d5e1

Browse files
committed
Automate instant semconv release
1 parent 8236b5a commit 2c4d5e1

3 files changed

Lines changed: 18 additions & 3 deletions

File tree

.github/renovate.json5

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,9 +173,13 @@
173173
{
174174
"customType": "regex",
175175
"description": "Update Semantic Conventions version in Rake files",
176-
"managerFilePatterns": ["/^semantic_conventions/Rakefile$/"],
176+
"managerFilePatterns": [
177+
"/^semantic_conventions/Rakefile$/",
178+
"/^semantic_conventions/semconv.yaml"$/"
179+
],
177180
"matchStrings": [
178-
"SPEC_VERSION = '(?<currentValue>.*?)'"
181+
"SPEC_VERSION = '(?<currentValue>.*?)'",
182+
"spec_version: '(?<currentValue>.*?)'"
179183
],
180184
"depNameTemplate": "open-telemetry/semantic-conventions",
181185
"datasourceTemplate": "github-releases",

.github/workflows/release-request.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ on:
77
description: Components to release (leave blank to release all components)
88
required: false
99
default: ""
10+
push:
11+
branches:
12+
- main
13+
paths:
14+
- "semantic_conventions/semconv.yaml"
1015

1116
permissions:
1217
contents: read
@@ -34,11 +39,16 @@ jobs:
3439
with:
3540
client-id: ${{ vars.OTELBOT_RUBY_APP_ID }}
3641
private-key: ${{ secrets.OTELBOT_RUBY_PRIVATE_KEY }}
42+
- name: Determine releases
43+
id: detect
44+
if: ${{ github.event_name == 'push' }}
45+
run: |
46+
echo "components=opentelemetry-semantic_conventions" >> $GITHUB_OUTPUT
3747
- name: Open release pull request
3848
env:
3949
# Use an app token instead of GITHUB_TOKEN to trigger workflows
4050
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
41-
RELEASE_NAMES: ${{ github.event.inputs.names }}
51+
RELEASE_NAMES: ${{ github.event.inputs.names || steps.detect.outputs.components }}
4252
TARGET_BRANCH: ${{ github.ref }}
4353
run: |
4454
bundle exec toys release request --yes --verbose \

semantic_conventions/semconv.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
spec_version: '1.40.0'

0 commit comments

Comments
 (0)