@miakapp/cli 4.0.0-alpha.0 → 4.0.0-alpha.10

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.
Files changed (63) hide show
  1. package/README.md +151 -35
  2. package/assets/agent-guide.md +232 -79
  3. package/assets/design/OFL-Manrope.txt +93 -0
  4. package/assets/design/components.css +139 -0
  5. package/assets/design/fonts.css +9 -0
  6. package/assets/design/gallery.html +667 -0
  7. package/assets/design/guide.md +77 -0
  8. package/assets/design/tokens.css +185 -0
  9. package/assets/starter/app/app/README.md +74 -0
  10. package/assets/starter/app/app/main.ts +124 -0
  11. package/assets/starter/app/app/miakapp.ts +156 -0
  12. package/assets/starter/app/app/theme.ts +8 -0
  13. package/assets/starter/app/tsconfig.json +23 -0
  14. package/bin/miakapp.js +5 -1
  15. package/dist/agent-pack.d.ts +11 -3
  16. package/dist/agent-pack.d.ts.map +1 -1
  17. package/dist/agent-pack.js +26 -10
  18. package/dist/agent-pack.js.map +1 -1
  19. package/dist/contexts.d.ts +59 -0
  20. package/dist/contexts.d.ts.map +1 -0
  21. package/dist/contexts.js +388 -0
  22. package/dist/contexts.js.map +1 -0
  23. package/dist/control-plane.d.ts +14 -0
  24. package/dist/control-plane.d.ts.map +1 -1
  25. package/dist/control-plane.js +33 -1
  26. package/dist/control-plane.js.map +1 -1
  27. package/dist/internal/names.d.ts +5 -0
  28. package/dist/internal/names.d.ts.map +1 -1
  29. package/dist/internal/names.js +6 -0
  30. package/dist/internal/names.js.map +1 -1
  31. package/dist/main.d.ts +22 -5
  32. package/dist/main.d.ts.map +1 -1
  33. package/dist/main.js +673 -60
  34. package/dist/main.js.map +1 -1
  35. package/dist/mcp.d.ts +7 -1
  36. package/dist/mcp.d.ts.map +1 -1
  37. package/dist/mcp.js +195 -26
  38. package/dist/mcp.js.map +1 -1
  39. package/dist/pairing.d.ts +27 -0
  40. package/dist/pairing.d.ts.map +1 -0
  41. package/dist/pairing.js +148 -0
  42. package/dist/pairing.js.map +1 -0
  43. package/dist/project.d.ts +3 -1
  44. package/dist/project.d.ts.map +1 -1
  45. package/dist/project.js +33 -6
  46. package/dist/project.js.map +1 -1
  47. package/dist/publication.d.ts +20 -5
  48. package/dist/publication.d.ts.map +1 -1
  49. package/dist/publication.js +58 -16
  50. package/dist/publication.js.map +1 -1
  51. package/dist/starter.d.ts +17 -0
  52. package/dist/starter.d.ts.map +1 -0
  53. package/dist/starter.js +72 -0
  54. package/dist/starter.js.map +1 -0
  55. package/dist/terminal.d.ts +10 -0
  56. package/dist/terminal.d.ts.map +1 -0
  57. package/dist/terminal.js +70 -0
  58. package/dist/terminal.js.map +1 -0
  59. package/dist/version.d.ts +15 -0
  60. package/dist/version.d.ts.map +1 -0
  61. package/dist/version.js +15 -0
  62. package/dist/version.js.map +1 -0
  63. package/package.json +6 -4
@@ -0,0 +1,17 @@
1
+ export declare const STARTERS: readonly ['app'];
2
+ export type Starter = (typeof STARTERS)[number];
3
+ /** Copied verbatim from `assets/starter/app/`, in this order. */
4
+ export declare const STARTER_ASSETS: readonly ['tsconfig.json', 'app/main.ts', 'app/miakapp.ts', 'app/theme.ts', 'app/README.md'];
5
+ /** Every file the starter writes besides the manifest, relative to the project root. */
6
+ export declare const STARTER_FILES: readonly ["package.json", "tsconfig.json", "app/main.ts", "app/miakapp.ts", "app/theme.ts", "app/README.md"];
7
+ /** The TypeScript the starter's typecheck script pins; the version this repository builds with. */
8
+ export declare const STARTER_TYPESCRIPT = "7.0.2";
9
+ export declare function isStarter(value: string): value is Starter;
10
+ export declare function starterAssetPath(relative: string): string;
11
+ export declare function validateStarterArtifact(artifact: string): void;
12
+ /** The starter's files, as bytes, keyed by their path relative to the project root. */
13
+ export declare function starterFiles(options: {
14
+ readonly home: string;
15
+ readonly artifact: string;
16
+ }): Promise<ReadonlyArray<readonly [path: string, bytes: Uint8Array]>>;
17
+ //# sourceMappingURL=starter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"starter.d.ts","sourceRoot":"","sources":["../src/starter.ts"],"names":[],"mappings":"AAkBA,eAAO,MAAM,QAAQ,YAAI,KAAK,CAAU,CAAC;AACzC,MAAM,MAAM,OAAO,GAAG,CAAC,OAAO,QAAQ,CAAC,CAAC,MAAM,CAAC,CAAC;AAEhD,iEAAiE;AACjE,eAAO,MAAM,cAAc,YAAI,eAAe,EAAE,aAAa,EAAE,gBAAgB,EAAE,cAAc,EAAE,eAAe,CAAU,CAAC;AAE3H,wFAAwF;AACxF,eAAO,MAAM,aAAa,8GAA+C,CAAC;AAE1E,mGAAmG;AACnG,eAAO,MAAM,kBAAkB,UAAU,CAAC;AAQ1C,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,KAAK,IAAI,OAAO,CAEzD;AAED,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAEzD;AAED,wBAAgB,uBAAuB,CAAC,QAAQ,EAAE,MAAM,GAAG,IAAI,CAU9D;AAqBD,uFAAuF;AACvF,wBAAsB,YAAY,CAAC,OAAO,EAAE;IAC1C,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;CAC3B,GAAG,OAAO,CAAC,aAAa,CAAC,SAAS,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,UAAU,CAAC,CAAC,CAAC,CAQrE"}
@@ -0,0 +1,72 @@
1
+ /**
2
+ * The app starter `miakapp init --starter app` writes beside `miakapp.yaml`.
3
+ *
4
+ * It exists so that a new agent with nothing but the published CLI can reach a
5
+ * buildable, checkable whole-house application: no source repository, no
6
+ * unpublished package. Everything is copied out of this package's `assets/`,
7
+ * except `package.json`, whose build script must name the artifact the
8
+ * manifest declares.
9
+ *
10
+ * `app/miakapp.ts` is the `@miakapp/app` SDK source, byte for byte: the bridge
11
+ * a starter ships is the canonical one, never a second hand-written protocol.
12
+ * A test fails when the two drift.
13
+ */
14
+ import { readFile } from 'node:fs/promises';
15
+ import { fileURLToPath } from 'node:url';
16
+ import { usageError } from './errors.js';
17
+ import { CLI_VERSION, PACKAGE_NAME } from './version.js';
18
+ export const STARTERS = ['app'];
19
+ /** Copied verbatim from `assets/starter/app/`, in this order. */
20
+ export const STARTER_ASSETS = ['tsconfig.json', 'app/main.ts', 'app/miakapp.ts', 'app/theme.ts', 'app/README.md'];
21
+ /** Every file the starter writes besides the manifest, relative to the project root. */
22
+ export const STARTER_FILES = ['package.json', ...STARTER_ASSETS];
23
+ /** The TypeScript the starter's typecheck script pins; the version this repository builds with. */
24
+ export const STARTER_TYPESCRIPT = '7.0.2';
25
+ /**
26
+ * A path the build script can name without shell quoting. The manifest parser
27
+ * already keeps it inside the project; this keeps it out of the shell's way.
28
+ */
29
+ const SCRIPT_SAFE_ARTIFACT = /^(?!.*(?:^|\/)\.\.?(?:\/|$))[A-Za-z0-9_-][A-Za-z0-9._-]*(?:\/[A-Za-z0-9_-][A-Za-z0-9._-]*)*\.js$/;
30
+ export function isStarter(value) {
31
+ return STARTERS.includes(value);
32
+ }
33
+ export function starterAssetPath(relative) {
34
+ return fileURLToPath(new URL(`../assets/starter/app/${relative}`, import.meta.url));
35
+ }
36
+ export function validateStarterArtifact(artifact) {
37
+ if (!SCRIPT_SAFE_ARTIFACT.test(artifact)
38
+ || STARTER_FILES.includes(artifact)
39
+ || artifact === 'miakapp.yaml') {
40
+ throw usageError(`--artifact ${JSON.stringify(artifact)} cannot be used with --starter app`, 'Use a relative .js path of letters, digits, ".", "_", "-" and "/" that is not a starter '
41
+ + 'file, such as dist/app.js.');
42
+ }
43
+ }
44
+ function packageJson(home, artifact) {
45
+ return `${JSON.stringify({
46
+ name: `miakapp-home-${home}`,
47
+ version: '0.1.0',
48
+ private: true,
49
+ type: 'module',
50
+ engines: { bun: '>=1.2.23', node: '>=22.9' },
51
+ scripts: {
52
+ build: `bun build app/main.ts --format=iife --minify --outfile ${artifact}`,
53
+ typecheck: 'tsc --noEmit',
54
+ check: 'bun run build && node ./node_modules/@miakapp/cli/bin/miakapp.js check',
55
+ },
56
+ devDependencies: {
57
+ [PACKAGE_NAME]: CLI_VERSION,
58
+ typescript: STARTER_TYPESCRIPT,
59
+ },
60
+ }, null, 2)}\n`;
61
+ }
62
+ /** The starter's files, as bytes, keyed by their path relative to the project root. */
63
+ export async function starterFiles(options) {
64
+ const files = [
65
+ ['package.json', new TextEncoder().encode(packageJson(options.home, options.artifact))],
66
+ ];
67
+ for (const relative of STARTER_ASSETS) {
68
+ files.push([relative, new Uint8Array(await readFile(starterAssetPath(relative)))]);
69
+ }
70
+ return files;
71
+ }
72
+ //# sourceMappingURL=starter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"starter.js","sourceRoot":"","sources":["../src/starter.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAEzD,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,KAAK,CAAU,CAAC;AAGzC,iEAAiE;AACjE,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,eAAe,EAAE,aAAa,EAAE,gBAAgB,EAAE,cAAc,EAAE,eAAe,CAAU,CAAC;AAE3H,wFAAwF;AACxF,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,cAAc,EAAE,GAAG,cAAc,CAAU,CAAC;AAE1E,mGAAmG;AACnG,MAAM,CAAC,MAAM,kBAAkB,GAAG,OAAO,CAAC;AAE1C;;;GAGG;AACH,MAAM,oBAAoB,GAAG,kGAAkG,CAAC;AAEhI,MAAM,UAAU,SAAS,CAAC,KAAa;IACrC,OAAQ,QAA8B,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;AACzD,CAAC;AAED,M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,CAAC;IACF,KAAK,MAAM,QAAQ,IAAI,cAAc,EAAE,CAAC;QACtC,KAAK,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,IAAI,UAAU,CAAC,MAAM,QAAQ,CAAC,gBAAgB,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IACrF,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC"}
@@ -0,0 +1,10 @@
1
+ export interface SecretInput extends AsyncIterable<Uint8Array | string> {
2
+ readonly isTTY?: boolean;
3
+ setRawMode?(mode: boolean): unknown;
4
+ on?(event: 'data', listener: (chunk: Uint8Array | string) => void): unknown;
5
+ off?(event: 'data', listener: (chunk: Uint8Array | string) => void): unknown;
6
+ resume?(): unknown;
7
+ pause?(): unknown;
8
+ }
9
+ export declare function readSecret(input: SecretInput, prompt: string, writeError: (text: string) => void): Promise<string>;
10
+ //# sourceMappingURL=terminal.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"terminal.d.ts","sourceRoot":"","sources":["../src/terminal.ts"],"names":[],"mappings":"AAaA,MAAM,WAAW,WAAY,SAAQ,aAAa,CAAC,UAAU,GAAG,MAAM,CAAC;IACrE,QAAQ,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC;IACzB,UAAU,CAAC,CAAC,IAAI,EAAE,OAAO,GAAG,OAAO,CAAC;IACpC,EAAE,CAAC,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC,KAAK,EAAE,UAAU,GAAG,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC;IAC5E,GAAG,CAAC,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC,KAAK,EAAE,UAAU,GAAG,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC;IAC7E,MAAM,CAAC,IAAI,OAAO,CAAC;IACnB,KAAK,CAAC,IAAI,OAAO,CAAC;CACnB;AAsDD,wBAAsB,UAAU,CAC9B,KAAK,EAAE,WAAW,EAClB,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,GACjC,OAAO,CAAC,MAAM,CAAC,CAMjB"}
@@ -0,0 +1,70 @@
1
+ /**
2
+ * Reads one secret line from stdin without ever echoing it.
3
+ *
4
+ * On a terminal the prompt goes to stderr and the terminal is put in raw mode,
5
+ * so the code is neither displayed nor kept in the scrollback. From a pipe —
6
+ * `printf %s "$CODE" | miakapp pair`, the form an agent uses — the first line
7
+ * is read and the rest ignored. Either way the value never reaches argv, so it
8
+ * is absent from shell history and from the process list.
9
+ */
10
+ import { usageError } from './errors.js';
11
+ const MAXIMUM_SECRET_BYTES = 4_096;
12
+ function text(chunk) {
13
+ return typeof chunk === 'string' ? chunk : new TextDecoder().decode(chunk);
14
+ }
15
+ async function readPipe(input) {
16
+ let buffer = '';
17
+ for await (const chunk of input) {
18
+ buffer += text(chunk);
19
+ const newline = buffer.search(/\r?\n/);
20
+ if (newline !== -1)
21
+ return buffer.slice(0, newline);
22
+ if (buffer.length > MAXIMUM_SECRET_BYTES)
23
+ throw usageError('The secret on stdin is too long');
24
+ }
25
+ return buffer;
26
+ }
27
+ function readTerminal(input, writeError) {
28
+ return new Promise((resolve, reject) => {
29
+ let value = '';
30
+ const finish = (outcome) => {
31
+ input.off?.('data', onData);
32
+ input.setRawMode?.(false);
33
+ input.pause?.();
34
+ writeError('\n');
35
+ outcome();
36
+ };
37
+ const onData = (chunk) => {
38
+ for (const character of text(chunk)) {
39
+ if (character === '\r' || character === '\n' || character === '\u0004') {
40
+ finish(() => resolve(value));
41
+ return;
42
+ }
43
+ if (character === '\u0003') {
44
+ finish(() => reject(usageError('Cancelled')));
45
+ return;
46
+ }
47
+ if (character === '\u007f' || character === '\b') {
48
+ value = value.slice(0, -1);
49
+ continue;
50
+ }
51
+ value += character;
52
+ if (value.length > MAXIMUM_SECRET_BYTES) {
53
+ finish(() => reject(usageError('The secret is too long')));
54
+ return;
55
+ }
56
+ }
57
+ };
58
+ input.setRawMode?.(true);
59
+ input.on?.('data', onData);
60
+ input.resume?.();
61
+ });
62
+ }
63
+ export async function readSecret(input, prompt, writeError) {
64
+ if (input.isTTY === true && input.setRawMode !== undefined && input.on !== undefined) {
65
+ writeError(prompt);
66
+ return await readTerminal(input, writeError);
67
+ }
68
+ return await readPipe(input);
69
+ }
70
+ //# sourceMappingURL=terminal.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"terminal.js","sourceRoot":"","sources":["../src/terminal.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzC,MAAM,oBAAoB,GAAG,KAAK,CAAC;AAWnC,SAAS,IAAI,CAAC,KAA0B;IACtC,OAAO,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,WAAW,EAAE,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AAC7E,CAAC;AAED,KAAK,UAAU,QAAQ,CAAC,KAAkB;IACxC,IAAI,MAAM,GAAG,EAAE,CAAC;IAChB,IAAI,KAAK,EAAE,MAAM,KAAK,IAAI,KAAK,EAAE,CAAC;QAChC,MAAM,IAAI,IAAI,CAAC,KAAK,CAAC,CAAC;QACtB,MAAM,OAAO,GAAG,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;QACvC,IAAI,OAAO,KAAK,CAAC,CAAC;YAAE,OAAO,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC;QACpD,IAAI,MAAM,CAAC,MAAM,GAAG,oBAAoB;YAAE,MAAM,UAAU,CAAC,iCAAiC,CAAC,CAAC;IAChG,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC;AAED,SAAS,YAAY,CAAC,KAAkB,EAAE,UAAkC;IAC1E,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;QACrC,IAAI,KAAK,GAAG,EAAE,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QACzB,KAAK,CAAC,EAAE,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;QAC3B,KAAK,CAAC,MAAM,EAAE,EAAE,CAAC;IACnB,CAAC,CAAC,CAAC;AACL,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,UAAU,CAC9B,KAAkB,EAClB,MAAc,EACd,UAAkC;IAElC,IAAI,KAAK,CAAC,KAAK,KAAK,IAAI,IAAI,KAAK,CAAC,UAAU,KAAK,SAAS,IAAI,KAAK,CAAC,EAAE,KAAK,SAAS,EAAE,CAAC;QACrF,UAAU,CAAC,MAAM,CAAC,CAAC;QACnB,OAAO,MAAM,YAAY,CAAC,KAAK,EAAE,UAAU,CAAC,CAAC;IAC/C,CAAC;IACD,OAAO,MAAM,QAAQ,CAAC,KAAK,CAAC,CAAC;AAC/B,CAAC"}
@@ -0,0 +1,15 @@
1
+ /**
2
+ * The package's own identity, in one place.
3
+ *
4
+ * `main.ts` imports `agent-pack.ts`, so the constants cannot live in `main.ts`
5
+ * without a cycle: the pack needs them to write a runnable MCP entry.
6
+ *
7
+ * Both values are duplicates of `package.json`, which cannot be imported here
8
+ * without a JSON import assertion the build does not emit. `test/version.test.ts`
9
+ * compares them to the manifest, because the drift is not cosmetic: the pack
10
+ * writes `PACKAGE_NAME@CLI_VERSION` into a repository, and a stale version
11
+ * would resolve a different release than the guide shipped beside it.
12
+ */
13
+ export declare const PACKAGE_NAME = "@miakapp/cli";
14
+ export declare const CLI_VERSION = "4.0.0-alpha.10";
15
+ //# sourceMappingURL=version.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,YAAY,iBAAiB,CAAC;AAE3C,eAAO,MAAM,WAAW,mBAAmB,CAAC"}
@@ -0,0 +1,15 @@
1
+ /**
2
+ * The package's own identity, in one place.
3
+ *
4
+ * `main.ts` imports `agent-pack.ts`, so the constants cannot live in `main.ts`
5
+ * without a cycle: the pack needs them to write a runnable MCP entry.
6
+ *
7
+ * Both values are duplicates of `package.json`, which cannot be imported here
8
+ * without a JSON import assertion the build does not emit. `test/version.test.ts`
9
+ * compares them to the manifest, because the drift is not cosmetic: the pack
10
+ * writes `PACKAGE_NAME@CLI_VERSION` into a repository, and a stale version
11
+ * would resolve a different release than the guide shipped beside it.
12
+ */
13
+ export const PACKAGE_NAME = '@miakapp/cli';
14
+ export const CLI_VERSION = '4.0.0-alpha.10';
15
+ //# sourceMappingURL=version.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"version.js","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,cAAc,CAAC;AAE3C,MAAM,CAAC,MAAM,WAAW,GAAG,gBAAgB,CAAC"}
package/package.json CHANGED
@@ -1,14 +1,14 @@
1
1
  {
2
2
  "name": "@miakapp/cli",
3
- "version": "4.0.0-alpha.0",
4
- "description": "Agent-first Miakapp command line: check, build, publish, activate and roll back home components",
3
+ "version": "4.0.0-alpha.10",
4
+ "description": "Agent-first Miakapp command line: check, build, publish, activate and roll back home interfaces",
5
5
  "type": "module",
6
6
  "engines": {
7
7
  "bun": ">=1.2.23",
8
8
  "node": ">=22.9"
9
9
  },
10
10
  "bin": {
11
- "miakapp": "./bin/miakapp.js"
11
+ "miakapp": "bin/miakapp.js"
12
12
  },
13
13
  "files": [
14
14
  "assets",
@@ -20,6 +20,7 @@
20
20
  "sideEffects": false,
21
21
  "scripts": {
22
22
  "build": "tsc -p tsconfig.build.json",
23
+ "prepack": "bun run build",
23
24
  "test": "bun test test/",
24
25
  "typecheck": "tsc --noEmit",
25
26
  "check": "bun run typecheck && bun run build && bun run test"
@@ -30,7 +31,8 @@
30
31
  "directory": "packages/cli"
31
32
  },
32
33
  "publishConfig": {
33
- "access": "public"
34
+ "access": "public",
35
+ "tag": "latest"
34
36
  },
35
37
  "keywords": [
36
38
  "Miakapp",