-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: Almanov Nikita <[email protected]>
- Loading branch information
1 parent
668e3a3
commit a61bfd0
Showing
15 changed files
with
205 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,5 @@ | ||
{ | ||
"exclude": [ | ||
"README.md" | ||
] | ||
} |
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 @@ | ||
* @nikkeyl |
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,15 @@ | ||
version: 2 | ||
|
||
updates: | ||
- package-ecosystem: github-actions | ||
directory: / | ||
schedule: | ||
interval: weekly | ||
day: sunday | ||
|
||
- package-ecosystem: npm | ||
directory: / | ||
schedule: | ||
interval: weekly | ||
day: sunday | ||
versioning-strategy: increase |
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,38 @@ | ||
name: Commit Lint | ||
|
||
on: | ||
push: | ||
|
||
jobs: | ||
commit-lint: | ||
name: Commit Lint | ||
|
||
if: ${{ github.actor != 'dependabot[bot]' }} | ||
|
||
runs-on: ubuntu-latest | ||
timeout-minutes: 10 | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set Up BunJS | ||
uses: oven-sh/setup-bun@v2 | ||
|
||
- name: Install Dependencies | ||
run: bun i | ||
|
||
- name: Extract Commit Message (Push) | ||
if: ${{ github.event_name }} == 'push' | ||
run: | | ||
git log -1 --pretty=%B > commit_message.txt | ||
- name: Extract Commit Message (Pull Request) | ||
if: ${{ github.event_name }} == 'pull_request' | ||
run: | | ||
git show -s --format=%B > commit_message.txt | ||
- name: Lint | ||
run: | | ||
COMMIT_MESSAGE=$(cat commit_message.txt) | ||
echo "$COMMIT_MESSAGE" | bun commitlint |
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,21 @@ | ||
name: Create Pull Request | ||
|
||
on: | ||
push: | ||
|
||
jobs: | ||
create-pull-request: | ||
name: Create Pull Request | ||
|
||
if: ${{ github.actor != 'dependabot[bot]' }} | ||
|
||
runs-on: ubuntu-latest | ||
timeout-minutes: 10 | ||
|
||
steps: | ||
- name: Create Pull Request | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
PULL_REQUEST_BRANCH: main | ||
PULL_REQUEST_TITLE: ${{ github.event.head_commit.message }} | ||
uses: vsoch/pull-request-action@master |
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,29 @@ | ||
name: Editorconfig | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
editorconfig: | ||
name: Editorconfig | ||
|
||
runs-on: ubuntu-latest | ||
timeout-minutes: 10 | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set Up BunJS | ||
uses: oven-sh/setup-bun@v2 | ||
|
||
- name: Install Dependencies | ||
run: bun i | ||
|
||
- name: Lint | ||
run: bun lint:editorconfig |
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,33 @@ | ||
name: Remark | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
paths: | ||
- '**/*.md' | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- '**/*.md' | ||
|
||
jobs: | ||
remark: | ||
name: Remark | ||
|
||
runs-on: ubuntu-latest | ||
timeout-minutes: 10 | ||
|
||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set Up BunJS | ||
uses: oven-sh/setup-bun@v2 | ||
|
||
- name: Install Dependencies | ||
run: bun i | ||
|
||
- name: Lint | ||
run: bun lint:md |
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,5 @@ | ||
# Bun | ||
bun.lockb | ||
|
||
# Directories | ||
node_modules |
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 @@ | ||
bun commitlint --edit |
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 @@ | ||
bun git-pull-run --pattern 'package.json' --command 'bun i' |
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 @@ | ||
bun lint-staged |
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,7 @@ | ||
{ | ||
"plugins": [ | ||
"remark-preset-lint-consistent", | ||
"remark-preset-lint-markdown-style-guide", | ||
"remark-preset-lint-recommended" | ||
] | ||
} |
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,24 @@ | ||
import { defineConfig } from '@archoleat/commitlint-define-config'; | ||
|
||
export default defineConfig({ | ||
extends: ['@commitlint/config-conventional'], | ||
rules: { | ||
'type-enum': [ | ||
2, | ||
'always', | ||
[ | ||
'build', | ||
'chore', | ||
'ci', | ||
'docs', | ||
'feat', | ||
'fix', | ||
'perf', | ||
'refactor', | ||
'revert', | ||
'spec', | ||
'style', | ||
], | ||
], | ||
}, | ||
}); |
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,3 @@ | ||
export default { | ||
'**/*.md': 'remark --quiet --frail' | ||
}; |
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,21 @@ | ||
{ | ||
"scripts": { | ||
"lint:editorconfig": "editorconfig-checker", | ||
"lint:md": "remark . --quiet --frail" | ||
}, | ||
"devDependencies": { | ||
"@archoleat/commitlint-define-config": "^1.0.9", | ||
"@commitlint/cli": "^19.4.0", | ||
"@commitlint/config-conventional": "^19.2.2", | ||
"@commitlint/types": "^19.0.3", | ||
"editorconfig-checker": "^5.1.8", | ||
"git-pull-run": "^1.4.0", | ||
"husky": "^9.1.4", | ||
"lint-staged": "^15.2.9", | ||
"remark": "15.0.1", | ||
"remark-cli": "^12.0.1", | ||
"remark-preset-lint-consistent": "^6.0.0", | ||
"remark-preset-lint-markdown-style-guide": "^6.0.0", | ||
"remark-preset-lint-recommended": "^7.0.0" | ||
} | ||
} |