@tauri-apps/cli 2.9.6 → 2.10.1

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,60 @@
1
1
  # Changelog
2
2
 
3
+ ## \[2.10.1]
4
+
5
+ ### Bug Fixes
6
+
7
+ - [`35c35f27a`](https://www.github.com/tauri-apps/tauri/commit/35c35f27aedc430b602ec74059b271128c15ad36) ([#14931](https://www.github.com/tauri-apps/tauri/pull/14931) by [@lucasfernog](https://www.github.com/tauri-apps/tauri/../../lucasfernog)) Support comma-separated list of Cargo features on all commands.
8
+ - [`0d1cb83ba`](https://www.github.com/tauri-apps/tauri/commit/0d1cb83bab2aa482c7d73116893fd7ff6aa56283) ([#14932](https://www.github.com/tauri-apps/tauri/pull/14932) by [@lucasfernog](https://www.github.com/tauri-apps/tauri/../../lucasfernog)) Fix missing Cargo args when running mobile dev and build commands.
9
+ - [`33754ae5e`](https://www.github.com/tauri-apps/tauri/commit/33754ae5e3740d022483b6164511c5c001a3c24b) ([#15022](https://www.github.com/tauri-apps/tauri/pull/15022) by [@Legend-Master](https://www.github.com/tauri-apps/tauri/../../Legend-Master)) Fix updater signing private keys generated using `tauri signer generate` with empty password can't be used (The keys generated during tauri were broken between v2.9.3 and v2.10.0, you'll need to regenerate them)
10
+
11
+ ### What's Changed
12
+
13
+ - [`7be58a1c6`](https://www.github.com/tauri-apps/tauri/commit/7be58a1c643a7ed6d0f484a7e1134022618eb2b2) ([#14894](https://www.github.com/tauri-apps/tauri/pull/14894) by [@Legend-Master](https://www.github.com/tauri-apps/tauri/../../Legend-Master)) Log patching bundle type information again
14
+
15
+ ### Dependencies
16
+
17
+ - Upgraded to `tauri-cli@2.10.1`
18
+
19
+ ## \[2.10.0]
20
+
21
+ ### Enhancements
22
+
23
+ - [`f82594410`](https://www.github.com/tauri-apps/tauri/commit/f82594410cd57d6f794f58d4afea0ed335aa796f) ([#13253](https://www.github.com/tauri-apps/tauri/pull/13253) by [@Armaldio](https://www.github.com/tauri-apps/tauri/../../Armaldio)) Allow electron to run the CLI directly
24
+ - [`a2abe2e6b`](https://www.github.com/tauri-apps/tauri/commit/a2abe2e6bcb9e1eed8484240dfdb76a5bc28ae58) ([#14607](https://www.github.com/tauri-apps/tauri/pull/14607) by [@sftse](https://www.github.com/tauri-apps/tauri/../../sftse)) Simplified internal representation of `features: Option<Vec<String>>` with `Vec<String>`, no user facing changes
25
+ - [`84b04c4a8`](https://www.github.com/tauri-apps/tauri/commit/84b04c4a8d3310b7a7091d10e36244bf94996e51) ([#14759](https://www.github.com/tauri-apps/tauri/pull/14759) by [@amrbashir](https://www.github.com/tauri-apps/tauri/../../amrbashir)) Added new environment variables for `tauri signer sign` command, to align with existing environment variables used in `tauri build`, `tauri bundle` and `tauri signer generate`
26
+
27
+ - `TAURI_SIGNING_PRIVATE_KEY`
28
+ - `TAURI_SIGNING_PRIVATE_KEY_PATH`
29
+ - `TAURI_SIGNING_PRIVATE_KEY_PASSWORD`
30
+
31
+ The old environment variables are deprecated and will be removed in a future release.
32
+
33
+ - `TAURI_PRIVATE_KEY`
34
+ - `TAURI_PRIVATE_KEY_PATH`
35
+ - `TAURI_PRIVATE_KEY_PASSWORD`
36
+
37
+ ### Bug Fixes
38
+
39
+ - [`62aa13a12`](https://www.github.com/tauri-apps/tauri/commit/62aa13a124ef46bb5ce9887a2a574dd35ef86d4f) ([#14629](https://www.github.com/tauri-apps/tauri/pull/14629) by [@lucasfernog](https://www.github.com/tauri-apps/tauri/../../lucasfernog)) Fix `android build`'s `--aab` and `--apk` flags requiring a value to be provided.
40
+ - [`eccff9758`](https://www.github.com/tauri-apps/tauri/commit/eccff97588232055bd0cafd83e6ee03d11a501fb) ([#14779](https://www.github.com/tauri-apps/tauri/pull/14779) by [@lucasfernog](https://www.github.com/tauri-apps/tauri/../../lucasfernog)) Fix empty associated-domains entitlements when domains are not configured for deep links.
41
+ - [`ea31b07f1`](https://www.github.com/tauri-apps/tauri/commit/ea31b07f19e0aa467ed0f921f60575cfe09809c8) ([#14789](https://www.github.com/tauri-apps/tauri/pull/14789) by [@Legend-Master](https://www.github.com/tauri-apps/tauri/../../Legend-Master)) Fixed the command description for `tauri inspect`
42
+ - [`7fca58230`](https://www.github.com/tauri-apps/tauri/commit/7fca58230f97c3e6834134419514a0c7dbbe784b) ([#14830](https://www.github.com/tauri-apps/tauri/pull/14830) by [@Legend-Master](https://www.github.com/tauri-apps/tauri/../../Legend-Master)) Updated `nsis_tauri_utils` to 0.5.3:
43
+
44
+ - Use an alternative method `CreateProcessWithTokenW` to run programs as user, this fixed a problem that the program launched with the previous method can't query its own handle
45
+ - [`53611c4d7`](https://www.github.com/tauri-apps/tauri/commit/53611c4d7bdaf89b9a5d7c46a9c4bf4e34216148) ([#14747](https://www.github.com/tauri-apps/tauri/pull/14747) by [@Legend-Master](https://www.github.com/tauri-apps/tauri/../../Legend-Master)) Only watch dependent workspace members when running `tauri dev` instead of watching on all members
46
+ - [`1b0e335d3`](https://www.github.com/tauri-apps/tauri/commit/1b0e335d3f3445948d6590f7e074275d97cd9859) ([#14713](https://www.github.com/tauri-apps/tauri/pull/14713) by [@wasuaje](https://www.github.com/tauri-apps/tauri/../../wasuaje)) `tauri signer sign` doesn't work for files without an extension
47
+
48
+ ### What's Changed
49
+
50
+ - [`e3fdcb500`](https://www.github.com/tauri-apps/tauri/commit/e3fdcb5002b362b46cde2a1971e4e7f2a1161208) ([#14836](https://www.github.com/tauri-apps/tauri/pull/14836) by [@sftse](https://www.github.com/tauri-apps/tauri/../../sftse)) Continued refactors of tauri-cli, fix too weak atomics.
51
+ - [`0575dd287`](https://www.github.com/tauri-apps/tauri/commit/0575dd287e021b61d2aedf64d62ae84a2c925fb4) ([#14521](https://www.github.com/tauri-apps/tauri/pull/14521) by [@kandrelczyk](https://www.github.com/tauri-apps/tauri/../../kandrelczyk)) Change the way bundle type information is added to binary files. Instead of looking up the value of a variable we simply look for the default value.
52
+ - [`7f7d9aac2`](https://www.github.com/tauri-apps/tauri/commit/7f7d9aac214e22d9492490543f7a9bcae0a6659e) ([#14668](https://www.github.com/tauri-apps/tauri/pull/14668) by [@sftse](https://www.github.com/tauri-apps/tauri/../../sftse)) Refactored internal use of static on config and directory resolvings, no user facing changes, please report any regressions if you encounter any
53
+
54
+ ### Dependencies
55
+
56
+ - Upgraded to `tauri-cli@2.10.0`
57
+
3
58
  ## \[2.9.6]
4
59
 
5
60
  ### Dependencies
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "$schema": "http://json-schema.org/draft-07/schema#",
3
- "$id": "https://schema.tauri.app/config/2.9.5",
3
+ "$id": "https://schema.tauri.app/config/2.10.3",
4
4
  "title": "Config",
5
5
  "description": "The Tauri configuration object.\n It is read from a file where you can define your frontend assets,\n configure the bundler and define a tray icon.\n\n The configuration file is generated by the\n [`tauri init`](https://v2.tauri.app/reference/cli/#init) command that lives in\n your Tauri application source directory (src-tauri).\n\n Once generated, you may modify it at will to customize your Tauri application.\n\n ## File Formats\n\n By default, the configuration is defined as a JSON file named `tauri.conf.json`.\n\n Tauri also supports JSON5 and TOML files via the `config-json5` and `config-toml` Cargo features, respectively.\n The JSON5 file name must be either `tauri.conf.json` or `tauri.conf.json5`.\n The TOML file name is `Tauri.toml`.\n\n ## Platform-Specific Configuration\n\n In addition to the default configuration file, Tauri can\n read a platform-specific configuration from `tauri.linux.conf.json`,\n `tauri.windows.conf.json`, `tauri.macos.conf.json`, `tauri.android.conf.json` and `tauri.ios.conf.json`\n (or `Tauri.linux.toml`, `Tauri.windows.toml`, `Tauri.macos.toml`, `Tauri.android.toml` and `Tauri.ios.toml` if the `Tauri.toml` format is used),\n which gets merged with the main configuration object.\n\n ## Configuration Structure\n\n The configuration is composed of the following objects:\n\n - [`app`](#appconfig): The Tauri configuration\n - [`build`](#buildconfig): The build configuration\n - [`bundle`](#bundleconfig): The bundle configurations\n - [`plugins`](#pluginconfig): The plugins configuration\n\n Example tauri.config.json file:\n\n ```json\n {\n \"productName\": \"tauri-app\",\n \"version\": \"0.1.0\",\n \"build\": {\n \"beforeBuildCommand\": \"\",\n \"beforeDevCommand\": \"\",\n \"devUrl\": \"http://localhost:3000\",\n \"frontendDist\": \"../dist\"\n },\n \"app\": {\n \"security\": {\n \"csp\": null\n },\n \"windows\": [\n {\n \"fullscreen\": false,\n \"height\": 600,\n \"resizable\": true,\n \"title\": \"Tauri App\",\n \"width\": 800\n }\n ]\n },\n \"bundle\": {},\n \"plugins\": {}\n }\n ```",
6
6
  "type": "object",
@@ -165,7 +165,7 @@
165
165
  "type": "object",
166
166
  "properties": {
167
167
  "windows": {
168
- "description": "The app windows configuration.\n\n ## Example:\n\n To create a window at app startup\n\n ```json\n {\n \"app\": {\n \"windows\": [\n { \"width\": 800, \"height\": 600 }\n ]\n }\n }\n ```\n\n If not specified, the window's label (its identifier) defaults to \"main\",\n you can use this label to get the window through\n `app.get_webview_window` in Rust or `WebviewWindow.getByLabel` in JavaScript\n\n When working with multiple windows, each window will need an unique label\n\n ```json\n {\n \"app\": {\n \"windows\": [\n { \"label\": \"main\", \"width\": 800, \"height\": 600 },\n { \"label\": \"secondary\", \"width\": 800, \"height\": 600 }\n ]\n }\n }\n ```\n\n You can also set `create` to false and use this config through the Rust APIs\n\n ```json\n {\n \"app\": {\n \"windows\": [\n { \"create\": false, \"width\": 800, \"height\": 600 }\n ]\n }\n }\n ```\n\n and use it like this\n\n ```rust\n tauri::Builder::default()\n .setup(|app| {\n tauri::WebviewWindowBuilder::from_config(app.handle(), app.config().app.windows[0])?.build()?;\n Ok(())\n });\n ```",
168
+ "description": "The app windows configuration.\n\n ## Example:\n\n To create a window at app startup\n\n ```json\n {\n \"app\": {\n \"windows\": [\n { \"width\": 800, \"height\": 600 }\n ]\n }\n }\n ```\n\n If not specified, the window's label (its identifier) defaults to \"main\",\n you can use this label to get the window through\n `app.get_webview_window` in Rust or `WebviewWindow.getByLabel` in JavaScript\n\n When working with multiple windows, each window will need an unique label\n\n ```json\n {\n \"app\": {\n \"windows\": [\n { \"label\": \"main\", \"width\": 800, \"height\": 600 },\n { \"label\": \"secondary\", \"width\": 800, \"height\": 600 }\n ]\n }\n }\n ```\n\n You can also set `create` to false and use this config through the Rust APIs\n\n ```json\n {\n \"app\": {\n \"windows\": [\n { \"create\": false, \"width\": 800, \"height\": 600 }\n ]\n }\n }\n ```\n\n and use it like this\n\n ```rust\n tauri::Builder::default()\n .setup(|app| {\n tauri::WebviewWindowBuilder::from_config(app.handle(), &app.config().app.windows[0])?.build()?;\n Ok(())\n });\n ```",
169
169
  "default": [],
170
170
  "type": "array",
171
171
  "items": {
@@ -231,7 +231,7 @@
231
231
  "type": "string"
232
232
  },
233
233
  "create": {
234
- "description": "Whether Tauri should create this window at app startup or not.\n\n When this is set to `false` you must manually grab the config object via `app.config().app.windows`\n and create it with [`WebviewWindowBuilder::from_config`](https://docs.rs/tauri/2/tauri/webview/struct.WebviewWindowBuilder.html#method.from_config).\n\n ## Example:\n\n ```rust\n tauri::Builder::default()\n .setup(|app| {\n tauri::WebviewWindowBuilder::from_config(app.handle(), app.config().app.windows[0])?.build()?;\n Ok(())\n });\n ```",
234
+ "description": "Whether Tauri should create this window at app startup or not.\n\n When this is set to `false` you must manually grab the config object via `app.config().app.windows`\n and create it with [`WebviewWindowBuilder::from_config`](https://docs.rs/tauri/2/tauri/webview/struct.WebviewWindowBuilder.html#method.from_config).\n\n ## Example:\n\n ```rust\n tauri::Builder::default()\n .setup(|app| {\n tauri::WebviewWindowBuilder::from_config(app.handle(), &app.config().app.windows[0])?.build()?;\n Ok(())\n });\n ```",
235
235
  "default": true,
236
236
  "type": "boolean"
237
237
  },
@@ -262,7 +262,7 @@
262
262
  "type": "boolean"
263
263
  },
264
264
  "x": {
265
- "description": "The horizontal position of the window's top left corner",
265
+ "description": "The horizontal position of the window's top left corner in logical pixels",
266
266
  "type": [
267
267
  "number",
268
268
  "null"
@@ -270,7 +270,7 @@
270
270
  "format": "double"
271
271
  },
272
272
  "y": {
273
- "description": "The vertical position of the window's top left corner",
273
+ "description": "The vertical position of the window's top left corner in logical pixels",
274
274
  "type": [
275
275
  "number",
276
276
  "null"
@@ -278,19 +278,19 @@
278
278
  "format": "double"
279
279
  },
280
280
  "width": {
281
- "description": "The window width.",
281
+ "description": "The window width in logical pixels.",
282
282
  "default": 800.0,
283
283
  "type": "number",
284
284
  "format": "double"
285
285
  },
286
286
  "height": {
287
- "description": "The window height.",
287
+ "description": "The window height in logical pixels.",
288
288
  "default": 600.0,
289
289
  "type": "number",
290
290
  "format": "double"
291
291
  },
292
292
  "minWidth": {
293
- "description": "The min window width.",
293
+ "description": "The min window width in logical pixels.",
294
294
  "type": [
295
295
  "number",
296
296
  "null"
@@ -298,7 +298,7 @@
298
298
  "format": "double"
299
299
  },
300
300
  "minHeight": {
301
- "description": "The min window height.",
301
+ "description": "The min window height in logical pixels.",
302
302
  "type": [
303
303
  "number",
304
304
  "null"
@@ -306,7 +306,7 @@
306
306
  "format": "double"
307
307
  },
308
308
  "maxWidth": {
309
- "description": "The max window width.",
309
+ "description": "The max window width in logical pixels.",
310
310
  "type": [
311
311
  "number",
312
312
  "null"
@@ -314,7 +314,7 @@
314
314
  "format": "double"
315
315
  },
316
316
  "maxHeight": {
317
- "description": "The max window height.",
317
+ "description": "The max window height in logical pixels.",
318
318
  "type": [
319
319
  "number",
320
320
  "null"
@@ -652,13 +652,13 @@
652
652
  ],
653
653
  "properties": {
654
654
  "width": {
655
- "description": "Horizontal margin in physical unit",
655
+ "description": "Horizontal margin in physical pixels",
656
656
  "type": "integer",
657
657
  "format": "uint32",
658
658
  "minimum": 0.0
659
659
  },
660
660
  "height": {
661
- "description": "Vertical margin in physical unit",
661
+ "description": "Vertical margin in physical pixels",
662
662
  "type": "integer",
663
663
  "format": "uint32",
664
664
  "minimum": 0.0
@@ -1991,7 +1991,7 @@
1991
1991
  "description": "Defines the URL or assets to embed in the application.",
1992
1992
  "anyOf": [
1993
1993
  {
1994
- "description": "An external URL that should be used as the default application URL.",
1994
+ "description": "An external URL that should be used as the default application URL. No assets are embedded in the app in this case.",
1995
1995
  "type": "string",
1996
1996
  "format": "uri"
1997
1997
  },
@@ -2000,7 +2000,7 @@
2000
2000
  "type": "string"
2001
2001
  },
2002
2002
  {
2003
- "description": "An array of files to embed on the app.",
2003
+ "description": "An array of files to embed in the app.",
2004
2004
  "type": "array",
2005
2005
  "items": {
2006
2006
  "type": "string"
@@ -2792,7 +2792,7 @@
2792
2792
  "type": "object",
2793
2793
  "properties": {
2794
2794
  "version": {
2795
- "description": "MSI installer version in the format `major.minor.patch.build` (build is optional).\n\n Because a valid version is required for MSI installer, it will be derived from [`Config::version`] if this field is not set.\n\n The first field is the major version and has a maximum value of 255. The second field is the minor version and has a maximum value of 255.\n The third and foruth fields have a maximum value of 65,535.\n\n See <https://learn.microsoft.com/en-us/windows/win32/msi/productversion> for more info.",
2795
+ "description": "MSI installer version in the format `major.minor.patch.build` (build is optional).\n\n Because a valid version is required for MSI installer, it will be derived from [`Config::version`] if this field is not set.\n\n The first field is the major version and has a maximum value of 255. The second field is the minor version and has a maximum value of 255.\n The third and fourth fields have a maximum value of 65,535.\n\n See <https://learn.microsoft.com/en-us/windows/win32/msi/productversion> for more info.",
2796
2796
  "type": [
2797
2797
  "string",
2798
2798
  "null"
@@ -3096,7 +3096,7 @@
3096
3096
  "description": "Custom Signing Command configuration.",
3097
3097
  "anyOf": [
3098
3098
  {
3099
- "description": "A string notation of the script to execute.\n\n \"%1\" will be replaced with the path to the binary to be signed.\n\n This is a simpler notation for the command.\n Tauri will split the string with `' '` and use the first element as the command name and the rest as arguments.\n\n If you need to use whitespace in the command or arguments, use the object notation [`Self::ScriptWithOptions`].",
3099
+ "description": "A string notation of the script to execute.\n\n \"%1\" will be replaced with the path to the binary to be signed.\n\n This is a simpler notation for the command.\n Tauri will split the string with `' '` and use the first element as the command name and the rest as arguments.\n\n If you need to use whitespace in the command or arguments, use the object notation [`Self::CommandWithOptions`].",
3100
3100
  "type": "string"
3101
3101
  },
3102
3102
  {
package/index.js CHANGED
@@ -7,9 +7,6 @@
7
7
  // @ts-nocheck
8
8
  /* auto-generated by NAPI-RS */
9
9
 
10
- const { createRequire } = require('node:module')
11
- require = createRequire(__filename)
12
-
13
10
  const { readFileSync } = require('node:fs')
14
11
  let nativeBinding = null
15
12
  const loadErrors = []
@@ -70,7 +67,7 @@ const isMuslFromChildProcess = () => {
70
67
  function requireNative() {
71
68
  if (process.env.NAPI_RS_NATIVE_LIBRARY_PATH) {
72
69
  try {
73
- nativeBinding = require(process.env.NAPI_RS_NATIVE_LIBRARY_PATH);
70
+ return require(process.env.NAPI_RS_NATIVE_LIBRARY_PATH);
74
71
  } catch (err) {
75
72
  loadErrors.push(err)
76
73
  }
@@ -82,7 +79,12 @@ function requireNative() {
82
79
  loadErrors.push(e)
83
80
  }
84
81
  try {
85
- return require('@tauri-apps/cli-android-arm64')
82
+ const binding = require('@tauri-apps/cli-android-arm64')
83
+ const bindingPackageVersion = require('@tauri-apps/cli-android-arm64/package.json').version
84
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
85
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
86
+ }
87
+ return binding
86
88
  } catch (e) {
87
89
  loadErrors.push(e)
88
90
  }
@@ -93,7 +95,12 @@ function requireNative() {
93
95
  loadErrors.push(e)
94
96
  }
95
97
  try {
96
- return require('@tauri-apps/cli-android-arm-eabi')
98
+ const binding = require('@tauri-apps/cli-android-arm-eabi')
99
+ const bindingPackageVersion = require('@tauri-apps/cli-android-arm-eabi/package.json').version
100
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
101
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
102
+ }
103
+ return binding
97
104
  } catch (e) {
98
105
  loadErrors.push(e)
99
106
  }
@@ -102,16 +109,39 @@ function requireNative() {
102
109
  }
103
110
  } else if (process.platform === 'win32') {
104
111
  if (process.arch === 'x64') {
112
+ if (process.config?.variables?.shlib_suffix === 'dll.a' || process.config?.variables?.node_target_type === 'shared_library') {
113
+ try {
114
+ return require('./cli.win32-x64-gnu.node')
115
+ } catch (e) {
116
+ loadErrors.push(e)
117
+ }
105
118
  try {
119
+ const binding = require('@tauri-apps/cli-win32-x64-gnu')
120
+ const bindingPackageVersion = require('@tauri-apps/cli-win32-x64-gnu/package.json').version
121
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
122
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
123
+ }
124
+ return binding
125
+ } catch (e) {
126
+ loadErrors.push(e)
127
+ }
128
+ } else {
129
+ try {
106
130
  return require('./cli.win32-x64-msvc.node')
107
131
  } catch (e) {
108
132
  loadErrors.push(e)
109
133
  }
110
134
  try {
111
- return require('@tauri-apps/cli-win32-x64-msvc')
135
+ const binding = require('@tauri-apps/cli-win32-x64-msvc')
136
+ const bindingPackageVersion = require('@tauri-apps/cli-win32-x64-msvc/package.json').version
137
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
138
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
139
+ }
140
+ return binding
112
141
  } catch (e) {
113
142
  loadErrors.push(e)
114
143
  }
144
+ }
115
145
  } else if (process.arch === 'ia32') {
116
146
  try {
117
147
  return require('./cli.win32-ia32-msvc.node')
@@ -119,7 +149,12 @@ function requireNative() {
119
149
  loadErrors.push(e)
120
150
  }
121
151
  try {
122
- return require('@tauri-apps/cli-win32-ia32-msvc')
152
+ const binding = require('@tauri-apps/cli-win32-ia32-msvc')
153
+ const bindingPackageVersion = require('@tauri-apps/cli-win32-ia32-msvc/package.json').version
154
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
155
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
156
+ }
157
+ return binding
123
158
  } catch (e) {
124
159
  loadErrors.push(e)
125
160
  }
@@ -130,7 +165,12 @@ function requireNative() {
130
165
  loadErrors.push(e)
131
166
  }
132
167
  try {
133
- return require('@tauri-apps/cli-win32-arm64-msvc')
168
+ const binding = require('@tauri-apps/cli-win32-arm64-msvc')
169
+ const bindingPackageVersion = require('@tauri-apps/cli-win32-arm64-msvc/package.json').version
170
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
171
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
172
+ }
173
+ return binding
134
174
  } catch (e) {
135
175
  loadErrors.push(e)
136
176
  }
@@ -144,7 +184,12 @@ function requireNative() {
144
184
  loadErrors.push(e)
145
185
  }
146
186
  try {
147
- return require('@tauri-apps/cli-darwin-universal')
187
+ const binding = require('@tauri-apps/cli-darwin-universal')
188
+ const bindingPackageVersion = require('@tauri-apps/cli-darwin-universal/package.json').version
189
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
190
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
191
+ }
192
+ return binding
148
193
  } catch (e) {
149
194
  loadErrors.push(e)
150
195
  }
@@ -155,7 +200,12 @@ function requireNative() {
155
200
  loadErrors.push(e)
156
201
  }
157
202
  try {
158
- return require('@tauri-apps/cli-darwin-x64')
203
+ const binding = require('@tauri-apps/cli-darwin-x64')
204
+ const bindingPackageVersion = require('@tauri-apps/cli-darwin-x64/package.json').version
205
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
206
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
207
+ }
208
+ return binding
159
209
  } catch (e) {
160
210
  loadErrors.push(e)
161
211
  }
@@ -166,7 +216,12 @@ function requireNative() {
166
216
  loadErrors.push(e)
167
217
  }
168
218
  try {
169
- return require('@tauri-apps/cli-darwin-arm64')
219
+ const binding = require('@tauri-apps/cli-darwin-arm64')
220
+ const bindingPackageVersion = require('@tauri-apps/cli-darwin-arm64/package.json').version
221
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
222
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
223
+ }
224
+ return binding
170
225
  } catch (e) {
171
226
  loadErrors.push(e)
172
227
  }
@@ -181,7 +236,12 @@ function requireNative() {
181
236
  loadErrors.push(e)
182
237
  }
183
238
  try {
184
- return require('@tauri-apps/cli-freebsd-x64')
239
+ const binding = require('@tauri-apps/cli-freebsd-x64')
240
+ const bindingPackageVersion = require('@tauri-apps/cli-freebsd-x64/package.json').version
241
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
242
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
243
+ }
244
+ return binding
185
245
  } catch (e) {
186
246
  loadErrors.push(e)
187
247
  }
@@ -192,7 +252,12 @@ function requireNative() {
192
252
  loadErrors.push(e)
193
253
  }
194
254
  try {
195
- return require('@tauri-apps/cli-freebsd-arm64')
255
+ const binding = require('@tauri-apps/cli-freebsd-arm64')
256
+ const bindingPackageVersion = require('@tauri-apps/cli-freebsd-arm64/package.json').version
257
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
258
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
259
+ }
260
+ return binding
196
261
  } catch (e) {
197
262
  loadErrors.push(e)
198
263
  }
@@ -208,7 +273,12 @@ function requireNative() {
208
273
  loadErrors.push(e)
209
274
  }
210
275
  try {
211
- return require('@tauri-apps/cli-linux-x64-musl')
276
+ const binding = require('@tauri-apps/cli-linux-x64-musl')
277
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-x64-musl/package.json').version
278
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
279
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
280
+ }
281
+ return binding
212
282
  } catch (e) {
213
283
  loadErrors.push(e)
214
284
  }
@@ -219,7 +289,12 @@ function requireNative() {
219
289
  loadErrors.push(e)
220
290
  }
221
291
  try {
222
- return require('@tauri-apps/cli-linux-x64-gnu')
292
+ const binding = require('@tauri-apps/cli-linux-x64-gnu')
293
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-x64-gnu/package.json').version
294
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
295
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
296
+ }
297
+ return binding
223
298
  } catch (e) {
224
299
  loadErrors.push(e)
225
300
  }
@@ -232,7 +307,12 @@ function requireNative() {
232
307
  loadErrors.push(e)
233
308
  }
234
309
  try {
235
- return require('@tauri-apps/cli-linux-arm64-musl')
310
+ const binding = require('@tauri-apps/cli-linux-arm64-musl')
311
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-arm64-musl/package.json').version
312
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
313
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
314
+ }
315
+ return binding
236
316
  } catch (e) {
237
317
  loadErrors.push(e)
238
318
  }
@@ -243,7 +323,12 @@ function requireNative() {
243
323
  loadErrors.push(e)
244
324
  }
245
325
  try {
246
- return require('@tauri-apps/cli-linux-arm64-gnu')
326
+ const binding = require('@tauri-apps/cli-linux-arm64-gnu')
327
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-arm64-gnu/package.json').version
328
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
329
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
330
+ }
331
+ return binding
247
332
  } catch (e) {
248
333
  loadErrors.push(e)
249
334
  }
@@ -256,7 +341,12 @@ function requireNative() {
256
341
  loadErrors.push(e)
257
342
  }
258
343
  try {
259
- return require('@tauri-apps/cli-linux-arm-musleabihf')
344
+ const binding = require('@tauri-apps/cli-linux-arm-musleabihf')
345
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-arm-musleabihf/package.json').version
346
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
347
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
348
+ }
349
+ return binding
260
350
  } catch (e) {
261
351
  loadErrors.push(e)
262
352
  }
@@ -267,7 +357,46 @@ function requireNative() {
267
357
  loadErrors.push(e)
268
358
  }
269
359
  try {
270
- return require('@tauri-apps/cli-linux-arm-gnueabihf')
360
+ const binding = require('@tauri-apps/cli-linux-arm-gnueabihf')
361
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-arm-gnueabihf/package.json').version
362
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
363
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
364
+ }
365
+ return binding
366
+ } catch (e) {
367
+ loadErrors.push(e)
368
+ }
369
+ }
370
+ } else if (process.arch === 'loong64') {
371
+ if (isMusl()) {
372
+ try {
373
+ return require('./cli.linux-loong64-musl.node')
374
+ } catch (e) {
375
+ loadErrors.push(e)
376
+ }
377
+ try {
378
+ const binding = require('@tauri-apps/cli-linux-loong64-musl')
379
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-loong64-musl/package.json').version
380
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
381
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
382
+ }
383
+ return binding
384
+ } catch (e) {
385
+ loadErrors.push(e)
386
+ }
387
+ } else {
388
+ try {
389
+ return require('./cli.linux-loong64-gnu.node')
390
+ } catch (e) {
391
+ loadErrors.push(e)
392
+ }
393
+ try {
394
+ const binding = require('@tauri-apps/cli-linux-loong64-gnu')
395
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-loong64-gnu/package.json').version
396
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
397
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
398
+ }
399
+ return binding
271
400
  } catch (e) {
272
401
  loadErrors.push(e)
273
402
  }
@@ -280,7 +409,12 @@ function requireNative() {
280
409
  loadErrors.push(e)
281
410
  }
282
411
  try {
283
- return require('@tauri-apps/cli-linux-riscv64-musl')
412
+ const binding = require('@tauri-apps/cli-linux-riscv64-musl')
413
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-riscv64-musl/package.json').version
414
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
415
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
416
+ }
417
+ return binding
284
418
  } catch (e) {
285
419
  loadErrors.push(e)
286
420
  }
@@ -291,7 +425,12 @@ function requireNative() {
291
425
  loadErrors.push(e)
292
426
  }
293
427
  try {
294
- return require('@tauri-apps/cli-linux-riscv64-gnu')
428
+ const binding = require('@tauri-apps/cli-linux-riscv64-gnu')
429
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-riscv64-gnu/package.json').version
430
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
431
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
432
+ }
433
+ return binding
295
434
  } catch (e) {
296
435
  loadErrors.push(e)
297
436
  }
@@ -303,7 +442,12 @@ function requireNative() {
303
442
  loadErrors.push(e)
304
443
  }
305
444
  try {
306
- return require('@tauri-apps/cli-linux-ppc64-gnu')
445
+ const binding = require('@tauri-apps/cli-linux-ppc64-gnu')
446
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-ppc64-gnu/package.json').version
447
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
448
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
449
+ }
450
+ return binding
307
451
  } catch (e) {
308
452
  loadErrors.push(e)
309
453
  }
@@ -314,7 +458,12 @@ function requireNative() {
314
458
  loadErrors.push(e)
315
459
  }
316
460
  try {
317
- return require('@tauri-apps/cli-linux-s390x-gnu')
461
+ const binding = require('@tauri-apps/cli-linux-s390x-gnu')
462
+ const bindingPackageVersion = require('@tauri-apps/cli-linux-s390x-gnu/package.json').version
463
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
464
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
465
+ }
466
+ return binding
318
467
  } catch (e) {
319
468
  loadErrors.push(e)
320
469
  }
@@ -324,34 +473,49 @@ function requireNative() {
324
473
  } else if (process.platform === 'openharmony') {
325
474
  if (process.arch === 'arm64') {
326
475
  try {
327
- return require('./cli.linux-arm64-ohos.node')
476
+ return require('./cli.openharmony-arm64.node')
328
477
  } catch (e) {
329
478
  loadErrors.push(e)
330
479
  }
331
480
  try {
332
- return require('@tauri-apps/cli-linux-arm64-ohos')
481
+ const binding = require('@tauri-apps/cli-openharmony-arm64')
482
+ const bindingPackageVersion = require('@tauri-apps/cli-openharmony-arm64/package.json').version
483
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
484
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
485
+ }
486
+ return binding
333
487
  } catch (e) {
334
488
  loadErrors.push(e)
335
489
  }
336
490
  } else if (process.arch === 'x64') {
337
491
  try {
338
- return require('./cli.linux-x64-ohos.node')
492
+ return require('./cli.openharmony-x64.node')
339
493
  } catch (e) {
340
494
  loadErrors.push(e)
341
495
  }
342
496
  try {
343
- return require('@tauri-apps/cli-linux-x64-ohos')
497
+ const binding = require('@tauri-apps/cli-openharmony-x64')
498
+ const bindingPackageVersion = require('@tauri-apps/cli-openharmony-x64/package.json').version
499
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
500
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
501
+ }
502
+ return binding
344
503
  } catch (e) {
345
504
  loadErrors.push(e)
346
505
  }
347
506
  } else if (process.arch === 'arm') {
348
507
  try {
349
- return require('./cli.linux-arm-ohos.node')
508
+ return require('./cli.openharmony-arm.node')
350
509
  } catch (e) {
351
510
  loadErrors.push(e)
352
511
  }
353
512
  try {
354
- return require('@tauri-apps/cli-linux-arm-ohos')
513
+ const binding = require('@tauri-apps/cli-openharmony-arm')
514
+ const bindingPackageVersion = require('@tauri-apps/cli-openharmony-arm/package.json').version
515
+ if (bindingPackageVersion !== '2.10.0' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
516
+ throw new Error(`Native binding package version mismatch, expected 2.10.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`)
517
+ }
518
+ return binding
355
519
  } catch (e) {
356
520
  loadErrors.push(e)
357
521
  }
@@ -366,22 +530,32 @@ function requireNative() {
366
530
  nativeBinding = requireNative()
367
531
 
368
532
  if (!nativeBinding || process.env.NAPI_RS_FORCE_WASI) {
533
+ let wasiBinding = null
534
+ let wasiBindingError = null
369
535
  try {
370
- nativeBinding = require('./cli.wasi.cjs')
536
+ wasiBinding = require('./cli.wasi.cjs')
537
+ nativeBinding = wasiBinding
371
538
  } catch (err) {
372
539
  if (process.env.NAPI_RS_FORCE_WASI) {
373
- loadErrors.push(err)
540
+ wasiBindingError = err
374
541
  }
375
542
  }
376
543
  if (!nativeBinding) {
377
544
  try {
378
- nativeBinding = require('@tauri-apps/cli-wasm32-wasi')
545
+ wasiBinding = require('@tauri-apps/cli-wasm32-wasi')
546
+ nativeBinding = wasiBinding
379
547
  } catch (err) {
380
548
  if (process.env.NAPI_RS_FORCE_WASI) {
549
+ wasiBindingError.cause = err
381
550
  loadErrors.push(err)
382
551
  }
383
552
  }
384
553
  }
554
+ if (process.env.NAPI_RS_FORCE_WASI === 'error' && !wasiBinding) {
555
+ const error = new Error('WASI binding not found and NAPI_RS_FORCE_WASI is set to error')
556
+ error.cause = wasiBindingError
557
+ throw error
558
+ }
385
559
  }
386
560
 
387
561
  if (!nativeBinding) {
@@ -390,7 +564,12 @@ if (!nativeBinding) {
390
564
  `Cannot find native binding. ` +
391
565
  `npm has a bug related to optional dependencies (https://github.com/npm/cli/issues/4828). ` +
392
566
  'Please try `npm i` again after removing both package-lock.json and node_modules directory.',
393
- { cause: loadErrors }
567
+ {
568
+ cause: loadErrors.reduce((err, cur) => {
569
+ cur.cause = err
570
+ return cur
571
+ }),
572
+ },
394
573
  )
395
574
  }
396
575
  throw new Error(`Failed to load native binding`)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tauri-apps/cli",
3
- "version": "2.9.6",
3
+ "version": "2.10.1",
4
4
  "description": "Command line interface for building Tauri apps",
5
5
  "type": "commonjs",
6
6
  "funding": {
@@ -65,16 +65,16 @@
65
65
  "tauri": "node ./tauri.js"
66
66
  },
67
67
  "optionalDependencies": {
68
- "@tauri-apps/cli-linux-x64-gnu": "2.9.6",
69
- "@tauri-apps/cli-win32-x64-msvc": "2.9.6",
70
- "@tauri-apps/cli-darwin-x64": "2.9.6",
71
- "@tauri-apps/cli-darwin-arm64": "2.9.6",
72
- "@tauri-apps/cli-linux-arm64-gnu": "2.9.6",
73
- "@tauri-apps/cli-linux-arm64-musl": "2.9.6",
74
- "@tauri-apps/cli-linux-arm-gnueabihf": "2.9.6",
75
- "@tauri-apps/cli-linux-x64-musl": "2.9.6",
76
- "@tauri-apps/cli-linux-riscv64-gnu": "2.9.6",
77
- "@tauri-apps/cli-win32-ia32-msvc": "2.9.6",
78
- "@tauri-apps/cli-win32-arm64-msvc": "2.9.6"
68
+ "@tauri-apps/cli-linux-x64-gnu": "2.10.1",
69
+ "@tauri-apps/cli-win32-x64-msvc": "2.10.1",
70
+ "@tauri-apps/cli-darwin-x64": "2.10.1",
71
+ "@tauri-apps/cli-darwin-arm64": "2.10.1",
72
+ "@tauri-apps/cli-linux-arm64-gnu": "2.10.1",
73
+ "@tauri-apps/cli-linux-arm64-musl": "2.10.1",
74
+ "@tauri-apps/cli-linux-arm-gnueabihf": "2.10.1",
75
+ "@tauri-apps/cli-linux-x64-musl": "2.10.1",
76
+ "@tauri-apps/cli-linux-riscv64-gnu": "2.10.1",
77
+ "@tauri-apps/cli-win32-ia32-msvc": "2.10.1",
78
+ "@tauri-apps/cli-win32-arm64-msvc": "2.10.1"
79
79
  }
80
80
  }
package/tauri.js CHANGED
@@ -20,7 +20,7 @@ if (globalThis.navigator?.userAgent?.includes('Deno')) {
20
20
  }
21
21
  // Even if started by a package manager, the binary will be NodeJS.
22
22
  // Some distribution still use "nodejs" as the binary name.
23
- else if (binStem.match(/(nodejs|node|bun)\-?([0-9]*)*$/g)) {
23
+ else if (binStem.match(/(nodejs|node|bun|electron)\-?([0-9]*)*$/g)) {
24
24
  const managerStem = process.env.npm_execpath
25
25
  ? path.parse(process.env.npm_execpath).name.toLowerCase()
26
26
  : null