Skip to content

Commit da7dae0

Browse files
chore(workflow): add PR template, commit title enforcement, issue link check, and contribution guidelines [skip ci]
1 parent 89c5079 commit da7dae0

File tree

4 files changed

+129
-1
lines changed

4 files changed

+129
-1
lines changed

.github/pull_request_template.md

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,37 @@
1-
<!--
1+
# Pull Request Template for LOGIK-PROJEKT
2+
3+
## Title
4+
<!--
5+
- Use format: [TYPE] Short description (#issue-number)
6+
- Example: [FEATURE] Add desktop app automation (#42)
7+
-->
8+
9+
## Linked Issue
10+
<!--
11+
- Link to the relevant issue using: Closes #issue-number
12+
- Example: Closes #42
13+
-->
14+
15+
## Description
16+
<!--
17+
- Briefly describe the purpose and context of this PR.
18+
- Include any relevant background, motivation, or design decisions.
19+
-->
20+
21+
## Checklist
22+
- [ ] PR title follows required format
23+
- [ ] Linked to a relevant issue (Closes #...)
24+
- [ ] All new and updated code is documented
25+
- [ ] Tests added or updated (if applicable)
26+
- [ ] CI checks pass (lint, tests, workflows)
27+
- [ ] Changelog and release notes updated
28+
- [ ] No large, unrelated changes (PR is focused)
29+
- [ ] All reviewers added
30+
31+
## Additional Notes
32+
<!--
33+
- Add any extra context, screenshots, or migration notes here.
34+
--><!--
235
Thank you for your Pull Request!
336
Please fill out this template to help reviewers understand your changes.
437
Delete sections that aren't applicable to your PR.
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Conventional Commit Title Check
2+
3+
on:
4+
pull_request:
5+
types: [opened, edited, synchronize]
6+
push:
7+
branches:
8+
- prod-2027.0.0
9+
- release-*
10+
11+
jobs:
12+
commit-title-lint:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout code
16+
uses: actions/checkout@v4
17+
- name: Validate PR title (Conventional Commits)
18+
if: github.event_name == 'pull_request'
19+
uses: amannn/action-semantic-pull-request@v5
20+
env:
21+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
22+
with:
23+
types: |-
24+
feat
25+
fix
26+
docs
27+
style
28+
refactor
29+
perf
30+
test
31+
build
32+
ci
33+
chore
34+
revert
35+
scopes: ''
36+
requireScope: false
37+
subjectPattern: '^[A-Z].*'
38+
wip: false
39+
- name: Validate commit messages (Conventional Commits)
40+
if: github.event_name == 'push'
41+
uses: wagoid/commitlint-github-action@v6
42+
with:
43+
configFile: .github/commitlint.config.js
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Require Issue Link in PR
2+
3+
on:
4+
pull_request:
5+
types: [opened, edited, synchronize]
6+
7+
jobs:
8+
require-issue-link:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Check PR description for issue link
12+
uses: actions/github-script@v7
13+
with:
14+
script: |
15+
const prBody = github.context.payload.pull_request.body || '';
16+
const issueLinkPattern = /(Closes|Fixes)\s+#\d+/i;
17+
if (!issueLinkPattern.test(prBody)) {
18+
core.setFailed('PR description must include "Closes #N" or "Fixes #N" to link an issue.');
19+
}

CONTRIBUTING.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# Contributing to LOGIK-PROJEKT
2+
3+
Thank you for your interest in contributing! To keep our codebase maintainable and our review process efficient, please follow these guidelines:
4+
5+
## Pull Request Guidelines
6+
7+
- **Break large changes into focused PRs:**
8+
- Submit small, logically grouped changes rather than large, multi-purpose PRs.
9+
- Each PR should address a single feature, bugfix, or refactor whenever possible.
10+
- Large changesets are harder to review, test, and merge. If your work is broad, split it into multiple PRs and reference them in each description.
11+
12+
- **PR Title and Issue Linking:**
13+
- Use the required PR title format (see PULL_REQUEST_TEMPLATE.md).
14+
- Link to a relevant issue using "Closes #N" or "Fixes #N" in the PR description.
15+
16+
- **Checklist Before Submitting:**
17+
- Ensure all code is documented and tested.
18+
- Update changelogs and release notes as needed.
19+
- Confirm CI checks pass before requesting review.
20+
21+
## General Contribution Process
22+
23+
1. Fork the repository and create your feature branch from `prod-2027.0.0` or the latest release branch.
24+
2. Make your changes, keeping each PR focused and atomic.
25+
3. Run tests and linters locally before pushing.
26+
4. Open a pull request and fill out all required template sections.
27+
5. Address review feedback promptly and keep PRs up to date with the base branch.
28+
29+
For more details, see the PR template and workflows in `.github/`.
30+
31+
---
32+
33+
If you have questions, open an issue or contact the maintainers.

0 commit comments

Comments
 (0)