-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from Netcracker/feature/workflows
Add GitHub workflows for automatic PR labeling, CLA assistant, and code linting
- Loading branch information
Showing
7 changed files
with
154 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
--- | ||
|
||
conventional-commits: | ||
- type: 'fix' | ||
nouns: ['FIX', 'Fix', 'fix', 'FIXED', 'Fixed', 'fixed'] | ||
labels: ['fix'] | ||
- type: 'feature' | ||
nouns: ['FEATURE', 'Feature', 'feature', 'FEAT', 'Feat', 'feat'] | ||
labels: ['feature'] | ||
- type: 'breaking_change' | ||
nouns: ['BREAKING CHANGE', 'BREAKING', 'MAJOR'] | ||
labels: ['breaking-change'] | ||
- type: 'bug' | ||
nouns: ['bug', 'Bug', 'BUG'] | ||
labels: ['bug'] | ||
- type: 'bugfix' | ||
nouns: ['bugfix', 'Bugfix', 'bug-fix', 'BugFix'] | ||
labels: ['bugfix'] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name-template: 'v$RESOLVED_VERSION' | ||
tag-template: 'v$RESOLVED_VERSION' | ||
|
||
|
||
categories: | ||
- title: '💥 Breaking Changes' | ||
labels: | ||
- breaking-change | ||
- title: '🚀 New Features' | ||
labels: | ||
- feature | ||
- title: '🐛 Bug Fixes' | ||
labels: | ||
- bug | ||
- fix | ||
- bugfix | ||
- title: '🛠️ Technical Debt' | ||
labels: | ||
- refactor | ||
|
||
change-template: '- $TITLE (#$NUMBER) by @$AUTHOR' | ||
no-changes-template: 'No significant changes' | ||
|
||
template: | | ||
## 🚀 Release | ||
### What's Changed | ||
$CHANGES | ||
**Contributors:** $CONTRIBUTORS | ||
version-resolver: | ||
major: | ||
labels: | ||
- major | ||
minor: | ||
labels: | ||
- minor | ||
patch: | ||
labels: | ||
- patch | ||
default: patch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
--- | ||
|
||
name: Automatic PR Labeler | ||
|
||
on: | ||
pull_request: | ||
branches: [main] | ||
types: | ||
[opened, reopened] | ||
|
||
jobs: | ||
assign-labels: | ||
uses: Netcracker/qubership-workflow-hub/.github/workflows/auto-labeler.yaml@main | ||
name: Assign labels in pull request | ||
if: github.event.pull_request.merged == false | ||
with: | ||
pull_request_number: ${{ github.event.pull_request.number }} | ||
config_file: './.github/auto-labeler-config.yaml' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
--- | ||
name: CLA Assistant | ||
on: | ||
issue_comment: | ||
types: [created] | ||
pull_request_target: | ||
types: [opened,closed,synchronize] | ||
jobs: | ||
cla_assistant: | ||
uses: Netcracker/qubership-workflow-hub/.github/workflows/cla.yaml@main | ||
secrets: | ||
personal_access_token: ${{ secrets.PERSONAL_ACCESS_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
--- | ||
name: Prettier-fix | ||
on: [pull_request, workflow_dispatch] | ||
|
||
permissions: | ||
contents: write | ||
|
||
jobs: | ||
call-prettier-fix: | ||
uses: Netcracker/qubership-workflow-hub/.github/workflows/prettierFix.yaml@main |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
--- | ||
name: Profanity filter | ||
|
||
on: | ||
issue_comment: | ||
types: [created, edited] | ||
issues: | ||
types: [opened, edited, reopened] | ||
pull_request: | ||
types: [opened, edited, reopened] | ||
|
||
permissions: | ||
issues: write | ||
pull-requests: write | ||
|
||
jobs: | ||
call-apply-filter: | ||
uses: Netcracker/qubership-workflow-hub/.github/workflows/profanityFilter.yaml@main |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# This workflow executes several linters on changed files based on languages used in your code base whenever | ||
# you push a code or open a pull request. | ||
# | ||
# You can adjust the behavior by modifying this file. | ||
# For more information, see: | ||
# https://github.com/github/super-linter | ||
name: Lint Code Base | ||
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
pull_request: | ||
branches: [ "main" ] | ||
workflow_dispatch: | ||
inputs: | ||
full_scan: | ||
type: boolean | ||
default: false | ||
required: false | ||
description: "Lint all codebase" | ||
jobs: | ||
run-lint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
# Full git history is needed to get a proper list of changed files within `super-linter` | ||
fetch-depth: 0 | ||
|
||
- name: Lint Code Base | ||
uses: github/super-linter@v4 | ||
env: | ||
VALIDATE_ALL_CODEBASE: ${{ inputs.full_scan || false }} | ||
DEFAULT_BRANCH: "main" | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |