Skip to content

Commit

Permalink
feat: add rules for PRs (#77)
Browse files Browse the repository at this point in the history
* add rules for PRs

* fix regex link
  • Loading branch information
k15r committed Feb 14, 2024
1 parent 83087ca commit fc1f70f
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 1 deletion.
10 changes: 9 additions & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,27 @@

version: 2
updates:
- package-ecosystem: "github-actions" # See documentation for possible values
- package-ecosystem: "gomod" # See documentation for possible values
directory: "/" # Location of package manifests
schedule:
interval: "daily"
commit-message:
prefix: "deps(dependabot)"
- package-ecosystem: "docker" # See documentation for possible values
directory: "/" # Location of package manifests
schedule:
interval: "daily"
commit-message:
prefix: "deps(dependabot)"
- package-ecosystem: "docker" # See documentation for possible values
directory: "resources/loadtest/base" # Location of package manifests
schedule:
interval: "daily"
commit-message:
prefix: "deps(dependabot)"
- package-ecosystem: "docker" # See documentation for possible values
directory: "resources/validationtest/base" # Location of package manifests
schedule:
interval: "daily"
commit-message:
prefix: "deps(dependabot)"
31 changes: 31 additions & 0 deletions .github/workflows/lint-conventional-prs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Lint PR Title
run-name: ${{github.event.pull_request.title}}

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

jobs:
check:
name: Check Title
runs-on: ubuntu-latest
steps:
- uses: amannn/action-semantic-pull-request@47b15d52c5c30e94a17ec87eb8dd51ff5221fed9
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
types: |
deps
chore
docs
feat
fix
refactor
test
requireScope: false
# https://regex101.com/r/pmEvPq/2
subjectPattern: ^(?![A-Z]).+$
2 changes: 2 additions & 0 deletions internal/loadtest/sender/legacyevent/sender.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (
"encoding/json"
"fmt"
"io"
"log"
"net/http"
"strings"
"time"
Expand Down Expand Up @@ -87,6 +88,7 @@ func (s *Sender) SendEvent(event events.Event) {
}
resp, err := s.client.Do(rq)
if err != nil {
log.Println(err)
s.undeliveredC <- event
return
}
Expand Down

0 comments on commit fc1f70f

Please sign in to comment.