Skip to content

Commit

Permalink
feat: configure renovate regex manager (#3)
Browse files Browse the repository at this point in the history
* Add Renovate configuration with custom regex manager

* Fix Renovate configuration

* Manage devpod version with Renovate

* Add simple workflow to validate Renovate configuration

* Use newer Renovate custom manager syntax
  • Loading branch information
p5 authored Dec 19, 2023
1 parent e5a11be commit bc8544d
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .github/renovate.json5
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"extends": ["config:recommended"],
"customManagers": [
{
"customType": "regex",
"fileMatch": [".*\\.spec"],
"matchStrings": [
"#\\s?renovate: datasource=(?<datasource>.*?) depName=(?<depName>.*?)( versioning=(?<versioning>.*?))?( extractVersion=(?<extractVersion>.*?))?\\s*Version:\\s*(?<currentValue>.*)\\s"
],
"versioningTemplate": "{{#if versioning}}{{{versioning}}}{{else}}semver{{/if}}"
}
]
}
25 changes: 25 additions & 0 deletions .github/workflows/renovate.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Validate Renovate

on:
pull_request:
paths:
- "**/renovate.json"
- "**/renovate.json5"

jobs:
validate:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: latest

- name: Install dependencies
run: npm install -g renovate

- name: Validate Renovate config
run: renovate-config-validator --strict
1 change: 1 addition & 0 deletions staging/devpod/devpod.spec
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Name: devpod
# renovate: datasource=github-releases depName=loft-sh/devpod
Version: v0.4.2
Release: 1%{?dist}
Summary: Codespaces but open-source, client-only and unopinionated.
Expand Down

0 comments on commit bc8544d

Please sign in to comment.