@vantail/cli 0.1.0 → 0.1.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/README.md ADDED
@@ -0,0 +1,77 @@
1
+ # @vantail/cli
2
+
3
+ The command line for [Vantail](https://github.com/Vantail/vantail): run an
4
+ application in a native window, and turn it into something people can install.
5
+
6
+ ```bash
7
+ npm create @vantail my-app
8
+ ```
9
+
10
+ The scaffolder installs this for you. Otherwise:
11
+
12
+ ```bash
13
+ npm install --save-dev @vantail/cli
14
+ ```
15
+
16
+ ## Commands
17
+
18
+ ```bash
19
+ vantail dev # native window against the Vite dev server, with HMR
20
+ vantail build # build the web assets
21
+ vantail package # lay out a distributable application
22
+ vantail doctor # check that everything needed to run is present
23
+ vantail updater # keygen | sign | manifest
24
+ ```
25
+
26
+ `vantail dev` starts Vite, points a real webview at it, and ties their
27
+ lifetimes together: close the window and the server stops, stop the CLI and
28
+ the window closes. Editing the config reopens the window, since window size
29
+ and permissions are read once at startup.
30
+
31
+ `vantail package` produces a `.app` on macOS and a portable folder elsewhere.
32
+ It copies a precompiled runtime binary; there is no compilation step and no
33
+ Rust toolchain involved. Add `--installer` for the thing a user downloads: a
34
+ `.dmg` on macOS, an `.msi` on Windows, a `.deb` on Linux.
35
+
36
+ `vantail doctor` prints which runtime it found and why, which is the first
37
+ thing to run when something will not start.
38
+
39
+ ## Configuration
40
+
41
+ `defineConfig` is exported from here, so the config file is typed:
42
+
43
+ ```ts
44
+ // vantail.config.ts
45
+ import { defineConfig } from "@vantail/cli";
46
+
47
+ export default defineConfig({
48
+ app: {
49
+ name: "My App",
50
+ identifier: "dev.example.myapp",
51
+ version: "1.0.0",
52
+ // One square PNG. Every size each platform asks for is scaled from it.
53
+ icon: "icon.png",
54
+ },
55
+
56
+ window: { width: 1200, height: 800 },
57
+
58
+ permissions: {
59
+ dialog: true,
60
+ filesystem: {
61
+ read: ["$DOCUMENT/**"],
62
+ write: ["$APPDATA/**"],
63
+ },
64
+ },
65
+ });
66
+ ```
67
+
68
+ Nothing native is available until the config asks for it. `$DOCUMENT`,
69
+ `$APPDATA` and the rest resolve to the right directory per platform.
70
+
71
+ ## Documentation
72
+
73
+ - [Configuration and permissions](https://github.com/Vantail/vantail/blob/main/docs/permissions.md)
74
+ - [Bundles, installers and signing](https://github.com/Vantail/vantail/blob/main/docs/packaging.md)
75
+ - [Shipping updates](https://github.com/Vantail/vantail/blob/main/docs/updater.md)
76
+
77
+ MIT licensed.
package/dist/bin.js CHANGED
File without changes
package/dist/index.d.ts CHANGED
@@ -13,7 +13,7 @@ export { packageApp, type PackageOptions } from "./commands/package.js";
13
13
  export { bundle, type BundleInput, type BundleResult } from "./bundle/index.js";
14
14
  export { buildRuntimeConfig, type RuntimeConfigInput } from "./runtime-config.js";
15
15
  /** Kept in step with package.json by the release script. */
16
- export declare const VERSION = "0.1.0";
16
+ export declare const VERSION = "0.1.1";
17
17
  /** `ConfigError` is thrown from a package the CLI does not re-export. */
18
18
  export declare const ConfigErrorName = "ConfigError";
19
19
  //# sourceMappingURL=index.d.ts.map
package/dist/index.js CHANGED
@@ -12,7 +12,7 @@ export { packageApp } from "./commands/package.js";
12
12
  export { bundle } from "./bundle/index.js";
13
13
  export { buildRuntimeConfig } from "./runtime-config.js";
14
14
  /** Kept in step with package.json by the release script. */
15
- export const VERSION = "0.1.0";
15
+ export const VERSION = "0.1.1";
16
16
  /** `ConfigError` is thrown from a package the CLI does not re-export. */
17
17
  export const ConfigErrorName = "ConfigError";
18
18
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vantail/cli",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "The Vantail command line: dev, build, package.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -27,9 +27,9 @@
27
27
  "typecheck": "tsc -p tsconfig.json --noEmit"
28
28
  },
29
29
  "dependencies": {
30
- "@vantail/runtime": "^0.1.0",
31
- "@vantail/shared": "^0.1.0",
32
- "@vantail/vite": "^0.1.0"
30
+ "@vantail/runtime": "^0.1.1",
31
+ "@vantail/shared": "^0.1.1",
32
+ "@vantail/vite": "^0.1.1"
33
33
  },
34
34
  "peerDependencies": {
35
35
  "vite": "^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0"