Skip to content

Commit

Permalink
Make requested changes
Browse files Browse the repository at this point in the history
Signed-off-by: Andrew W. Harn <[email protected]>
  • Loading branch information
awharn committed Aug 8, 2024
1 parent ec84fc8 commit 7919322
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 49 deletions.
3 changes: 1 addition & 2 deletions packages/imperative/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ module.exports = {
"sourceType": "module",
"project": [
"./tsconfig.json",
"./__tests__/tsconfig.json",
"./tsconfig-tests.json"
"./__tests__/tsconfig.json"
]
}
}
2 changes: 1 addition & 1 deletion packages/imperative/__tests__/config/jest.preset.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"globals": {
"ts-jest": {
"diagnostics": false,
"tsconfig": "tsconfig-tests.json"
"tsconfig": "./__tests__/tsconfig.json"
}
},
"moduleFileExtensions": ["ts","js"],
Expand Down
11 changes: 9 additions & 2 deletions packages/imperative/__tests__/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,17 @@
"include": [
"**/*.test.ts",
"**/*.subtest.ts",
"**/__tests__/**/*"
"**/__tests__/**/*",
"../**/*.test.ts",
"../**/*.subtest.ts",
"../**/__tests__/**/*"
],
"exclude": [
"lib",
"node_modules"
]
],
"files": [
"../../__types__/wontache.d.ts"
],
"allowJs": true
}
6 changes: 3 additions & 3 deletions packages/imperative/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@
"scripts": {
"build:packages": "tsc --pretty",
"build": "npm run build:packages && npm run build:webHelp",
"lint": "eslint \"src/**/*.ts\" \"**/__tests__/**/*.ts\"",
"lint:packages": "eslint \"src/**/*.ts\" --ignore-pattern \"**/__tests__/**/*.ts\"",
"lint:tests": "eslint \"./__tests__/**/*.ts\"",
"lint": "eslint \"src/**/*.ts\" \"**/__tests__/**/*.ts\" --ignore-pattern \"**/__mocks__/*.ts\"",
"lint:packages": "eslint \"src/**/*.ts\" --ignore-pattern \"**/__tests__/**/*.ts\" --ignore-pattern \"**/__mocks__/*.ts\"",
"lint:tests": "eslint \"**/__tests__/**/*.ts\"",
"circularDependencyCheck": "madge -c lib",
"watch": "concurrently \"tsc --pretty --watch\" \"npm run watch:webHelp\"",
"build:webHelp": "cd web-help && npm run build",
Expand Down
2 changes: 1 addition & 1 deletion packages/imperative/src/utilities/src/TextUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export class TextUtils {
public static getRecommendedWidth(preferredWidth: number = TextUtils.DEFAULT_WRAP_WIDTH): number {
const widthSafeGuard = 8; // prevent partial words from continuing over lines
const yargs = require("yargs");
const maxWidth = !((yargs.terminalWidth() && yargs.terminalWidth() > 0) == null) ?
const maxWidth = (!(yargs.terminalWidth() == null) && yargs.terminalWidth() > 0) ?
(yargs.terminalWidth() - widthSafeGuard) : preferredWidth;
return Math.min(preferredWidth, maxWidth);
}
Expand Down
40 changes: 0 additions & 40 deletions packages/imperative/tsconfig-tests.json

This file was deleted.

0 comments on commit 7919322

Please sign in to comment.