@tauri-apps/cli 2.0.0-alpha.1 → 2.0.0-alpha.3

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/CHANGELOG.md CHANGED
@@ -1,5 +1,51 @@
1
1
  # Changelog
2
2
 
3
+ ## \[2.0.0-alpha.3]
4
+
5
+ - Added `plugin android add` and `plugin ios add` commands to add mobile plugin functionality to existing projects.
6
+ - [14d03d42](https://www.github.com/tauri-apps/tauri/commit/14d03d426e86d966950a790926c04560c76203b3) refactor(cli): enhance plugin commands for mobile ([#6289](https://www.github.com/tauri-apps/tauri/pull/6289)) on 2023-02-16
7
+ - Add commands to add native Android and iOS functionality to plugins.
8
+ - [05dad087](https://www.github.com/tauri-apps/tauri/commit/05dad0876842e2a7334431247d49365cee835d3e) feat: initial work for iOS plugins ([#6205](https://www.github.com/tauri-apps/tauri/pull/6205)) on 2023-02-11
9
+ - Use temp file instead of environment variable to pass CLI IPC websocket address to the IDE.
10
+ - [894a8d06](https://www.github.com/tauri-apps/tauri/commit/894a8d060c12a482a0fc5b3714f3848189b809de) refactor(cli): use temp file to communicate IPC websocket address ([#6219](https://www.github.com/tauri-apps/tauri/pull/6219)) on 2023-02-08
11
+ - Change the Android template to enable minification on release and pull ProGuard rules from proguard-tauri.pro.
12
+ - [bef4ef51](https://www.github.com/tauri-apps/tauri/commit/bef4ef51bc2c633b88db121c2087a38dddb7d6bf) feat(android): enable minify on release, add proguard rules ([#6257](https://www.github.com/tauri-apps/tauri/pull/6257)) on 2023-02-13
13
+ - Print an error if the Android project was generated with an older bundle identifier or package name.
14
+ - [79eb0542](https://www.github.com/tauri-apps/tauri/commit/79eb054292b04bb089a0e4df401a5986b33b691e) feat(cli): handle Android package identifier change ([#6314](https://www.github.com/tauri-apps/tauri/pull/6314)) on 2023-02-19
15
+ - Fixes the generated mobile build script when using an NPM runner.
16
+ - [62f15265](https://www.github.com/tauri-apps/tauri/commit/62f152659204ce1218178596f463f0bcfbd4e6dc) fix(cli): generate build script using NPM runner if it was used ([#6233](https://www.github.com/tauri-apps/tauri/pull/6233)) on 2023-02-10
17
+ - Resolve Android package name from single word bundle identifiers.
18
+ - [60a8b07d](https://www.github.com/tauri-apps/tauri/commit/60a8b07dc7c56c9c45331cb57d9afb410e7eadf3) fix: handle single word bundle identifier when resolving Android domain ([#6313](https://www.github.com/tauri-apps/tauri/pull/6313)) on 2023-02-19
19
+ - Update Android project template with fix to crash on orientation change.
20
+ - [947eb391](https://www.github.com/tauri-apps/tauri/commit/947eb391ca41cebdb11abd9ffaec642baffbf44a) fix(android): crash on orientation change due to activity recreation ([#6261](https://www.github.com/tauri-apps/tauri/pull/6261)) on 2023-02-13
21
+ - Added `--ios-color` option to the `tauri icon` command.
22
+ - [67755425](https://www.github.com/tauri-apps/tauri/commit/677554257e40e05b1af0dd61c982d6be8a8a033c) feat(cli): add `--ios-color` option to set iOS icon background color ([#6247](https://www.github.com/tauri-apps/tauri/pull/6247)) on 2023-02-12
23
+ - Fixes HMR on mobile when devPath is configured to load a filesystem path.
24
+ - [4a82da29](https://www.github.com/tauri-apps/tauri/commit/4a82da2919e0564ec993b2005dc65b5b49407b36) fix(cli): use local ip address for reload ([#6285](https://www.github.com/tauri-apps/tauri/pull/6285)) on 2023-02-16
25
+ - Ignore the `gen` folder on the dev watcher.
26
+ - [cab4ff95](https://www.github.com/tauri-apps/tauri/commit/cab4ff95b98aeac88401c1fed2d8b8940e4180cb) fix(cli): ignore the `gen` folder on the dev watcher ([#6232](https://www.github.com/tauri-apps/tauri/pull/6232)) on 2023-02-09
27
+ - Correctly pass arguments from `npm run` to `tauri`.
28
+ - [1b343bd1](https://www.github.com/tauri-apps/tauri/commit/1b343bd11686f47f24a87298d8192097c66250f6) fix(cli): use `npm run tauri -- foo` for correctly passing args to tauri ([#6448](https://www.github.com/tauri-apps/tauri/pull/6448)) on 2023-03-16
29
+ - Changed the `--api` flag on `plugin init` to `--no-api`.
30
+ - [14d03d42](https://www.github.com/tauri-apps/tauri/commit/14d03d426e86d966950a790926c04560c76203b3) refactor(cli): enhance plugin commands for mobile ([#6289](https://www.github.com/tauri-apps/tauri/pull/6289)) on 2023-02-16
31
+
32
+ ## \[2.0.0-alpha.2]
33
+
34
+ - Fixes `TAURI_*` environment variables for hook scripts on mobile commands.
35
+ - [1af9be90](https://www.github.com/tauri-apps/tauri/commit/1af9be904a309138b9f79dc741391000b1652c75) feat(cli): properly fill target for TAURI\_ env vars on mobile ([#6116](https://www.github.com/tauri-apps/tauri/pull/6116)) on 2023-01-23
36
+ - Force colored logs on mobile commands.
37
+ - [2c4a0bbd](https://www.github.com/tauri-apps/tauri/commit/2c4a0bbd1fbe15d7500264e6490772397e1917ed) feat(cli): force colored logs on mobile commands ([#5934](https://www.github.com/tauri-apps/tauri/pull/5934)) on 2022-12-28
38
+ - Keep the process alive even when the iOS application is closed.
39
+ - [dee9460f](https://www.github.com/tauri-apps/tauri/commit/dee9460f9c9bc92e9c638e7691e616849ac2085b) feat: keep CLI alive when iOS app exits, show logs, closes [#5855](https://www.github.com/tauri-apps/tauri/pull/5855) ([#5902](https://www.github.com/tauri-apps/tauri/pull/5902)) on 2022-12-27
40
+ - Show all application logs on iOS.
41
+ - [dee9460f](https://www.github.com/tauri-apps/tauri/commit/dee9460f9c9bc92e9c638e7691e616849ac2085b) feat: keep CLI alive when iOS app exits, show logs, closes [#5855](https://www.github.com/tauri-apps/tauri/pull/5855) ([#5902](https://www.github.com/tauri-apps/tauri/pull/5902)) on 2022-12-27
42
+ - Print log output for all tags on Android development.
43
+ - [8cc11149](https://www.github.com/tauri-apps/tauri/commit/8cc111494d74161e489152e52191e1442dd99759) fix(cli): print Android logs for all tags on 2023-01-17
44
+ - Add support to custom and kebab case library names for mobile apps.
45
+ - [50f6dd87](https://www.github.com/tauri-apps/tauri/commit/50f6dd87b1ac2c99f8794b055f1acba4ef7d34d3) feat: improvements to support hyphens in crate name ([#5989](https://www.github.com/tauri-apps/tauri/pull/5989)) on 2023-01-06
46
+ - Fix target directory detection when compiling for Android.
47
+ - [e873bae0](https://www.github.com/tauri-apps/tauri/commit/e873bae09f0f27517f720a753f51c1dcb903f883) fix(cli): Cargo target dir detection on Android, closes [#5865](https://www.github.com/tauri-apps/tauri/pull/5865) ([#5932](https://www.github.com/tauri-apps/tauri/pull/5932)) on 2022-12-28
48
+
3
49
  ## \[2.0.0-alpha.1]
4
50
 
5
51
  - Fixes running on device using Xcode 14.
@@ -22,6 +68,11 @@
22
68
  - First mobile alpha release!
23
69
  - [fa3a1098](https://www.github.com/tauri-apps/tauri/commit/fa3a10988a03aed1b66fb17d893b1a9adb90f7cd) feat(ci): prepare 2.0.0-alpha.0 ([#5786](https://www.github.com/tauri-apps/tauri/pull/5786)) on 2022-12-08
24
70
 
71
+ ## \[1.2.3]
72
+
73
+ - Pin `ignore` to `=0.4.18`.
74
+ - [adcb082b](https://www.github.com/tauri-apps/tauri/commit/adcb082b1651ecb2a6208b093e12f4185aa3fc98) chore(deps): pin `ignore` to =0.4.18 on 2023-01-17
75
+
25
76
  ## \[1.2.2]
26
77
 
27
78
  - Detect SvelteKit and Vite for the init and info commands.
package/Cargo.toml CHANGED
@@ -6,10 +6,13 @@ version = "0.0.0"
6
6
  [lib]
7
7
  crate-type = ["cdylib"]
8
8
 
9
+ [features]
10
+ openssl-vendored = ["tauri-cli/openssl-vendored"]
11
+
9
12
  [dependencies]
10
13
  # Default enable napi4 feature, see https://nodejs.org/api/n-api.html#node-api-version-matrix
11
14
  napi = { version = "2.10", default-features = false, features = ["napi4"] }
12
- napi-derive = "2.9"
15
+ napi-derive = "2.10"
13
16
  tauri-cli = { path = ".." }
14
17
  log = "0.4.17"
15
18
 
package/build.rs CHANGED
@@ -1,4 +1,4 @@
1
- // Copyright 2019-2022 Tauri Programme within The Commons Conservancy
1
+ // Copyright 2019-2023 Tauri Programme within The Commons Conservancy
2
2
  // SPDX-License-Identifier: Apache-2.0
3
3
  // SPDX-License-Identifier: MIT
4
4
 
package/index.d.ts CHANGED
@@ -1,3 +1,7 @@
1
+ // Copyright 2019-2023 Tauri Programme within The Commons Conservancy
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ // SPDX-License-Identifier: MIT
4
+
1
5
  /* tslint:disable */
2
6
  /* eslint-disable */
3
7
 
package/index.js CHANGED
@@ -1,3 +1,7 @@
1
+ // Copyright 2019-2023 Tauri Programme within The Commons Conservancy
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ // SPDX-License-Identifier: MIT
4
+
1
5
  const { existsSync, readFileSync } = require('fs')
2
6
  const { join } = require('path')
3
7
 
package/jest.config.js CHANGED
@@ -1,3 +1,7 @@
1
+ // Copyright 2019-2023 Tauri Programme within The Commons Conservancy
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ // SPDX-License-Identifier: MIT
4
+
1
5
  module.exports = {
2
6
  setupFilesAfterEnv: ['<rootDir>/test/jest/jest.setup.js'],
3
7
  testMatch: [
package/main.d.ts CHANGED
@@ -1,3 +1,7 @@
1
+ // Copyright 2019-2023 Tauri Programme within The Commons Conservancy
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ // SPDX-License-Identifier: MIT
4
+
1
5
  /* tslint:disable */
2
6
  /* eslint-disable */
3
7
 
package/main.js CHANGED
@@ -1,3 +1,7 @@
1
+ // Copyright 2019-2023 Tauri Programme within The Commons Conservancy
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ // SPDX-License-Identifier: MIT
4
+
1
5
  const { run, logError } = require('./index')
2
6
 
3
7
  module.exports.run = (args, binName) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tauri-apps/cli",
3
- "version": "2.0.0-alpha.1",
3
+ "version": "2.0.0-alpha.3",
4
4
  "description": "Command line interface for building Tauri apps",
5
5
  "funding": {
6
6
  "type": "opencollective",
@@ -37,13 +37,16 @@
37
37
  }
38
38
  },
39
39
  "devDependencies": {
40
- "@napi-rs/cli": "2.13.0",
40
+ "@napi-rs/cli": "2.14.4",
41
41
  "cross-env": "7.0.3",
42
42
  "cross-spawn": "7.0.3",
43
43
  "fs-extra": "11.1.0",
44
- "jest": "29.3.1",
44
+ "jest": "29.4.0",
45
45
  "jest-transform-toml": "1.0.0",
46
- "prettier": "2.8.1"
46
+ "prettier": "2.8.3"
47
+ },
48
+ "resolutions": {
49
+ "json5": "2.2.3"
47
50
  },
48
51
  "engines": {
49
52
  "node": ">= 10"
@@ -64,14 +67,14 @@
64
67
  "format:check": "prettier --check ./package.json ./tauri.js"
65
68
  },
66
69
  "optionalDependencies": {
67
- "@tauri-apps/cli-win32-x64-msvc": "2.0.0-alpha.1",
68
- "@tauri-apps/cli-darwin-x64": "2.0.0-alpha.1",
69
- "@tauri-apps/cli-linux-x64-gnu": "2.0.0-alpha.1",
70
- "@tauri-apps/cli-darwin-arm64": "2.0.0-alpha.1",
71
- "@tauri-apps/cli-linux-arm64-gnu": "2.0.0-alpha.1",
72
- "@tauri-apps/cli-linux-arm64-musl": "2.0.0-alpha.1",
73
- "@tauri-apps/cli-linux-arm-gnueabihf": "2.0.0-alpha.1",
74
- "@tauri-apps/cli-linux-x64-musl": "2.0.0-alpha.1",
75
- "@tauri-apps/cli-win32-ia32-msvc": "2.0.0-alpha.1"
70
+ "@tauri-apps/cli-win32-x64-msvc": "2.0.0-alpha.3",
71
+ "@tauri-apps/cli-darwin-x64": "2.0.0-alpha.3",
72
+ "@tauri-apps/cli-linux-x64-gnu": "2.0.0-alpha.3",
73
+ "@tauri-apps/cli-darwin-arm64": "2.0.0-alpha.3",
74
+ "@tauri-apps/cli-linux-arm64-gnu": "2.0.0-alpha.3",
75
+ "@tauri-apps/cli-linux-arm64-musl": "2.0.0-alpha.3",
76
+ "@tauri-apps/cli-linux-arm-gnueabihf": "2.0.0-alpha.3",
77
+ "@tauri-apps/cli-linux-x64-musl": "2.0.0-alpha.3",
78
+ "@tauri-apps/cli-win32-ia32-msvc": "2.0.0-alpha.3"
76
79
  }
77
80
  }
package/schema.json CHANGED
@@ -105,6 +105,7 @@
105
105
  "print": false,
106
106
  "requestUserAttention": false,
107
107
  "setAlwaysOnTop": false,
108
+ "setContentProtected": false,
108
109
  "setCursorGrab": false,
109
110
  "setCursorIcon": false,
110
111
  "setCursorPosition": false,
@@ -118,6 +119,7 @@
118
119
  "setMinSize": false,
119
120
  "setPosition": false,
120
121
  "setResizable": false,
122
+ "setShadow": false,
121
123
  "setSize": false,
122
124
  "setSkipTaskbar": false,
123
125
  "setTitle": false,
@@ -146,6 +148,7 @@
146
148
  "allowDowngrades": true,
147
149
  "certificateThumbprint": null,
148
150
  "digestAlgorithm": null,
151
+ "nsis": null,
149
152
  "timestampUrl": null,
150
153
  "tsp": false,
151
154
  "webviewFixedRuntimePath": null,
@@ -169,7 +172,8 @@
169
172
  "dialog": true,
170
173
  "pubkey": "",
171
174
  "windows": {
172
- "installMode": "passive"
175
+ "installMode": "passive",
176
+ "installerArgs": []
173
177
  }
174
178
  },
175
179
  "windows": []
@@ -206,7 +210,7 @@
206
210
  "additionalProperties": false,
207
211
  "definitions": {
208
212
  "PackageConfig": {
209
- "description": "The package configuration.",
213
+ "description": "The package configuration.\n\nSee more: https://tauri.app/v1/api/config#packageconfig",
210
214
  "type": "object",
211
215
  "properties": {
212
216
  "productName": {
@@ -229,7 +233,7 @@
229
233
  "additionalProperties": false
230
234
  },
231
235
  "TauriConfig": {
232
- "description": "The Tauri configuration object.",
236
+ "description": "The Tauri configuration object.\n\nSee more: https://tauri.app/v1/api/config#tauriconfig",
233
237
  "type": "object",
234
238
  "properties": {
235
239
  "pattern": {
@@ -283,6 +287,7 @@
283
287
  "allowDowngrades": true,
284
288
  "certificateThumbprint": null,
285
289
  "digestAlgorithm": null,
290
+ "nsis": null,
286
291
  "timestampUrl": null,
287
292
  "tsp": false,
288
293
  "webviewFixedRuntimePath": null,
@@ -380,6 +385,7 @@
380
385
  "print": false,
381
386
  "requestUserAttention": false,
382
387
  "setAlwaysOnTop": false,
388
+ "setContentProtected": false,
383
389
  "setCursorGrab": false,
384
390
  "setCursorIcon": false,
385
391
  "setCursorPosition": false,
@@ -393,6 +399,7 @@
393
399
  "setMinSize": false,
394
400
  "setPosition": false,
395
401
  "setResizable": false,
402
+ "setShadow": false,
396
403
  "setSize": false,
397
404
  "setSkipTaskbar": false,
398
405
  "setTitle": false,
@@ -427,7 +434,8 @@
427
434
  "dialog": true,
428
435
  "pubkey": "",
429
436
  "windows": {
430
- "installMode": "passive"
437
+ "installMode": "passive",
438
+ "installerArgs": []
431
439
  }
432
440
  },
433
441
  "allOf": [
@@ -504,7 +512,7 @@
504
512
  ]
505
513
  },
506
514
  "WindowConfig": {
507
- "description": "The window configuration object.",
515
+ "description": "The window configuration object.\n\nSee more: https://tauri.app/v1/api/config#windowconfig",
508
516
  "type": "object",
509
517
  "properties": {
510
518
  "label": {
@@ -643,6 +651,11 @@
643
651
  "default": false,
644
652
  "type": "boolean"
645
653
  },
654
+ "contentProtected": {
655
+ "description": "Prevents the window contents from being captured by other apps.",
656
+ "default": false,
657
+ "type": "boolean"
658
+ },
646
659
  "skipTaskbar": {
647
660
  "description": "If `true`, hides the window icon from the taskbar on Windows and Linux.",
648
661
  "default": false,
@@ -684,6 +697,18 @@
684
697
  "string",
685
698
  "null"
686
699
  ]
700
+ },
701
+ "additionalBrowserArgs": {
702
+ "description": "Defines additional browser arguments on Windows. By default wry passes `--disable-features=msWebOOUI,msPdfOOUI,msSmartScreenProtection` so if you use this method, you also need to disable these components by yourself if you want.",
703
+ "type": [
704
+ "string",
705
+ "null"
706
+ ]
707
+ },
708
+ "shadow": {
709
+ "description": "Whether or not the window has shadow.\n\n## Platform-specific\n\n- **Windows:** - `false` has no effect on decorated window, shadow are always ON. - `true` will make ndecorated window have a 1px white border, and on Windows 11, it will have a rounded corners. - **Linux:** Unsupported.",
710
+ "default": false,
711
+ "type": "boolean"
687
712
  }
688
713
  },
689
714
  "additionalProperties": false
@@ -748,7 +773,7 @@
748
773
  ]
749
774
  },
750
775
  "CliConfig": {
751
- "description": "describes a CLI configuration",
776
+ "description": "describes a CLI configuration\n\nSee more: https://tauri.app/v1/api/config#cliconfig",
752
777
  "type": "object",
753
778
  "properties": {
754
779
  "description": {
@@ -994,7 +1019,7 @@
994
1019
  "additionalProperties": false
995
1020
  },
996
1021
  "BundleConfig": {
997
- "description": "Configuration for tauri-bundler.",
1022
+ "description": "Configuration for tauri-bundler.\n\nSee more: https://tauri.app/v1/api/config#bundleconfig",
998
1023
  "type": "object",
999
1024
  "required": [
1000
1025
  "identifier"
@@ -1006,7 +1031,7 @@
1006
1031
  "type": "boolean"
1007
1032
  },
1008
1033
  "targets": {
1009
- "description": "The bundle targets, currently supports [\"deb\", \"appimage\", \"msi\", \"app\", \"dmg\", \"updater\"] or \"all\".",
1034
+ "description": "The bundle targets, currently supports [\"deb\", \"appimage\", \"nsis\", \"msi\", \"app\", \"dmg\", \"updater\"] or \"all\".",
1010
1035
  "default": "all",
1011
1036
  "allOf": [
1012
1037
  {
@@ -1120,6 +1145,7 @@
1120
1145
  "allowDowngrades": true,
1121
1146
  "certificateThumbprint": null,
1122
1147
  "digestAlgorithm": null,
1148
+ "nsis": null,
1123
1149
  "timestampUrl": null,
1124
1150
  "tsp": false,
1125
1151
  "webviewFixedRuntimePath": null,
@@ -1197,6 +1223,13 @@
1197
1223
  "msi"
1198
1224
  ]
1199
1225
  },
1226
+ {
1227
+ "description": "The NSIS bundle (.exe).",
1228
+ "type": "string",
1229
+ "enum": [
1230
+ "nsis"
1231
+ ]
1232
+ },
1200
1233
  {
1201
1234
  "description": "The macOS application bundle (.app).",
1202
1235
  "type": "string",
@@ -1221,7 +1254,7 @@
1221
1254
  ]
1222
1255
  },
1223
1256
  "AppImageConfig": {
1224
- "description": "Configuration for AppImage bundles.",
1257
+ "description": "Configuration for AppImage bundles.\n\nSee more: https://tauri.app/v1/api/config#appimageconfig",
1225
1258
  "type": "object",
1226
1259
  "properties": {
1227
1260
  "bundleMediaFramework": {
@@ -1233,7 +1266,7 @@
1233
1266
  "additionalProperties": false
1234
1267
  },
1235
1268
  "DebConfig": {
1236
- "description": "Configuration for Debian (.deb) bundles.",
1269
+ "description": "Configuration for Debian (.deb) bundles.\n\nSee more: https://tauri.app/v1/api/config#debconfig",
1237
1270
  "type": "object",
1238
1271
  "properties": {
1239
1272
  "depends": {
@@ -1258,7 +1291,7 @@
1258
1291
  "additionalProperties": false
1259
1292
  },
1260
1293
  "MacConfig": {
1261
- "description": "Configuration for the macOS bundles.",
1294
+ "description": "Configuration for the macOS bundles.\n\nSee more: https://tauri.app/v1/api/config#macconfig",
1262
1295
  "type": "object",
1263
1296
  "properties": {
1264
1297
  "frameworks": {
@@ -1318,7 +1351,7 @@
1318
1351
  "additionalProperties": false
1319
1352
  },
1320
1353
  "WindowsConfig": {
1321
- "description": "Windows bundler configuration.",
1354
+ "description": "Windows bundler configuration.\n\nSee more: https://tauri.app/v1/api/config#windowsconfig",
1322
1355
  "type": "object",
1323
1356
  "properties": {
1324
1357
  "digestAlgorithm": {
@@ -1381,6 +1414,17 @@
1381
1414
  "type": "null"
1382
1415
  }
1383
1416
  ]
1417
+ },
1418
+ "nsis": {
1419
+ "description": "Configuration for the installer generated with NSIS.",
1420
+ "anyOf": [
1421
+ {
1422
+ "$ref": "#/definitions/NsisConfig"
1423
+ },
1424
+ {
1425
+ "type": "null"
1426
+ }
1427
+ ]
1384
1428
  }
1385
1429
  },
1386
1430
  "additionalProperties": false
@@ -1491,7 +1535,7 @@
1491
1535
  ]
1492
1536
  },
1493
1537
  "WixConfig": {
1494
- "description": "Configuration for the MSI bundle using WiX.",
1538
+ "description": "Configuration for the MSI bundle using WiX.\n\nSee more: https://tauri.app/v1/api/config#wixconfig",
1495
1539
  "type": "object",
1496
1540
  "properties": {
1497
1541
  "language": {
@@ -1616,7 +1660,7 @@
1616
1660
  ]
1617
1661
  },
1618
1662
  "WixLanguageConfig": {
1619
- "description": "Configuration for a target language for the WiX build.",
1663
+ "description": "Configuration for a target language for the WiX build.\n\nSee more: https://tauri.app/v1/api/config#wixlanguageconfig",
1620
1664
  "type": "object",
1621
1665
  "properties": {
1622
1666
  "localePath": {
@@ -1629,6 +1673,91 @@
1629
1673
  },
1630
1674
  "additionalProperties": false
1631
1675
  },
1676
+ "NsisConfig": {
1677
+ "description": "Configuration for the Installer bundle using NSIS.",
1678
+ "type": "object",
1679
+ "properties": {
1680
+ "license": {
1681
+ "description": "The path to the license file to render on the installer.",
1682
+ "type": [
1683
+ "string",
1684
+ "null"
1685
+ ]
1686
+ },
1687
+ "headerImage": {
1688
+ "description": "The path to a bitmap file to display on the header of installers pages.\n\nThe recommended dimensions are 150px x 57px.",
1689
+ "type": [
1690
+ "string",
1691
+ "null"
1692
+ ]
1693
+ },
1694
+ "sidebarImage": {
1695
+ "description": "The path to a bitmap file for the Welcome page and the Finish page.\n\nThe recommended dimensions are 164px x 314px.",
1696
+ "type": [
1697
+ "string",
1698
+ "null"
1699
+ ]
1700
+ },
1701
+ "installerIcon": {
1702
+ "description": "The path to an icon file used as the installer icon.",
1703
+ "type": [
1704
+ "string",
1705
+ "null"
1706
+ ]
1707
+ },
1708
+ "installMode": {
1709
+ "description": "Whether the installation will be for all users or just the current user.",
1710
+ "default": "currentUser",
1711
+ "allOf": [
1712
+ {
1713
+ "$ref": "#/definitions/NSISInstallerMode"
1714
+ }
1715
+ ]
1716
+ },
1717
+ "languages": {
1718
+ "description": "A list of installer languages. By default the OS language is used. If the OS language is not in the list of languages, the first language will be used. To allow the user to select the language, set `display_language_selector` to `true`.\n\nSee <https://github.com/kichik/nsis/tree/9465c08046f00ccb6eda985abbdbf52c275c6c4d/Contrib/Language%20files> for the complete list of languages.",
1719
+ "type": [
1720
+ "array",
1721
+ "null"
1722
+ ],
1723
+ "items": {
1724
+ "type": "string"
1725
+ }
1726
+ },
1727
+ "displayLanguageSelector": {
1728
+ "description": "Whether to display a language selector dialog before the installer and uninstaller windows are rendered or not. By default the OS language is selected, with a fallback to the first language in the `languages` array.",
1729
+ "default": false,
1730
+ "type": "boolean"
1731
+ }
1732
+ },
1733
+ "additionalProperties": false
1734
+ },
1735
+ "NSISInstallerMode": {
1736
+ "description": "Install Modes for the NSIS installer.",
1737
+ "oneOf": [
1738
+ {
1739
+ "description": "Default mode for the installer.\n\nInstall the app by default in a directory that doesn't require Administrator access.\n\nInstaller metadata will be saved under the `HKCU` registry path.",
1740
+ "type": "string",
1741
+ "enum": [
1742
+ "currentUser"
1743
+ ]
1744
+ },
1745
+ {
1746
+ "description": "Install the app by default in the `Program Files` folder directory requires Administrator access for the installation.\n\nInstaller metadata will be saved under the `HKLM` registry path.",
1747
+ "type": "string",
1748
+ "enum": [
1749
+ "perMachine"
1750
+ ]
1751
+ },
1752
+ {
1753
+ "description": "Combines both modes and allows the user to choose at install time whether to install for the current user or per machine. Note that this mode will require Administrator access even if the user wants to install it for the current user only.\n\nInstaller metadata will be saved under the `HKLM` or `HKCU` registry path based on the user's choice.",
1754
+ "type": "string",
1755
+ "enum": [
1756
+ "both"
1757
+ ]
1758
+ }
1759
+ ]
1760
+ },
1632
1761
  "IosConfig": {
1633
1762
  "description": "General configuration for the iOS target.",
1634
1763
  "type": "object",
@@ -1644,7 +1773,7 @@
1644
1773
  "additionalProperties": false
1645
1774
  },
1646
1775
  "AllowlistConfig": {
1647
- "description": "Allowlist configuration.",
1776
+ "description": "Allowlist configuration. The allowlist is a translation of the [Cargo allowlist features](https://docs.rs/tauri/latest/tauri/#cargo-allowlist-features).\n\n# Notes\n\n- Endpoints that don't have their own allowlist option are enabled by default. - There is only \"opt-in\", no \"opt-out\". Setting an option to `false` has no effect.\n\n# Examples\n\n- * [`\"app-all\": true`](https://tauri.app/v1/api/config/#appallowlistconfig.all) will make the [hide](https://tauri.app/v1/api/js/app#hide) endpoint be available regardless of whether `hide` is set to `false` or `true` in the allowlist.",
1648
1777
  "type": "object",
1649
1778
  "properties": {
1650
1779
  "all": {
@@ -1686,6 +1815,7 @@
1686
1815
  "print": false,
1687
1816
  "requestUserAttention": false,
1688
1817
  "setAlwaysOnTop": false,
1818
+ "setContentProtected": false,
1689
1819
  "setCursorGrab": false,
1690
1820
  "setCursorIcon": false,
1691
1821
  "setCursorPosition": false,
@@ -1699,6 +1829,7 @@
1699
1829
  "setMinSize": false,
1700
1830
  "setPosition": false,
1701
1831
  "setResizable": false,
1832
+ "setShadow": false,
1702
1833
  "setSize": false,
1703
1834
  "setSkipTaskbar": false,
1704
1835
  "setTitle": false,
@@ -1858,7 +1989,7 @@
1858
1989
  "additionalProperties": false
1859
1990
  },
1860
1991
  "FsAllowlistConfig": {
1861
- "description": "Allowlist for the file system APIs.",
1992
+ "description": "Allowlist for the file system APIs.\n\nSee more: https://tauri.app/v1/api/config#fsallowlistconfig",
1862
1993
  "type": "object",
1863
1994
  "properties": {
1864
1995
  "scope": {
@@ -1958,7 +2089,7 @@
1958
2089
  ]
1959
2090
  },
1960
2091
  "WindowAllowlistConfig": {
1961
- "description": "Allowlist for the window APIs.",
2092
+ "description": "Allowlist for the window APIs.\n\nSee more: https://tauri.app/v1/api/config#windowallowlistconfig",
1962
2093
  "type": "object",
1963
2094
  "properties": {
1964
2095
  "all": {
@@ -2031,11 +2162,21 @@
2031
2162
  "default": false,
2032
2163
  "type": "boolean"
2033
2164
  },
2165
+ "setShadow": {
2166
+ "description": "Allows setting the shadow flag of the window.",
2167
+ "default": false,
2168
+ "type": "boolean"
2169
+ },
2034
2170
  "setAlwaysOnTop": {
2035
2171
  "description": "Allows setting the always_on_top flag of the window.",
2036
2172
  "default": false,
2037
2173
  "type": "boolean"
2038
2174
  },
2175
+ "setContentProtected": {
2176
+ "description": "Allows preventing the window contents from being captured by other apps.",
2177
+ "default": false,
2178
+ "type": "boolean"
2179
+ },
2039
2180
  "setSize": {
2040
2181
  "description": "Allows setting the window size.",
2041
2182
  "default": false,
@@ -2115,7 +2256,7 @@
2115
2256
  "additionalProperties": false
2116
2257
  },
2117
2258
  "ShellAllowlistConfig": {
2118
- "description": "Allowlist for the shell APIs.",
2259
+ "description": "Allowlist for the shell APIs.\n\nSee more: https://tauri.app/v1/api/config#shellallowlistconfig",
2119
2260
  "type": "object",
2120
2261
  "properties": {
2121
2262
  "scope": {
@@ -2236,7 +2377,7 @@
2236
2377
  "description": "Defines the `shell > open` api scope.",
2237
2378
  "anyOf": [
2238
2379
  {
2239
- "description": "If the shell open API should be enabled.\n\nIf enabled, the default validation regex (`^https?://`) is used.",
2380
+ "description": "If the shell open API should be enabled.\n\nIf enabled, the default validation regex (`^((mailto:\\w+)|(tel:\\w+)|(https?://\\w+)).+`) is used.",
2240
2381
  "type": "boolean"
2241
2382
  },
2242
2383
  {
@@ -2246,7 +2387,7 @@
2246
2387
  ]
2247
2388
  },
2248
2389
  "DialogAllowlistConfig": {
2249
- "description": "Allowlist for the dialog APIs.",
2390
+ "description": "Allowlist for the dialog APIs.\n\nSee more: https://tauri.app/v1/api/config#dialogallowlistconfig",
2250
2391
  "type": "object",
2251
2392
  "properties": {
2252
2393
  "all": {
@@ -2283,7 +2424,7 @@
2283
2424
  "additionalProperties": false
2284
2425
  },
2285
2426
  "HttpAllowlistConfig": {
2286
- "description": "Allowlist for the HTTP APIs.",
2427
+ "description": "Allowlist for the HTTP APIs.\n\nSee more: https://tauri.app/v1/api/config#httpallowlistconfig",
2287
2428
  "type": "object",
2288
2429
  "properties": {
2289
2430
  "scope": {
@@ -2317,7 +2458,7 @@
2317
2458
  }
2318
2459
  },
2319
2460
  "NotificationAllowlistConfig": {
2320
- "description": "Allowlist for the notification APIs.",
2461
+ "description": "Allowlist for the notification APIs.\n\nSee more: https://tauri.app/v1/api/config#notificationallowlistconfig",
2321
2462
  "type": "object",
2322
2463
  "properties": {
2323
2464
  "all": {
@@ -2329,7 +2470,7 @@
2329
2470
  "additionalProperties": false
2330
2471
  },
2331
2472
  "GlobalShortcutAllowlistConfig": {
2332
- "description": "Allowlist for the global shortcut APIs.",
2473
+ "description": "Allowlist for the global shortcut APIs.\n\nSee more: https://tauri.app/v1/api/config#globalshortcutallowlistconfig",
2333
2474
  "type": "object",
2334
2475
  "properties": {
2335
2476
  "all": {
@@ -2341,7 +2482,7 @@
2341
2482
  "additionalProperties": false
2342
2483
  },
2343
2484
  "OsAllowlistConfig": {
2344
- "description": "Allowlist for the OS APIs.",
2485
+ "description": "Allowlist for the OS APIs.\n\nSee more: https://tauri.app/v1/api/config#osallowlistconfig",
2345
2486
  "type": "object",
2346
2487
  "properties": {
2347
2488
  "all": {
@@ -2353,7 +2494,7 @@
2353
2494
  "additionalProperties": false
2354
2495
  },
2355
2496
  "PathAllowlistConfig": {
2356
- "description": "Allowlist for the path APIs.",
2497
+ "description": "Allowlist for the path APIs.\n\nSee more: https://tauri.app/v1/api/config#pathallowlistconfig",
2357
2498
  "type": "object",
2358
2499
  "properties": {
2359
2500
  "all": {
@@ -2365,7 +2506,7 @@
2365
2506
  "additionalProperties": false
2366
2507
  },
2367
2508
  "ProtocolAllowlistConfig": {
2368
- "description": "Allowlist for the custom protocols.",
2509
+ "description": "Allowlist for the custom protocols.\n\nSee more: https://tauri.app/v1/api/config#protocolallowlistconfig",
2369
2510
  "type": "object",
2370
2511
  "properties": {
2371
2512
  "assetScope": {
@@ -2391,7 +2532,7 @@
2391
2532
  "additionalProperties": false
2392
2533
  },
2393
2534
  "ProcessAllowlistConfig": {
2394
- "description": "Allowlist for the process APIs.",
2535
+ "description": "Allowlist for the process APIs.\n\nSee more: https://tauri.app/v1/api/config#processallowlistconfig",
2395
2536
  "type": "object",
2396
2537
  "properties": {
2397
2538
  "all": {
@@ -2418,7 +2559,7 @@
2418
2559
  "additionalProperties": false
2419
2560
  },
2420
2561
  "ClipboardAllowlistConfig": {
2421
- "description": "Allowlist for the clipboard APIs.",
2562
+ "description": "Allowlist for the clipboard APIs.\n\nSee more: https://tauri.app/v1/api/config#clipboardallowlistconfig",
2422
2563
  "type": "object",
2423
2564
  "properties": {
2424
2565
  "all": {
@@ -2440,7 +2581,7 @@
2440
2581
  "additionalProperties": false
2441
2582
  },
2442
2583
  "AppAllowlistConfig": {
2443
- "description": "Allowlist for the app APIs.",
2584
+ "description": "Allowlist for the app APIs.\n\nSee more: https://tauri.app/v1/api/config#appallowlistconfig",
2444
2585
  "type": "object",
2445
2586
  "properties": {
2446
2587
  "all": {
@@ -2462,7 +2603,7 @@
2462
2603
  "additionalProperties": false
2463
2604
  },
2464
2605
  "SecurityConfig": {
2465
- "description": "Security configuration.",
2606
+ "description": "Security configuration.\n\nSee more: https://tauri.app/v1/api/config#securityconfig",
2466
2607
  "type": "object",
2467
2608
  "properties": {
2468
2609
  "csp": {
@@ -2553,7 +2694,7 @@
2553
2694
  ]
2554
2695
  },
2555
2696
  "UpdaterConfig": {
2556
- "description": "The Updater configuration object.",
2697
+ "description": "The Updater configuration object.\n\nSee more: https://tauri.app/v1/api/config#updaterconfig",
2557
2698
  "type": "object",
2558
2699
  "properties": {
2559
2700
  "active": {
@@ -2584,7 +2725,8 @@
2584
2725
  "windows": {
2585
2726
  "description": "The Windows configuration for the updater.",
2586
2727
  "default": {
2587
- "installMode": "passive"
2728
+ "installMode": "passive",
2729
+ "installerArgs": []
2588
2730
  },
2589
2731
  "allOf": [
2590
2732
  {
@@ -2601,9 +2743,17 @@
2601
2743
  "format": "uri"
2602
2744
  },
2603
2745
  "UpdaterWindowsConfig": {
2604
- "description": "The updater configuration for Windows.",
2746
+ "description": "The updater configuration for Windows.\n\nSee more: https://tauri.app/v1/api/config#updaterwindowsconfig",
2605
2747
  "type": "object",
2606
2748
  "properties": {
2749
+ "installerArgs": {
2750
+ "description": "Additional arguments given to the NSIS or WiX installer.",
2751
+ "default": [],
2752
+ "type": "array",
2753
+ "items": {
2754
+ "type": "string"
2755
+ }
2756
+ },
2607
2757
  "installMode": {
2608
2758
  "description": "The installation mode for the update on Windows. Defaults to `passive`.",
2609
2759
  "default": "passive",
@@ -2627,7 +2777,7 @@
2627
2777
  ]
2628
2778
  },
2629
2779
  {
2630
- "description": "The quiet mode means there's no user interaction required. Requires admin privileges if the installer does.",
2780
+ "description": "The quiet mode means there's no user interaction required. Requires admin privileges if the installer does (WiX).",
2631
2781
  "type": "string",
2632
2782
  "enum": [
2633
2783
  "quiet"
@@ -2643,7 +2793,7 @@
2643
2793
  ]
2644
2794
  },
2645
2795
  "SystemTrayConfig": {
2646
- "description": "Configuration for application system tray icon.",
2796
+ "description": "Configuration for application system tray icon.\n\nSee more: https://tauri.app/v1/api/config#systemtrayconfig",
2647
2797
  "type": "object",
2648
2798
  "required": [
2649
2799
  "iconPath"
@@ -2674,7 +2824,7 @@
2674
2824
  "additionalProperties": false
2675
2825
  },
2676
2826
  "BuildConfig": {
2677
- "description": "The Build configuration object.",
2827
+ "description": "The Build configuration object.\n\nSee more: https://tauri.app/v1/api/config#buildconfig",
2678
2828
  "type": "object",
2679
2829
  "properties": {
2680
2830
  "runner": {
@@ -2837,7 +2987,7 @@
2837
2987
  ]
2838
2988
  },
2839
2989
  "PluginConfig": {
2840
- "description": "The plugin configs holds a HashMap mapping a plugin name to its configuration object.",
2990
+ "description": "The plugin configs holds a HashMap mapping a plugin name to its configuration object.\n\nSee more: https://tauri.app/v1/api/config#pluginconfig",
2841
2991
  "type": "object",
2842
2992
  "additionalProperties": true
2843
2993
  }
package/src/lib.rs CHANGED
@@ -1,4 +1,4 @@
1
- // Copyright 2019-2022 Tauri Programme within The Commons Conservancy
1
+ // Copyright 2019-2023 Tauri Programme within The Commons Conservancy
2
2
  // SPDX-License-Identifier: Apache-2.0
3
3
  // SPDX-License-Identifier: MIT
4
4
 
package/tauri.js CHANGED
@@ -1,5 +1,9 @@
1
1
  #!/usr/bin/env node
2
2
 
3
+ // Copyright 2019-2023 Tauri Programme within The Commons Conservancy
4
+ // SPDX-License-Identifier: Apache-2.0
5
+ // SPDX-License-Identifier: MIT
6
+
3
7
  const cli = require('./main')
4
8
  const path = require('path')
5
9
 
@@ -16,7 +20,7 @@ if (bin === '@tauri-apps/cli') {
16
20
  }
17
21
  // Even if started by a package manager, the binary will be NodeJS.
18
22
  // Some distribution still use "nodejs" as the binary name.
19
- else if (binStem.match(/(nodejs|node)([1-9]*)*$/g)) {
23
+ else if (binStem.match(/(nodejs|node)\-?([1-9]*)*$/g)) {
20
24
  const managerStem = process.env.npm_execpath
21
25
  ? path.parse(process.env.npm_execpath).name.toLowerCase()
22
26
  : null