@todesktop/cli 1.19.1 → 1.20.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/dist/types.d.ts CHANGED
@@ -183,9 +183,13 @@ export type NpmVersionProperty = string;
183
183
  */
184
184
  export type PnpmVersionProperty = string;
185
185
  /**
186
- * The package manager to use when installing dependencies. Valid values are `npm`, `yarn` or `pnpm`.
186
+ * The version of Bun that ToDesktop should use for installation.
187
187
  */
188
- export type PackageManagerProperty = 'npm' | 'yarn' | 'pnpm';
188
+ export type BunVersionProperty = string;
189
+ /**
190
+ * The package manager to use when installing dependencies. Valid values are `npm`, `yarn`, `pnpm` or `bun`.
191
+ */
192
+ export type PackageManagerProperty = 'npm' | 'yarn' | 'pnpm' | 'bun';
189
193
  /**
190
194
  * The library that ToDesktop should use for rebuilding native modules. Valid values are `app-builder` or `@electron/rebuild`.
191
195
  */
@@ -215,6 +219,7 @@ export interface Schema {
215
219
  enabled?: boolean;
216
220
  };
217
221
  bytenode?: BytenodeConfigProperty;
222
+ fuses?: FusesConfigProperty;
218
223
  asar?: AsarProperty;
219
224
  asarUnpack?: AsarUnpackProperty;
220
225
  buildVersion?: BuildVersionProperty;
@@ -246,6 +251,7 @@ export interface Schema {
246
251
  nodeVersion?: NodeVersionProperty;
247
252
  npmVersion?: NpmVersionProperty;
248
253
  pnpmVersion?: PnpmVersionProperty;
254
+ bunVersion?: BunVersionProperty;
249
255
  packageJson?: PackageJsonProperty;
250
256
  packageManager?: PackageManagerProperty;
251
257
  rebuildLibrary?: RebuildLibraryProperty;
@@ -265,6 +271,43 @@ export interface Schema {
265
271
  linux?: PlatformOverridableProperties;
266
272
  };
267
273
  }
274
+ /**
275
+ * Configure Electron Fuses to enable or disable certain Electron features at package time. Fuses are compile-time feature flags that cannot be changed at runtime, providing security benefits. See https://www.electronjs.org/docs/latest/tutorial/fuses for more information.
276
+ */
277
+ export interface FusesConfigProperty {
278
+ /**
279
+ * Controls whether the ELECTRON_RUN_AS_NODE environment variable is respected. When disabled, the env variable will be ignored. Default: true (enabled).
280
+ */
281
+ runAsNode?: boolean;
282
+ /**
283
+ * Controls whether the cookie store on disk is encrypted using OS-level cryptography. Default: false (disabled).
284
+ */
285
+ enableCookieEncryption?: boolean;
286
+ /**
287
+ * Controls whether the NODE_OPTIONS environment variable is respected. When disabled, the env variable will be ignored. Default: true (enabled).
288
+ */
289
+ enableNodeOptionsEnvironmentVariable?: boolean;
290
+ /**
291
+ * Controls whether command line arguments like --inspect are respected. When disabled, these arguments will be ignored. Default: true (enabled).
292
+ */
293
+ enableNodeCliInspectArguments?: boolean;
294
+ /**
295
+ * Controls whether Electron validates the integrity of the app.asar file. Requires the integrity block in the asar header. Default: false (disabled).
296
+ */
297
+ enableEmbeddedAsarIntegrityValidation?: boolean;
298
+ /**
299
+ * Controls whether Electron only loads the app from an asar archive. When enabled, Electron will not search for loose files. Default: false (disabled).
300
+ */
301
+ onlyLoadAppFromAsar?: boolean;
302
+ /**
303
+ * Controls whether the browser process uses a V8 snapshot file located at browser_v8_context_snapshot.bin. Default: false (disabled).
304
+ */
305
+ loadBrowserProcessSpecificV8Snapshot?: boolean;
306
+ /**
307
+ * Controls whether pages loaded via file:// protocol get extra privileges. When disabled, file:// pages are more restricted. Requires Electron 29+. Default: true (enabled).
308
+ */
309
+ grantFileProtocolExtraPrivileges?: boolean;
310
+ }
268
311
  /**
269
312
  * This object contains some options that only apply to the building & releasing for Linux.
270
313
  */
@@ -507,6 +550,7 @@ export interface PlatformOverridableProperties {
507
550
  appProtocolScheme?: AppProtocolSchemeProperty;
508
551
  appPath?: AppPathProperty;
509
552
  bytenode?: BytenodeConfigProperty;
553
+ fuses?: FusesConfigProperty;
510
554
  asar?: AsarProperty;
511
555
  asarUnpack?: AsarUnpackProperty;
512
556
  buildVersion?: BuildVersionProperty;
@@ -526,6 +570,7 @@ export interface PlatformOverridableProperties {
526
570
  nodeVersion?: NodeVersionProperty;
527
571
  npmVersion?: NpmVersionProperty;
528
572
  pnpmVersion?: PnpmVersionProperty;
573
+ bunVersion?: BunVersionProperty;
529
574
  packageJson?: PackageJsonProperty;
530
575
  packageManager?: PackageManagerProperty;
531
576
  rebuildLibrary?: RebuildLibraryProperty;
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "access": "public"
5
5
  },
6
6
  "name": "@todesktop/cli",
7
- "version": "1.19.1",
7
+ "version": "1.20.0-0",
8
8
  "license": "MIT",
9
9
  "author": "Dave Jeffery <dave@todesktop.com> (http://www.todesktop.com/)",
10
10
  "homepage": "https://todesktop.com/cli",
@@ -19,7 +19,7 @@
19
19
  "node": ">=16"
20
20
  },
21
21
  "scripts": {
22
- "build": "npm run docs:generate && types:generate && node scripts/esbuild.js",
22
+ "build": "npm run docs:generate && npm run types:generate && node scripts/esbuild.js",
23
23
  "dev": "node scripts/esbuild.js --link --watch --stage dev",
24
24
  "dev:local:prod": "node scripts/esbuild.js --link --watch --stage prod-local",
25
25
  "dev:prod": "node scripts/esbuild.js --link --watch",
@@ -41,6 +41,7 @@
41
41
  }
42
42
  },
43
43
  "bytenode": { "$ref": "#/definitions/bytenodeConfigProperty" },
44
+ "fuses": { "$ref": "#/definitions/fusesConfigProperty" },
44
45
  "asar": { "$ref": "#/definitions/asarProperty" },
45
46
  "asarUnpack": { "$ref": "#/definitions/asarUnpackProperty" },
46
47
  "buildVersion": { "$ref": "#/definitions/buildVersionProperty" },
@@ -87,6 +88,7 @@
87
88
  "nodeVersion": { "$ref": "#/definitions/nodeVersionProperty" },
88
89
  "npmVersion": { "$ref": "#/definitions/npmVersionProperty" },
89
90
  "pnpmVersion": { "$ref": "#/definitions/pnpmVersionProperty" },
91
+ "bunVersion": { "$ref": "#/definitions/bunVersionProperty" },
90
92
  "packageJson": { "$ref": "#/definitions/packageJsonProperty" },
91
93
  "packageManager": { "$ref": "#/definitions/packageManagerProperty" },
92
94
  "rebuildLibrary": { "$ref": "#/definitions/rebuildLibraryProperty" },
@@ -161,6 +163,45 @@
161
163
  }
162
164
  ]
163
165
  },
166
+ "fusesConfigProperty": {
167
+ "type": "object",
168
+ "additionalProperties": false,
169
+ "description": "Configure Electron Fuses to enable or disable certain Electron features at package time. Fuses are compile-time feature flags that cannot be changed at runtime, providing security benefits. See https://www.electronjs.org/docs/latest/tutorial/fuses for more information.",
170
+ "properties": {
171
+ "runAsNode": {
172
+ "type": "boolean",
173
+ "description": "Controls whether the ELECTRON_RUN_AS_NODE environment variable is respected. When disabled, the env variable will be ignored. Default: true (enabled)."
174
+ },
175
+ "enableCookieEncryption": {
176
+ "type": "boolean",
177
+ "description": "Controls whether the cookie store on disk is encrypted using OS-level cryptography. Default: false (disabled)."
178
+ },
179
+ "enableNodeOptionsEnvironmentVariable": {
180
+ "type": "boolean",
181
+ "description": "Controls whether the NODE_OPTIONS environment variable is respected. When disabled, the env variable will be ignored. Default: true (enabled)."
182
+ },
183
+ "enableNodeCliInspectArguments": {
184
+ "type": "boolean",
185
+ "description": "Controls whether command line arguments like --inspect are respected. When disabled, these arguments will be ignored. Default: true (enabled)."
186
+ },
187
+ "enableEmbeddedAsarIntegrityValidation": {
188
+ "type": "boolean",
189
+ "description": "Controls whether Electron validates the integrity of the app.asar file. Requires the integrity block in the asar header. Default: false (disabled)."
190
+ },
191
+ "onlyLoadAppFromAsar": {
192
+ "type": "boolean",
193
+ "description": "Controls whether Electron only loads the app from an asar archive. When enabled, Electron will not search for loose files. Default: false (disabled)."
194
+ },
195
+ "loadBrowserProcessSpecificV8Snapshot": {
196
+ "type": "boolean",
197
+ "description": "Controls whether the browser process uses a V8 snapshot file located at browser_v8_context_snapshot.bin. Default: false (disabled)."
198
+ },
199
+ "grantFileProtocolExtraPrivileges": {
200
+ "type": "boolean",
201
+ "description": "Controls whether pages loaded via file:// protocol get extra privileges. When disabled, file:// pages are more restricted. Requires Electron 29+. Default: true (enabled)."
202
+ }
203
+ }
204
+ },
164
205
  "appFilesProperty": {
165
206
  "type": "array",
166
207
  "description": "This option allows you to decide which files get uploaded to be built on the ToDesktop servers. By default, all files in your app path are included in your app, except for `node_modules` and `.git`. Dependencies are installed on our build servers as there could be platform-specific postinstall steps.",
@@ -654,6 +695,13 @@
654
695
  "description": "The version of pnpm that ToDesktop should use for installation.",
655
696
  "examples": ["8.10.5"]
656
697
  },
698
+ "bunVersionProperty": {
699
+ "type": "string",
700
+ "validSemver": {},
701
+ "minLength": 1,
702
+ "description": "The version of Bun that ToDesktop should use for installation.",
703
+ "examples": ["1.3.6"]
704
+ },
657
705
  "packageJsonProperty": {
658
706
  "type": "object",
659
707
  "description": "If you want to override the default `package.json` configuration, use the `packageJson` property. For example, you can use this to override the `productName` or `version` properties.",
@@ -661,10 +709,10 @@
661
709
  },
662
710
  "packageManagerProperty": {
663
711
  "type": "string",
664
- "enum": ["npm", "yarn", "pnpm"],
665
- "description": "The package manager to use when installing dependencies. Valid values are `npm`, `yarn` or `pnpm`.",
712
+ "enum": ["npm", "yarn", "pnpm", "bun"],
713
+ "description": "The package manager to use when installing dependencies. Valid values are `npm`, `yarn`, `pnpm` or `bun`.",
666
714
  "examples": ["yarn"],
667
- "default": "If `yarn.lock` exists, `yarn` is used. If `pnpm-lock.yaml` or `shrinkwrap.yaml` exists, `pnpm` is used. Otherwise, `npm` is used."
715
+ "default": "If `bun.lockb` or `bun.lock` exists, `bun` is used. If `yarn.lock` exists, `yarn` is used. If `pnpm-lock.yaml` or `shrinkwrap.yaml` exists, `pnpm` is used. Otherwise, `npm` is used."
668
716
  },
669
717
  "rebuildLibraryProperty": {
670
718
  "type": "string",
@@ -916,6 +964,7 @@
916
964
  },
917
965
  "appPath": { "$ref": "#/definitions/appPathProperty" },
918
966
  "bytenode": { "$ref": "#/definitions/bytenodeConfigProperty" },
967
+ "fuses": { "$ref": "#/definitions/fusesConfigProperty" },
919
968
  "asar": { "$ref": "#/definitions/asarProperty" },
920
969
  "asarUnpack": { "$ref": "#/definitions/asarUnpackProperty" },
921
970
  "buildVersion": { "$ref": "#/definitions/buildVersionProperty" },
@@ -943,6 +992,7 @@
943
992
  "nodeVersion": { "$ref": "#/definitions/nodeVersionProperty" },
944
993
  "npmVersion": { "$ref": "#/definitions/npmVersionProperty" },
945
994
  "pnpmVersion": { "$ref": "#/definitions/pnpmVersionProperty" },
995
+ "bunVersion": { "$ref": "#/definitions/bunVersionProperty" },
946
996
  "packageJson": { "$ref": "#/definitions/packageJsonProperty" },
947
997
  "packageManager": { "$ref": "#/definitions/packageManagerProperty" },
948
998
  "rebuildLibrary": { "$ref": "#/definitions/rebuildLibraryProperty" },