Skip to content

Commit

Permalink
Pre flip
Browse files Browse the repository at this point in the history
  • Loading branch information
NorthernMan54 committed Nov 21, 2024
1 parent 21053e3 commit b317c74
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
11 changes: 7 additions & 4 deletions eslint.config.js → eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
/** @type {import('eslint').FlatConfig[]} */
import pluginJs from "@eslint/js";
import pluginJest from "eslint-plugin-jest";
import globals from "globals";

/** @type {import('eslint').Linter.Config[]} */

export default [
{
files: ["**/*.js"],
languageOptions: {
sourceType: "commonjs", // Change to "module" for ES6
sourceType: "commonjs", // This is necessary to parse imports/exports
globals: {
...globals.browser,
...globals.es2021,
...globals.jest, // Add Jest globals
},
},
// Add any other specific rules here
},
pluginJs.configs.recommended,
{
Expand All @@ -26,6 +28,7 @@ export default [
},
},
{
ignores: ["test/**/*", "tools/*js", "src/lib/*"], // Modify the ignores property to exclude the specified files
// Exclude test, tools, and lib directories from linting
ignores: ["test/**/*", "tools/*js", "src/lib/*"], // Exclude these files from linting
}
];
];
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,14 @@
"name": "node-red-contrib-homebridge-automation",
"version": "0.1.12",
"description": "NodeRED Automation for HomeBridge",
"type": "module",
"main": "src/HAP-NodeRed.js",
"scripts": {
"api": "documentation build HAP-NodeRed.js -f md --config docs/documentation.yml > docs/API.md",
"document": "./gh-md-toc --insert --no-backup --hide-footer README.md",
"watch": "nodemon",
"coverage": "nyc npm t",
"format": "prettier --write {.,test}/*.js *.html *.md",
"lint": "eslint --max-warnings=0 .",
"lint": "eslint --max-warnings=10 .",
"lint:fix": "eslint --fix --max-warnings=0 .",
"test": "jest --detectOpenHandles",
"test-coverage": "jest --coverage"
Expand Down Expand Up @@ -63,7 +62,7 @@
],
"ext": "js,html",
"ignore": [],
"exec": "npm run lint && DEBUG=hapNodeRed ~/npm/bin/node-red -u test/node-red",
"exec": "DEBUG=hapNodeRed ~/npm/bin/node-red -u test/node-red",
"signal": "SIGTERM",
"env": {
"NODE_OPTIONS": "--trace-warnings"
Expand Down

0 comments on commit b317c74

Please sign in to comment.