Skip to content

Commit

Permalink
fix: Add release-please
Browse files Browse the repository at this point in the history
  • Loading branch information
gbbirkisson committed Dec 5, 2023
1 parent 80fbba3 commit 94ccc2e
Show file tree
Hide file tree
Showing 6 changed files with 161 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
version: 2
updates:
- package-ecosystem: "cargo"
Expand All @@ -9,6 +10,10 @@ updates:
- "gbbirkisson"
reviewers:
- "gbbirkisson"
commit-message:
prefix: fix
prefix-development: chore
include: scope
- package-ecosystem: "github-actions"
directory: "/"
schedule:
Expand All @@ -18,3 +23,7 @@ updates:
- "gbbirkisson"
reviewers:
- "gbbirkisson"
commit-message:
prefix: fix
prefix-development: chore
include: scope
39 changes: 39 additions & 0 deletions .github/renovate.json5
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"dependencyDashboard": true,
"semanticCommitType": "fix",
"packageRules": [
{
"packagePatterns": ["^futures[-_]?"],
"groupName": "futures packages"
},
{
"packagePatterns": ["^serde[-_]?"],
"groupName": "serde packages"
},
{
"packagePatterns": ["^tokio[-_]?"],
"groupName": "tokio packages"
},
{
"packagePatterns": ["^tracing[-_]?"],
"excludePackageNames": ["tracing-opentelemetry"],
"groupName": "tracing packages"
},
{
"packagePatterns": ["^liquid[-_]?", "^kstring$"],
"groupName": "liquid packages"
}
],
"regexManagers": [
{
"fileMatch": ["^rust-toolchain\\.toml?$"],
"matchStrings": [
"channel\\s*=\\s*\"(?<currentValue>\\d+\\.\\d+\\.\\d+)\""
],
"depNameTemplate": "rust",
"lookupNameTemplate": "rust-lang/rust",
"datasourceTemplate": "github-releases"
}
]
}
46 changes: 46 additions & 0 deletions .github/workflows/conventional-commit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
---
name: Conventional commit

on:
pull_request_target:
types:
- edited
- opened
- ready_for_review
- reopened
- synchronize

permissions:
pull-requests: write

jobs:
main:
name: Validate PR title
runs-on: ubuntu-latest
if: github.event.pull_request.draft == false
steps:
- uses: amannn/action-semantic-pull-request@v5
id: lint_pr_title
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- uses: marocchino/sticky-pull-request-comment@v2
if: always() && (steps.lint_pr_title.outputs.error_message != null)
with:
header: pr-title-wrong
message: |
Pull request titles should follow [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) and it looks like this PRs title does not.
<details>
<summary>Details</summary>
```
${{ steps.lint_pr_title.outputs.error_message }}
```
</details>
- uses: marocchino/sticky-pull-request-comment@v2
if: ${{ steps.lint_pr_title.outputs.error_message == null }}
with:
header: pr-title-wrong
delete: true
20 changes: 20 additions & 0 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Release Please

on:
push:
branches:
- main

permissions:
contents: write
pull-requests: write

jobs:
release-please:
name: Run Release Please
runs-on: ubuntu-latest
steps:
- uses: google-github-actions/release-please-action@v4
with:
token: ${{ secrets.RELEASE_PLEASE_TOKEN }}
6 changes: 6 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
".": "0.5.3",
"spis-gui": "0.5.3",
"spis-model": "0.5.3",
"spis-server": "0.5.3"
}
41 changes: 41 additions & 0 deletions release-please-config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"bootstrap-sha": "80fbba33a216d3e04aac840576c49ee13e9fae4e",
"include-v-in-tag": true,
"plugins": [
{
"type": "cargo-workspace",
"merge": false
},
{
"type": "linked-versions",
"groupName": "spis",
"components": [
"spis",
"gui",
"model",
"server"
]
}
],
"packages": {
".": {
"component": "spis",
"release-type": "simple"
},
"spis-gui": {
"component": "gui",
"release-type": "rust",
"draft": true
},
"spis-model": {
"component": "model",
"release-type": "rust",
"draft": true
},
"spis-server": {
"component": "server",
"release-type": "rust",
"draft": true
}
}
}

0 comments on commit 94ccc2e

Please sign in to comment.