Skip to content

Commit

Permalink
Extract github-actions config (#8)
Browse files Browse the repository at this point in the history
* Extract github-actions config

* Create github-actions.json

* Update README.md
  • Loading branch information
int128 committed Feb 17, 2023
1 parent ef42b91 commit 235e765
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 24 deletions.
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ This is a config of Renovate for Go and Kubernetes project.
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": [
"config:base",
":automergeMinor",
":label(renovate/{{depName}})",
"github>int128/go-renovate-config",
],
Expand All @@ -18,6 +17,12 @@ This is a config of Renovate for Go and Kubernetes project.

## Flavors

### GitHub Actions workflows

```json5
"github>int128/go-renovate-config:github-actions",
```

### Kubernetes specific rules

```json5
Expand Down
25 changes: 2 additions & 23 deletions default.json
Original file line number Diff line number Diff line change
@@ -1,30 +1,9 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": [
":automergeMinor",
":automergeDigest"
],
"regexManagers": [
{
"fileMatch": [
"^\\.github/workflows/.+\\.ya?ml$"
],
"matchStrings": [
"uses: golangci/golangci-lint-action@.+?\\s+with:\\s+version: (?<currentValue>.+)\\n"
],
"depNameTemplate": "golangci/golangci-lint",
"datasourceTemplate": "github-releases"
},
{
"fileMatch": [
"^\\.github/workflows/.+\\.ya?ml$"
],
"matchStrings": [
"\\s+go-version: (?<currentValue>.+)\\n"
],
"depNameTemplate": "golang-version",
"datasourceTemplate": "golang-version",
"versioningTemplate": "semver-coerced"
}
],
"postUpdateOptions": [
"gomodTidy",
"gomodUpdateImportPaths"
Expand Down
28 changes: 28 additions & 0 deletions github-actions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"regexManagers": [
{
"description": "Update go-version in workflow",
"fileMatch": [
"^\\.github/workflows/.+\\.ya?ml$"
],
"matchStrings": [
"\\s+go-version: (?<currentValue>.+)\\n"
],
"depNameTemplate": "golang-version",
"datasourceTemplate": "golang-version",
"versioningTemplate": "semver-coerced"
},
{
"description": "Update golangci-lint in workflow",
"fileMatch": [
"^\\.github/workflows/.+\\.ya?ml$"
],
"matchStrings": [
"uses: golangci/golangci-lint-action@.+?\\s+with:\\s+version: (?<currentValue>.+)\\n"
],
"depNameTemplate": "golangci/golangci-lint",
"datasourceTemplate": "github-releases"
}
]
}

0 comments on commit 235e765

Please sign in to comment.