create-windowless-app 11.0.2 → 12.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -23,6 +23,7 @@ If something doesn't work, please [file an issue](https://github.com/yoavain/cre
23
23
 
24
24
  Pre-Requisites for template to work:
25
25
  * `NodeJS` version `20.0.0` or higher
26
+ * `npm` version `9.0.0` or higher
26
27
  * `MSBuild.exe` must be in the PATH environment variable
27
28
  * `signtool` must be in the PATH environment variable
28
29
 
@@ -71,19 +72,23 @@ my-app
71
72
  ├── node_modules
72
73
  ├── package.json
73
74
  ├── sea-config.json
74
- ├── tsconfig.json
75
- ├── tsconfig.build.json
76
- ├── webpack.config.js
77
- ├── launcher
75
+ ├── tsconfig.json (TypeScript projects)
76
+ ├── tsconfig.build.json (TypeScript projects)
77
+ ├── webpack.config.ts (TypeScript projects)
78
+ ├── webpack.config.js (JavaScript projects)
79
+ ├── .husky/ (if husky enabled)
80
+ ├── launcher/
78
81
  │ ├── launcher.cs
79
82
  │ ├── launcher.csproj
80
- | ├── launcher.ico
81
- | └── launcherCompiler.ts
82
- ├── resources
83
- │ └── bin
83
+ ├── launcher.ico
84
+ └── launcherCompiler.js (JavaScript) / launcherCompiler.ts (TypeScript)
85
+ ├── resources/
86
+ │ └── bin/
84
87
  │ └── my-app-launcher.exe
85
- └───src
86
- └── index.js
88
+ ├── src/
89
+ └── index.js (JavaScript) / index.ts (TypeScript)
90
+ └── utils/
91
+ └── (utility files)
87
92
  ```
88
93
 
89
94
  No configuration or complicated folder structures, just the files you need to build your app.<br>
package/dist/cliParser.js CHANGED
@@ -20,7 +20,7 @@ const yargs_1 = __importDefault(require("yargs"));
20
20
  const helpers_1 = require("yargs/helpers");
21
21
  const interactive_1 = require("./interactive");
22
22
  const validation_1 = require("./validation");
23
- // eslint-disable-next-line @typescript-eslint/no-var-requires
23
+ // eslint-disable-next-line @typescript-eslint/no-require-imports
24
24
  const packageJson = require(`../${createWindowlessAppUtils_1.PACKAGE_JSON_FILENAME}`);
25
25
  const validateInput = (argv) => {
26
26
  if (argv.icon && !(0, fs_extra_1.pathExistsSync)(argv.icon)) {
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
15
15
  }) : function(o, v) {
16
16
  o["default"] = v;
17
17
  });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
25
35
  var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
26
36
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
27
37
  return new (P || (P = Promise))(function (resolve, reject) {
@@ -52,7 +62,7 @@ const run = (root, appName, originalDirectory, programConfig) => __awaiter(void
52
62
  try {
53
63
  const dependenciesManager = new dependencies_1.DependenciesManager(typescript, husky);
54
64
  yield dependenciesManager.installAll(verbose);
55
- const fileManager = new files_1.FileManager(root, appName, typescript, husky, icon);
65
+ const fileManager = new files_1.FileManager({ targetRoot: root, appName, typeScript: typescript, husky, icon });
56
66
  yield fileManager.copyTemplate();
57
67
  // Launcher
58
68
  (0, fs_extra_1.ensureDirSync)(path.resolve(root, "resources", "bin"));
@@ -30,7 +30,7 @@ const createWindowlessAppUtils_1 = require("../createWindowlessAppUtils");
30
30
  const fs_extra_1 = require("fs-extra");
31
31
  const path_1 = __importDefault(require("path"));
32
32
  class FileManager {
33
- constructor(targetRoot, appName, typeScript, husky, icon) {
33
+ constructor({ targetRoot, appName, typeScript, husky, icon }) {
34
34
  _FileManager_templatesRoot.set(this, void 0);
35
35
  _FileManager_targetRoot.set(this, void 0);
36
36
  _FileManager_typeScript.set(this, void 0);
@@ -15,13 +15,23 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
15
15
  }) : function(o, v) {
16
16
  o["default"] = v;
17
17
  });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
25
35
  var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
26
36
  function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
27
37
  return new (P || (P = Promise))(function (resolve, reject) {
@@ -23,7 +23,7 @@ exports.getTsScripts = getTsScripts;
23
23
  const getJsScripts = (appName) => (Object.assign({ "start": "node src/index.js", "prewebpack": "rimraf build && rimraf dist", "webpack": "webpack", "prebuild": "npm run check-node-version", "build": "npm run webpack && npm run node-sea", "check-node-version": "node -e \"require(\"\"./utils/checkNodeVersion\"\").checkNodeRuntimeVersion()\"", "check-msbuild": "node -e \"require(\"\"./launcher/launcherCompiler\"\").checkMsbuildInPath(true)\"", "rebuild-launcher": "msbuild launcher/launcher.csproj" }, getSingleExecutableApplicationsScripts(appName)));
24
24
  exports.getJsScripts = getJsScripts;
25
25
  const getHuskyScripts = (appName) => ({
26
- "prepare": "git config --get core.hookspath || husky install",
26
+ "prepare": "git config --get core.hookspath || husky",
27
27
  "pre-commit": `git diff HEAD --exit-code --stat launcher/* || npm run check-msbuild && npm run rebuild-launcher && git add resources/bin/${appName}-launcher.exe`
28
28
  });
29
29
  exports.getHuskyScripts = getHuskyScripts;
@@ -0,0 +1 @@
1
+ {"root":["../src/checknodeversion.ts","../src/cliparser.ts","../src/consts.ts","../src/createwindowlessapp.ts","../src/createwindowlessapputils.ts","../src/index.ts","../src/interactive.ts","../src/launchercompiler.ts","../src/main.ts","../src/nodeutils.ts","../src/validation.ts","../src/dependencies/dependenciesmanager.ts","../src/dependencies/index.ts","../src/files/filemanager.ts","../src/files/fileutils.ts","../src/files/index.ts","../src/packagejson/index.ts","../src/packagejson/packagejsonbuilder.ts","../src/packagejson/packagejsonconsts.ts"],"version":"5.8.3"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-windowless-app",
3
- "version": "11.0.2",
3
+ "version": "12.0.0",
4
4
  "description": "Create a windowless NodeJS app",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -15,7 +15,7 @@
15
15
  "build:no-test": "npm run tsc && npm run add-shebang && npm run package",
16
16
  "build:no-test:ci": "npm run tsc && npm run add-shebang && del package-lock.json && npm prune --omit=dev && npm shrinkwrap && npm run package",
17
17
  "test": "npm run eslint && npm run type-check && npm run jest",
18
- "eslint": "eslint src/ test/ integration_test/ templates/",
18
+ "eslint": "eslint src/ test/ integration_test/ templates/ *.ts",
19
19
  "eslint:fix": "npm run eslint -- --fix",
20
20
  "type-check": "tsc --build tsconfig.json",
21
21
  "jest": "cross-env FORCE_COLOR=0 jest",
@@ -56,53 +56,56 @@
56
56
  },
57
57
  "homepage": "https://github.com/yoavain/create-windowless-app#readme",
58
58
  "devDependencies": {
59
- "@tsconfig/node20": "20.1.4",
59
+ "@eslint/compat": "1.3.1",
60
+ "@eslint/eslintrc": "3.3.1",
61
+ "@eslint/js": "9.31.0",
62
+ "@tsconfig/node20": "20.1.6",
60
63
  "@types/cross-spawn": "6.0.6",
61
64
  "@types/fs-extra": "11.0.4",
62
- "@types/inquirer": "8.2.10",
63
- "@types/jest": "29.5.12",
65
+ "@types/jest": "30.0.0",
64
66
  "@types/mock-fs": "4.13.4",
65
- "@types/node": "20.12.8",
67
+ "@types/node": "20.19.9",
66
68
  "@types/node-notifier": "8.0.5",
67
69
  "@types/validate-npm-package-name": "4.0.2",
68
70
  "@types/winston": "2.4.4",
69
- "@typescript-eslint/eslint-plugin": "7.8.0",
70
- "@typescript-eslint/parser": "7.8.0",
71
+ "@typescript-eslint/eslint-plugin": "8.38.0",
72
+ "@typescript-eslint/parser": "8.38.0",
71
73
  "add-shebang": "0.1.0",
72
- "copy-webpack-plugin": "12.0.2",
74
+ "copy-webpack-plugin": "13.0.0",
73
75
  "cross-env": "7.0.3",
74
- "del": "6.1.1",
75
- "eslint": "8.57.0",
76
- "eslint-plugin-import": "2.29.1",
77
- "eslint-plugin-jest": "28.4.0",
78
- "eslint-plugin-n": "17.4.0",
79
- "eslint-plugin-security": "1.7.1",
76
+ "eslint": "9.31.0",
77
+ "eslint-import-resolver-typescript": "4.4.4",
78
+ "eslint-plugin-import": "2.32.0",
79
+ "eslint-plugin-jest": "29.0.1",
80
+ "eslint-plugin-n": "17.21.0",
81
+ "eslint-plugin-security": "3.0.1",
80
82
  "global-npm": "0.5.0",
81
- "husky": "9.0.11",
82
- "jest": "29.7.0",
83
- "lint-staged": "15.2.2",
84
- "mock-fs": "5.2.0",
83
+ "globals": "16.3.0",
84
+ "husky": "9.1.7",
85
+ "jest": "30.0.5",
86
+ "lint-staged": "15.5.2",
87
+ "mock-fs": "5.5.0",
85
88
  "mocked-env": "1.3.5",
86
89
  "node-notifier": "10.0.1",
87
- "nyc": "15.1.0",
90
+ "nyc": "17.1.0",
88
91
  "postject": "1.0.0-alpha.6",
89
- "prettier": "3.2.5",
90
- "rimraf": "5.0.5",
92
+ "prettier": "3.6.2",
93
+ "rimraf": "6.0.1",
91
94
  "tmp-promise": "3.0.3",
92
- "ts-jest": "29.1.2",
93
- "ts-loader": "9.5.1",
95
+ "ts-jest": "29.4.0",
96
+ "ts-loader": "9.5.2",
94
97
  "ts-node": "10.9.2",
95
- "typescript": "5.4.5",
96
- "webpack": "5.91.0",
97
- "webpack-cli": "5.1.4",
98
- "winston": "3.13.0"
98
+ "typescript": "5.8.3",
99
+ "webpack": "5.100.2",
100
+ "webpack-cli": "6.0.1",
101
+ "winston": "3.17.0"
99
102
  },
100
103
  "dependencies": {
101
104
  "chalk": "4.1.2",
102
- "cross-spawn": "7.0.3",
103
- "fs-extra": "11.2.0",
104
- "inquirer": "8.2.6",
105
- "validate-npm-package-name": "5.0.0",
105
+ "cross-spawn": "7.0.6",
106
+ "fs-extra": "11.3.0",
107
+ "inquirer": "11.1.0",
108
+ "validate-npm-package-name": "6.0.2",
106
109
  "yargs": "17.7.2"
107
110
  },
108
111
  "lint-staged": {
@@ -1,3 +1 @@
1
- #!/bin/sh
2
-
3
1
  npm run pre-commit