use Trunk for linting

This commit is contained in:
Sacha Weatherstone 2023-01-14 12:02:59 +10:00
parent 238d53997d
commit a681902030
No known key found for this signature in database
GPG key ID: 7AB2D7E206124B31
12 changed files with 142 additions and 929 deletions

View file

@ -1 +0,0 @@
"@meshtastic/eslint-config/prettier"

7
.trunk/.gitignore vendored Normal file
View file

@ -0,0 +1,7 @@
*out
*logs
*actions
*notifications
plugins
user_trunk.yaml
user.yaml

View file

@ -0,0 +1,10 @@
# Autoformatter friendly markdownlint config (all formatting rules disabled)
default: true
blank_lines: false
bullet: false
html: false
indentation: false
line_length: false
spaces: false
url: false
whitespace: false

View file

@ -0,0 +1,3 @@
{
"trailingComma": "none"
}

View file

@ -0,0 +1,7 @@
enable=all
source-path=SCRIPTDIR
disable=SC2154
# If you're having issues with shellcheck following source, disable the errors via:
# disable=SC1090
# disable=SC1091

View file

@ -0,0 +1,14 @@
module.exports = {
plugins: [
{
name: "preset-default",
params: {
overrides: {
removeViewBox: false, // https://github.com/svg/svgo/issues/1128
sortAttrs: true,
removeOffCanvasPaths: true,
},
},
},
],
};

24
.trunk/trunk.yaml Normal file
View file

@ -0,0 +1,24 @@
version: 0.1
cli:
version: 1.3.1
plugins:
sources:
- id: trunk
ref: v0.0.8
uri: https://github.com/trunk-io/plugins
lint:
enabled:
- markdownlint@0.33.0
- actionlint@1.6.22
- gitleaks@8.15.2
- git-diff-check
- oxipng@8.0.0
- shellcheck@0.9.0
- prettier@2.8.2
- shfmt@3.5.0
- eslint@8.31.0
- svgo@3.0.2
runtimes:
enabled:
- go@1.18.3
- node@18.12.1

5
.vscode/extensions.json vendored Normal file
View file

@ -0,0 +1,5 @@
{
"recommendations": [
"trunk.io"
]
}

4
.vscode/settings.json vendored Normal file
View file

@ -0,0 +1,4 @@
{
"editor.formatOnSave": true,
"editor.defaultFormatter": "trunk.io"
}

View file

@ -38,13 +38,11 @@
},
"devDependencies": {
"@docusaurus/module-type-aliases": "2.2.0",
"@meshtastic/eslint-config": "^1.0.8",
"@tailwindcss/typography": "^0.5.8",
"@tsconfig/docusaurus": "^1.0.6",
"@types/node": "^18.11.18",
"@types/react": "^18.0.26",
"@types/react-dom": "^18.0.10",
"prettier": "^2.8.1",
"typescript": "^4.9.4"
}
}

File diff suppressed because it is too large Load diff