Merge branch 'testing' into seijihariki-contributing
This commit is contained in:
commit
b110ad1bbe
2 changed files with 29 additions and 0 deletions
8
.gitignore
vendored
8
.gitignore
vendored
|
@ -1 +1,9 @@
|
|||
.vscode/*
|
||||
|
||||
# NPM things
|
||||
package.json
|
||||
package-lock.json
|
||||
node_modules/
|
||||
|
||||
# Yarn things
|
||||
yarn.lock
|
21
lint.sh
Normal file
21
lint.sh
Normal file
|
@ -0,0 +1,21 @@
|
|||
#!/usr/bin/bash
|
||||
|
||||
if ! which npx 2>&1 > /dev/null; then
|
||||
echo "[lint] npm/npx is not installed"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
npx prettier > /dev/null || npm install prettier && echo "[lint] We have 'prettier'"
|
||||
npx eslint > /dev/null || npm install eslint && echo "[lint] We have 'eslint'"
|
||||
npx prettier-eslint > /dev/null || npm install prettier-eslint-cli && echo "[lint] We have 'prettier-eslint'"
|
||||
|
||||
echo "[lint] Linting JavaScript files..."
|
||||
npx prettier-eslint --write "**/*.js"
|
||||
echo "[lint] Linting HTML files..."
|
||||
npx prettier-eslint --write "**/*.html"
|
||||
echo "[lint] Linting CSS files..."
|
||||
npx prettier-eslint --write "**/*.css"
|
||||
echo "[lint] Linting MarkDown files"
|
||||
npx prettier-eslint --write "**/*.md"
|
||||
|
||||
echo "[lint] Finished Linting."
|
Loading…
Reference in a new issue