Skip to content

Commit a21d13c

Browse files
ci: automated renovate dry-run (#2276)
* Add automated dry-run * Rename workflow from Local CLI Checks to Renovate * tweak naming * Fix path filter * Tighten regex for matching allower Ruby version * Apply suggestions from code review Co-authored-by: Ariel Valentin <arielvalentin@users.noreply.github.com> * Lint * Switch command * Update package.json * Add 'autodiscover' to cspell configuration * Add a repo filter Updated the dry run command for Renovate to include a filter for open-telemetry/opentelemetry-ruby-contrib. --------- Co-authored-by: Ariel Valentin <arielvalentin@users.noreply.github.com>
1 parent ab0fd6f commit a21d13c

4 files changed

Lines changed: 47 additions & 1 deletion

File tree

.cspell.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ ignoreWords:
7070
- millis
7171
- jsonlintrc
7272
- Dockerfiles
73+
- autodiscover
7374
words:
7475
- AWSXRayTrace
7576
- AWSXRaySamplingClient

.github/renovate.json5

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@
151151
datasourceTemplate: "ruby-version",
152152
versioningTemplate: "ruby",
153153
currentValueTemplate: "{{depVersion}}",
154-
extractVersionTemplate: "(?<version>[0-9]+.[0-9]+).0",
154+
extractVersionTemplate: "^(?<version>[0-9]+.[0-9]+).0$",
155155
depNameTemplate: "ruby",
156156
depTypeTemplate: "gemspec.required_ruby_version",
157157
},
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Test / Renovate
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- main
7+
paths:
8+
- ".github/workflows/test-renovate.yml"
9+
- ".github/renovate.json5"
10+
workflow_dispatch:
11+
12+
permissions:
13+
contents: read
14+
15+
concurrency:
16+
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.ref }} # Ensure that only one instance of this workflow is running per event type and ref
17+
cancel-in-progress: true # Cancel any previous runs of this workflow for the same event type and ref
18+
19+
jobs:
20+
automated-checks:
21+
if: ${{ github.repository == 'open-telemetry/opentelemetry-ruby-contrib' }}
22+
strategy:
23+
fail-fast: false
24+
name: Dry-run
25+
runs-on: ubuntu-24.04
26+
steps:
27+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
28+
29+
- name: Install Node
30+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
31+
with:
32+
cache: "npm"
33+
node-version: "24"
34+
35+
- name: Install Tools
36+
run: npm ci --ignore-scripts
37+
38+
- name: Run Dry-run
39+
env:
40+
LOG_LEVEL: debug
41+
RENOVATE_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
42+
RENOVATE_GITHUB_COM_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
43+
run: |
44+
npm run test:renovate:dryrun

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
"check:source": "npm run check:source:ruby",
1515
"check:source:ruby": "rubocop --only Bundler,Gemspec,Metrics,Migration,Minitest,Performance,Rake,RSpec,Security",
1616
"check:spelling": "cspell -c .cspell.yml .",
17+
"test:renovate:dryrun": "renovate --dry-run=full --autodiscover --autodiscover-filter open-telemetry/opentelemetry-ruby-contrib",
1718
"write": "npm run write:lint && npm run write:format && npm run write:source:ruby",
1819
"write:format": "npm run write:format:ruby && prettier . --write",
1920
"write:format:json": "prettier **/*.json --write",

0 commit comments

Comments
 (0)