@tauri-apps/cli 2.0.0-alpha.16 → 2.0.0-alpha.18

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,41 @@
1
1
  # Changelog
2
2
 
3
+ ## \[2.0.0-alpha.18]
4
+
5
+ ### New Features
6
+
7
+ - [`50f7ccbb`](https://www.github.com/tauri-apps/tauri/commit/50f7ccbbf3467f33cc7dd1cca53125fec6eda1c6)([#6444](https://www.github.com/tauri-apps/tauri/pull/6444)) Add suport to SVG input image for the `tauri icon` command.
8
+ - [`25e5f91d`](https://www.github.com/tauri-apps/tauri/commit/25e5f91dae7fe2bbc1ba4317d5d829402bfd1d50)([#8200](https://www.github.com/tauri-apps/tauri/pull/8200)) Merge `src-tauri/Info.plist` and `src-tauri/Info.ios.plist` with the iOS project plist file.
9
+
10
+ ### Enhancements
11
+
12
+ - [`01a7a983`](https://www.github.com/tauri-apps/tauri/commit/01a7a983aba2946b455a608b8a6a4b08cb25fc11)([#8128](https://www.github.com/tauri-apps/tauri/pull/8128)) Transform paths to relative to the mobile project for the IDE script runner script.
13
+
14
+ ### Bug Fixes
15
+
16
+ - [`88dac86f`](https://www.github.com/tauri-apps/tauri/commit/88dac86f3b301d1919df6473a9e20f46b560f29b)([#8149](https://www.github.com/tauri-apps/tauri/pull/8149)) Ensure `tauri add` prints `rust_code` with plugin name in snake case.
17
+ - [`977d0e52`](https://www.github.com/tauri-apps/tauri/commit/977d0e52f14b1ad01c86371765ef25b36572459e)([#8202](https://www.github.com/tauri-apps/tauri/pull/8202)) Fixes `android build --open` and `ios build --open` IDE failing to read CLI options.
18
+ - [`bfbbefdb`](https://www.github.com/tauri-apps/tauri/commit/bfbbefdb9e13ed1f42f6db7fa9ceaa84db1267e9)([#8161](https://www.github.com/tauri-apps/tauri/pull/8161)) Fix invalid plugin template.
19
+ - [`92b50a3a`](https://www.github.com/tauri-apps/tauri/commit/92b50a3a398c9d55b6992a8f5c2571e4d72bdaaf)([#8209](https://www.github.com/tauri-apps/tauri/pull/8209)) Added support to Xcode's archive. This requires regenerating the Xcode project.
20
+
21
+ ### Dependencies
22
+
23
+ - Upgraded to `tauri-cli@2.0.0-alpha.18`
24
+
25
+ ## \[2.0.0-alpha.17]
26
+
27
+ ### Enhancements
28
+
29
+ - [`c6c59cf2`](https://www.github.com/tauri-apps/tauri/commit/c6c59cf2373258b626b00a26f4de4331765dd487) Pull changes from Tauri 1.5 release.
30
+
31
+ ### Dependencies
32
+
33
+ - Upgraded to `tauri-cli@2.0.0-alpha.17`
34
+
35
+ ### Breaking Changes
36
+
37
+ - [`198abe3c`](https://www.github.com/tauri-apps/tauri/commit/198abe3c2cae06dacab860b3a93f715dcf529a95)([#8076](https://www.github.com/tauri-apps/tauri/pull/8076)) Updated the mobile plugin templates following the tauri v2.0.0-alpha.17 changes.
38
+
3
39
  ## \[2.0.0-alpha.16]
4
40
 
5
41
  ### New Features
@@ -240,6 +276,66 @@
240
276
  - First mobile alpha release!
241
277
  - [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
242
278
 
279
+ ## \[1.5.5]
280
+
281
+ ### Enhancements
282
+
283
+ - [`9bead42d`](https://www.github.com/tauri-apps/tauri/commit/9bead42dbca0fb6dd7ea0b6bfb2f2308a5c5f992)([#8059](https://www.github.com/tauri-apps/tauri/pull/8059)) Allow rotating the updater private key.
284
+
285
+ ### Bug Fixes
286
+
287
+ - [`be8e5aa3`](https://www.github.com/tauri-apps/tauri/commit/be8e5aa3071d9bc5d0bd24647e8168f312d11c8d)([#8042](https://www.github.com/tauri-apps/tauri/pull/8042)) Fixes duplicated newlines on command outputs.
288
+
289
+ ### Dependencies
290
+
291
+ - Upgraded to `tauri-cli@1.5.5`
292
+
293
+ ## \[1.5.4]
294
+
295
+ ### Dependencies
296
+
297
+ - Upgraded to `tauri-cli@1.5.4`
298
+
299
+ ## \[1.5.3]
300
+
301
+ ### Dependencies
302
+
303
+ - Upgraded to `tauri-cli@1.5.3`
304
+
305
+ ## \[1.5.2]
306
+
307
+ ### Dependencies
308
+
309
+ - Upgraded to `tauri-cli@1.5.2`
310
+
311
+ ## \[1.5.1]
312
+
313
+ ### Bug Fixes
314
+
315
+ - [`d6eb46cf`](https://www.github.com/tauri-apps/tauri/commit/d6eb46cf1116d147121f6b6db9d390b5e2fb238d)([#7934](https://www.github.com/tauri-apps/tauri/pull/7934)) On macOS, fix the `apple-id` option name when using `notarytools submit`.
316
+
317
+ ### Dependencies
318
+
319
+ - Upgraded to `tauri-cli@1.5.1`
320
+
321
+ ## \[1.5.0]
322
+
323
+ ### New Features
324
+
325
+ - [`e1526626`](https://www.github.com/tauri-apps/tauri/commit/e152662687ece7a62d383923a50751cc0dd34331)([#7723](https://www.github.com/tauri-apps/tauri/pull/7723)) Support Bun package manager in CLI
326
+
327
+ ### Enhancements
328
+
329
+ - [`13279917`](https://www.github.com/tauri-apps/tauri/commit/13279917d4cae071d0ce3a686184d48af079f58a)([#7713](https://www.github.com/tauri-apps/tauri/pull/7713)) Add version of Rust Tauri CLI installed with Cargo to `tauri info` command.
330
+
331
+ ### Bug Fixes
332
+
333
+ - [`dad4f54e`](https://www.github.com/tauri-apps/tauri/commit/dad4f54eec9773d2ea6233a7d9fd218741173823)([#7277](https://www.github.com/tauri-apps/tauri/pull/7277)) Removed the automatic version check of the CLI that ran after `tauri` commands which caused various issues.
334
+
335
+ ### Dependencies
336
+
337
+ - Upgraded to `tauri-cli@1.5.0`
338
+
243
339
  ## \[1.4.0]
244
340
 
245
341
  ### New Features
package/README.md CHANGED
@@ -19,7 +19,7 @@ Tauri is a polyglot and generic system that is very composable and allows engine
19
19
 
20
20
  Tauri apps can have custom menus and have tray-type interfaces. They can be updated, and are managed by the user's operating system as expected. They are very small, because they use the system's webview. They do not ship a runtime, since the final binary is compiled from rust. This makes the reversing of Tauri apps not a trivial task.
21
21
  ## This module
22
- Written in Typescript and packaged such that it can be used with `npm`, `pnpm`, and `yarn`, this library provides a node.js runner for common tasks when using Tauri, like `yarn tauri dev`. For the most part it is a wrapper around [tauri-cli](https://github.com/tauri-apps/tauri/blob/dev/tooling/cli).
22
+ Written in Typescript and packaged such that it can be used with `npm`, `pnpm`, `yarn`, and `bun`, this library provides a node.js runner for common tasks when using Tauri, like `yarn tauri dev`. For the most part it is a wrapper around [tauri-cli](https://github.com/tauri-apps/tauri/blob/dev/tooling/cli).
23
23
 
24
24
  To learn more about the details of how all of these pieces fit together, please consult this [ARCHITECTURE.md](https://github.com/tauri-apps/tauri/blob/dev/ARCHITECTURE.md) document.
25
25
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tauri-apps/cli",
3
- "version": "2.0.0-alpha.16",
3
+ "version": "2.0.0-alpha.18",
4
4
  "description": "Command line interface for building Tauri apps",
5
5
  "funding": {
6
6
  "type": "opencollective",
@@ -42,13 +42,12 @@
42
42
  "cross-env": "7.0.3",
43
43
  "cross-spawn": "7.0.3",
44
44
  "fs-extra": "11.1.1",
45
- "jest": "29.5.0",
45
+ "jest": "29.7.0",
46
46
  "jest-transform-toml": "1.0.0",
47
47
  "prettier": "2.8.8"
48
48
  },
49
49
  "resolutions": {
50
- "json5": "2.2.3",
51
- "semver": ">=7.5.2"
50
+ "json5": "2.2.3"
52
51
  },
53
52
  "engines": {
54
53
  "node": ">= 10"
@@ -68,17 +67,16 @@
68
67
  "format": "prettier --write ./package.json ./tauri.js",
69
68
  "format:check": "prettier --check ./package.json ./tauri.js"
70
69
  },
71
- "dependencies": {},
72
70
  "optionalDependencies": {
73
- "@tauri-apps/cli-win32-x64-msvc": "2.0.0-alpha.16",
74
- "@tauri-apps/cli-darwin-x64": "2.0.0-alpha.16",
75
- "@tauri-apps/cli-linux-x64-gnu": "2.0.0-alpha.16",
76
- "@tauri-apps/cli-darwin-arm64": "2.0.0-alpha.16",
77
- "@tauri-apps/cli-linux-arm64-gnu": "2.0.0-alpha.16",
78
- "@tauri-apps/cli-linux-arm64-musl": "2.0.0-alpha.16",
79
- "@tauri-apps/cli-linux-arm-gnueabihf": "2.0.0-alpha.16",
80
- "@tauri-apps/cli-linux-x64-musl": "2.0.0-alpha.16",
81
- "@tauri-apps/cli-win32-ia32-msvc": "2.0.0-alpha.16",
82
- "@tauri-apps/cli-win32-arm64-msvc": "2.0.0-alpha.16"
71
+ "@tauri-apps/cli-win32-x64-msvc": "2.0.0-alpha.18",
72
+ "@tauri-apps/cli-darwin-x64": "2.0.0-alpha.18",
73
+ "@tauri-apps/cli-linux-x64-gnu": "2.0.0-alpha.18",
74
+ "@tauri-apps/cli-darwin-arm64": "2.0.0-alpha.18",
75
+ "@tauri-apps/cli-linux-arm64-gnu": "2.0.0-alpha.18",
76
+ "@tauri-apps/cli-linux-arm64-musl": "2.0.0-alpha.18",
77
+ "@tauri-apps/cli-linux-arm-gnueabihf": "2.0.0-alpha.18",
78
+ "@tauri-apps/cli-linux-x64-musl": "2.0.0-alpha.18",
79
+ "@tauri-apps/cli-win32-ia32-msvc": "2.0.0-alpha.18",
80
+ "@tauri-apps/cli-win32-arm64-msvc": "2.0.0-alpha.18"
83
81
  }
84
82
  }
package/schema.json CHANGED
@@ -37,6 +37,20 @@
37
37
  "deb": {
38
38
  "files": {}
39
39
  },
40
+ "dmg": {
41
+ "appPosition": {
42
+ "x": 180,
43
+ "y": 170
44
+ },
45
+ "applicationFolderPosition": {
46
+ "x": 480,
47
+ "y": 170
48
+ },
49
+ "windowSize": {
50
+ "height": 400,
51
+ "width": 660
52
+ }
53
+ },
40
54
  "iOS": {},
41
55
  "icon": [],
42
56
  "identifier": "",
@@ -171,6 +185,20 @@
171
185
  "deb": {
172
186
  "files": {}
173
187
  },
188
+ "dmg": {
189
+ "appPosition": {
190
+ "x": 180,
191
+ "y": 170
192
+ },
193
+ "applicationFolderPosition": {
194
+ "x": 480,
195
+ "y": 170
196
+ },
197
+ "windowSize": {
198
+ "height": 400,
199
+ "width": 660
200
+ }
201
+ },
174
202
  "iOS": {},
175
203
  "icon": [],
176
204
  "identifier": "",
@@ -934,13 +962,14 @@
934
962
  },
935
963
  "resources": {
936
964
  "description": "App resources to bundle. Each resource is a path to a file or directory. Glob patterns are supported.",
937
- "type": [
938
- "array",
939
- "null"
940
- ],
941
- "items": {
942
- "type": "string"
943
- }
965
+ "anyOf": [
966
+ {
967
+ "$ref": "#/definitions/BundleResources"
968
+ },
969
+ {
970
+ "type": "null"
971
+ }
972
+ ]
944
973
  },
945
974
  "copyright": {
946
975
  "description": "A copyright string associated with your application.",
@@ -1002,6 +1031,28 @@
1002
1031
  }
1003
1032
  ]
1004
1033
  },
1034
+ "dmg": {
1035
+ "description": "DMG-specific settings.",
1036
+ "default": {
1037
+ "appPosition": {
1038
+ "x": 180,
1039
+ "y": 170
1040
+ },
1041
+ "applicationFolderPosition": {
1042
+ "x": 480,
1043
+ "y": 170
1044
+ },
1045
+ "windowSize": {
1046
+ "height": 400,
1047
+ "width": 660
1048
+ }
1049
+ },
1050
+ "allOf": [
1051
+ {
1052
+ "$ref": "#/definitions/DmgConfig"
1053
+ }
1054
+ ]
1055
+ },
1005
1056
  "macOS": {
1006
1057
  "description": "Configuration for the macOS bundles.",
1007
1058
  "default": {
@@ -1163,6 +1214,25 @@
1163
1214
  }
1164
1215
  ]
1165
1216
  },
1217
+ "BundleResources": {
1218
+ "description": "Definition for bundle resources. Can be either a list of paths to include or a map of source to target paths.",
1219
+ "anyOf": [
1220
+ {
1221
+ "description": "A list of paths to include.",
1222
+ "type": "array",
1223
+ "items": {
1224
+ "type": "string"
1225
+ }
1226
+ },
1227
+ {
1228
+ "description": "A map of source to target paths.",
1229
+ "type": "object",
1230
+ "additionalProperties": {
1231
+ "type": "string"
1232
+ }
1233
+ }
1234
+ ]
1235
+ },
1166
1236
  "FileAssociation": {
1167
1237
  "description": "File association",
1168
1238
  "type": "object",
@@ -1178,7 +1248,7 @@
1178
1248
  }
1179
1249
  },
1180
1250
  "name": {
1181
- "description": "The name. Maps to `CFBundleTypeName` on macOS. Default to ext[0]",
1251
+ "description": "The name. Maps to `CFBundleTypeName` on macOS. Default to `ext[0]`",
1182
1252
  "type": [
1183
1253
  "string",
1184
1254
  "null"
@@ -1298,6 +1368,113 @@
1298
1368
  },
1299
1369
  "additionalProperties": false
1300
1370
  },
1371
+ "DmgConfig": {
1372
+ "description": "Configuration for Apple Disk Image (.dmg) bundles.\n\nSee more: https://tauri.app/v1/api/config#dmgconfig",
1373
+ "type": "object",
1374
+ "properties": {
1375
+ "background": {
1376
+ "description": "Image to use as the background in dmg file. Accepted formats: `png`/`jpg`/`gif`.",
1377
+ "type": [
1378
+ "string",
1379
+ "null"
1380
+ ]
1381
+ },
1382
+ "windowPosition": {
1383
+ "description": "Position of volume window on screen.",
1384
+ "anyOf": [
1385
+ {
1386
+ "$ref": "#/definitions/Position"
1387
+ },
1388
+ {
1389
+ "type": "null"
1390
+ }
1391
+ ]
1392
+ },
1393
+ "windowSize": {
1394
+ "description": "Size of volume window.",
1395
+ "default": {
1396
+ "height": 400,
1397
+ "width": 660
1398
+ },
1399
+ "allOf": [
1400
+ {
1401
+ "$ref": "#/definitions/Size"
1402
+ }
1403
+ ]
1404
+ },
1405
+ "appPosition": {
1406
+ "description": "Position of app file on window.",
1407
+ "default": {
1408
+ "x": 180,
1409
+ "y": 170
1410
+ },
1411
+ "allOf": [
1412
+ {
1413
+ "$ref": "#/definitions/Position"
1414
+ }
1415
+ ]
1416
+ },
1417
+ "applicationFolderPosition": {
1418
+ "description": "Position of application folder on window.",
1419
+ "default": {
1420
+ "x": 480,
1421
+ "y": 170
1422
+ },
1423
+ "allOf": [
1424
+ {
1425
+ "$ref": "#/definitions/Position"
1426
+ }
1427
+ ]
1428
+ }
1429
+ },
1430
+ "additionalProperties": false
1431
+ },
1432
+ "Position": {
1433
+ "description": "Position coordinates struct.",
1434
+ "type": "object",
1435
+ "required": [
1436
+ "x",
1437
+ "y"
1438
+ ],
1439
+ "properties": {
1440
+ "x": {
1441
+ "description": "X coordinate.",
1442
+ "type": "integer",
1443
+ "format": "uint32",
1444
+ "minimum": 0.0
1445
+ },
1446
+ "y": {
1447
+ "description": "Y coordinate.",
1448
+ "type": "integer",
1449
+ "format": "uint32",
1450
+ "minimum": 0.0
1451
+ }
1452
+ },
1453
+ "additionalProperties": false
1454
+ },
1455
+ "Size": {
1456
+ "description": "Size of the window.",
1457
+ "type": "object",
1458
+ "required": [
1459
+ "height",
1460
+ "width"
1461
+ ],
1462
+ "properties": {
1463
+ "width": {
1464
+ "description": "Width of the window.",
1465
+ "type": "integer",
1466
+ "format": "uint32",
1467
+ "minimum": 0.0
1468
+ },
1469
+ "height": {
1470
+ "description": "Height of the window.",
1471
+ "type": "integer",
1472
+ "format": "uint32",
1473
+ "minimum": 0.0
1474
+ }
1475
+ },
1476
+ "additionalProperties": false
1477
+ },
1301
1478
  "MacConfig": {
1302
1479
  "description": "Configuration for the macOS bundles.\n\nSee more: <https://tauri.app/v1/api/config#macconfig>",
1303
1480
  "type": "object",
@@ -1753,6 +1930,17 @@
1753
1930
  "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.",
1754
1931
  "default": false,
1755
1932
  "type": "boolean"
1933
+ },
1934
+ "compression": {
1935
+ "description": "Set the compression algorithm used to compress files in the installer.\n\nSee <https://nsis.sourceforge.io/Reference/SetCompressor>",
1936
+ "anyOf": [
1937
+ {
1938
+ "$ref": "#/definitions/NsisCompression"
1939
+ },
1940
+ {
1941
+ "type": "null"
1942
+ }
1943
+ ]
1756
1944
  }
1757
1945
  },
1758
1946
  "additionalProperties": false
@@ -1783,6 +1971,32 @@
1783
1971
  }
1784
1972
  ]
1785
1973
  },
1974
+ "NsisCompression": {
1975
+ "description": "Compression algorithms used in the NSIS installer.\n\nSee <https://nsis.sourceforge.io/Reference/SetCompressor>",
1976
+ "oneOf": [
1977
+ {
1978
+ "description": "ZLIB uses the deflate algorithm, it is a quick and simple method. With the default compression level it uses about 300 KB of memory.",
1979
+ "type": "string",
1980
+ "enum": [
1981
+ "zlib"
1982
+ ]
1983
+ },
1984
+ {
1985
+ "description": "BZIP2 usually gives better compression ratios than ZLIB, but it is a bit slower and uses more memory. With the default compression level it uses about 4 MB of memory.",
1986
+ "type": "string",
1987
+ "enum": [
1988
+ "bzip2"
1989
+ ]
1990
+ },
1991
+ {
1992
+ "description": "LZMA (default) is a new compression method that gives very good compression ratios. The decompression speed is high (10-20 MB/s on a 2 GHz CPU), the compression speed is lower. The memory size that will be used for decompression is the dictionary size plus a few KBs, the default is 8 MB.",
1993
+ "type": "string",
1994
+ "enum": [
1995
+ "lzma"
1996
+ ]
1997
+ }
1998
+ ]
1999
+ },
1786
2000
  "IosConfig": {
1787
2001
  "description": "General configuration for the iOS target.",
1788
2002
  "type": "object",
@@ -2019,7 +2233,7 @@
2019
2233
  }
2020
2234
  },
2021
2235
  "plugins": {
2022
- "description": "The list of plugins that are allowed in this scope.",
2236
+ "description": "The list of plugins that are allowed in this scope. The names should be without the `tauri-plugin-` prefix, for example `\"store\"` for `tauri-plugin-store`.",
2023
2237
  "default": [],
2024
2238
  "type": "array",
2025
2239
  "items": {
package/tauri.js CHANGED
@@ -7,7 +7,7 @@
7
7
  const cli = require('./main')
8
8
  const path = require('path')
9
9
 
10
- const [bin, script, ...arguments] = process.argv
10
+ const [bin, script, ...args] = process.argv
11
11
  const binStem = path.parse(bin).name.toLowerCase()
12
12
 
13
13
  // We want to make a helpful binary name for the underlying CLI helper, if we
@@ -20,7 +20,7 @@ if (bin === '@tauri-apps/cli') {
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)\-?([0-9]*)*$/g)) {
23
+ else if (binStem.match(/(nodejs|node|bun)\-?([0-9]*)*$/g)) {
24
24
  const managerStem = process.env.npm_execpath
25
25
  ? path.parse(process.env.npm_execpath).name.toLowerCase()
26
26
  : null
@@ -32,7 +32,7 @@ else if (binStem.match(/(nodejs|node)\-?([0-9]*)*$/g)) {
32
32
  manager = 'npm'
33
33
  break
34
34
 
35
- // Yarn and pnpm have the same stem name as their bin.
35
+ // Yarn, pnpm, and bun have the same stem name as their bin.
36
36
  // We assume all unknown package managers do as well.
37
37
  default:
38
38
  manager = managerStem
@@ -48,10 +48,10 @@ else if (binStem.match(/(nodejs|node)\-?([0-9]*)*$/g)) {
48
48
  }
49
49
  } else {
50
50
  // We don't know what started it, assume it's already stripped.
51
- arguments.unshift(bin)
51
+ args.unshift(bin)
52
52
  }
53
53
 
54
- cli.run(arguments, binName).catch((err) => {
54
+ cli.run(args, binName).catch((err) => {
55
55
  cli.logError(err.message)
56
56
  process.exit(1)
57
57
  })