-
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.
ci: setup GH CO, WF, renovate, & Rome
- Loading branch information
1 parent
3d33374
commit abc04b1
Showing
5 changed files
with
123 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 @@ | ||
* @elijaholmos |
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 @@ | ||
{ | ||
"$schema": "https://docs.renovatebot.com/renovate-schema.json", | ||
"extends": ["elijaholmos/.github:renovate-config"], | ||
"packageRules": [ | ||
{ | ||
"matchPackagePatterns": ["nomic"], | ||
"matchUpdateTypes": ["minor", "patch"], | ||
"groupName": "Nomic dependencies" | ||
}, | ||
{ | ||
"matchPackagePatterns": ["ethers"], | ||
"matchUpdateTypes": ["minor", "patch"], | ||
"groupName": "Ethers dependencies" | ||
}, | ||
{ | ||
"matchPackagePatterns": ["typechain"], | ||
"matchUpdateTypes": ["minor", "patch"], | ||
"groupName": "Typechain dependencies" | ||
} | ||
] | ||
} |
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,48 @@ | ||
name: Code Style | ||
on: | ||
pull_request: | ||
branches: [master] | ||
paths: ['**.js', '**.ts'] | ||
|
||
env: | ||
# version should be in sync w package.json | ||
ROME_VERSION: 11.0.0 | ||
|
||
jobs: | ||
lint: | ||
name: Lint | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install Rome | ||
uses: rome/setup-rome@main | ||
with: | ||
version: ${{ env.ROME_VERSION }} | ||
|
||
- name: Check Rome Version | ||
run: rome version | ||
|
||
- name: Run Linter | ||
# specific flag is required per https://github.com/rome/tools/discussions/3925#discussioncomment-4310702 | ||
run: rome ci --formatter-enabled=false . | ||
|
||
format: | ||
name: Format | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install Rome | ||
uses: rome/setup-rome@main | ||
with: | ||
version: ${{ env.ROME_VERSION }} | ||
|
||
- name: Check Rome Version | ||
run: rome version | ||
|
||
- name: Run Formatter | ||
# specific flag is required per https://github.com/rome/tools/discussions/3925#discussioncomment-4310702 | ||
run: rome ci --linter-enabled=false . |
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 @@ | ||
name: detect-duplicate-actions | ||
|
||
on: | ||
workflow_call: | ||
outputs: | ||
should_skip: | ||
description: 'Returns "true" if the current run should be skipped' | ||
value: ${{ jobs.detect-duplicate-actions.outputs.should_skip }} | ||
|
||
jobs: | ||
detect-duplicate-actions: | ||
name: detect-duplicate-actions | ||
runs-on: ubuntu-latest | ||
outputs: | ||
should_skip: ${{ steps.skip_check.outputs.should_skip }} | ||
steps: | ||
- name: Detect Duplicate | ||
id: skip_check | ||
uses: fkirc/skip-duplicate-actions@master | ||
with: | ||
paths_ignore: '["**.md", "**.mdx", "**.png", "**.jpg"]' | ||
do_not_skip: '["workflow_dispatch", "schedule"]' | ||
cancel_others: 'true' | ||
concurrent_skipping: 'same_content' |
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 @@ | ||
{ | ||
"$schema": "./node_modules/rome/configuration_schema.json", | ||
"files": { | ||
"ignore": ["./node_modules/**/*", "./dist/**/*", "./public/**/*", "typings.ts"] | ||
}, | ||
"formatter": { | ||
"indentStyle": "tab", | ||
"indentSize": 4, | ||
"lineWidth": 100 | ||
}, | ||
"javascript": { | ||
"formatter": { | ||
"quoteStyle": "single" | ||
} | ||
}, | ||
"linter": { | ||
"rules": { | ||
"complexity": { | ||
"noExtraBooleanCast": "off" | ||
}, | ||
"performance": { | ||
"noDelete": "off" | ||
}, | ||
"suspicious": { | ||
"noExplicitAny": "warn" | ||
} | ||
} | ||
} | ||
} |