@notis_ai/cli 0.2.0 → 0.2.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 +39 -10
- package/package.json +7 -1
- package/src/command-specs/apps.js +852 -47
- package/src/command-specs/helpers.js +28 -3
- package/src/command-specs/index.js +1 -1
- package/src/command-specs/tools.js +33 -6
- package/src/runtime/agent-browser.js +192 -0
- package/src/runtime/app-boundary-validator.js +132 -0
- package/src/runtime/app-dev-server.js +577 -0
- package/src/runtime/app-dev-sessions.js +87 -0
- package/src/runtime/app-platform.js +646 -71
- package/src/runtime/cli-mode.generated.js +4 -0
- package/src/runtime/cli-mode.js +29 -0
- package/src/runtime/output.js +2 -2
- package/src/runtime/ports.js +15 -0
- package/src/runtime/profiles.js +34 -3
- package/src/runtime/transport.js +129 -4
- package/template/.harness/index.html.tmpl +260 -0
- package/template/app/globals.css +3 -0
- package/template/app/layout.tsx +6 -0
- package/template/app/page.tsx +55 -0
- package/template/components/ui/badge.tsx +28 -0
- package/template/components/ui/button.tsx +53 -0
- package/template/components/ui/card.tsx +56 -0
- package/template/components.json +20 -0
- package/template/lib/utils.ts +6 -0
- package/template/notis.config.ts +33 -0
- package/template/package.json +31 -0
- package/template/packages/notis-sdk/package.json +26 -0
- package/template/packages/notis-sdk/src/components/MultiSelectActionBar.tsx +272 -0
- package/template/packages/notis-sdk/src/components/MultiSelectCheckbox.tsx +91 -0
- package/template/packages/notis-sdk/src/components/MultiSelectDragOverlay.tsx +39 -0
- package/template/packages/notis-sdk/src/config.ts +71 -0
- package/template/packages/notis-sdk/src/helpers.ts +131 -0
- package/template/packages/notis-sdk/src/hooks/useAppState.ts +50 -0
- package/template/packages/notis-sdk/src/hooks/useBackend.ts +41 -0
- package/template/packages/notis-sdk/src/hooks/useCollectionItem.ts +58 -0
- package/template/packages/notis-sdk/src/hooks/useDatabase.ts +88 -0
- package/template/packages/notis-sdk/src/hooks/useDocument.ts +61 -0
- package/template/packages/notis-sdk/src/hooks/useMultiSelect.ts +502 -0
- package/template/packages/notis-sdk/src/hooks/useNotis.ts +33 -0
- package/template/packages/notis-sdk/src/hooks/useNotisNavigation.ts +49 -0
- package/template/packages/notis-sdk/src/hooks/useTool.ts +49 -0
- package/template/packages/notis-sdk/src/hooks/useTools.ts +56 -0
- package/template/packages/notis-sdk/src/hooks/useTopBarSearch.ts +73 -0
- package/template/packages/notis-sdk/src/hooks/useUpsertDocument.ts +58 -0
- package/template/packages/notis-sdk/src/index.ts +67 -0
- package/template/packages/notis-sdk/src/provider.tsx +43 -0
- package/template/packages/notis-sdk/src/runtime.ts +182 -0
- package/template/packages/notis-sdk/src/styles.css +38 -0
- package/template/packages/notis-sdk/src/ui.ts +15 -0
- package/template/packages/notis-sdk/src/vite.ts +56 -0
- package/template/packages/notis-sdk/tsconfig.json +15 -0
- package/template/postcss.config.mjs +8 -0
- package/template/tailwind.config.ts +58 -0
- package/template/tsconfig.json +22 -0
- package/template/vite.config.ts +10 -0
- package/src/runtime/app-preview-server.js +0 -272
package/README.md
CHANGED
|
@@ -84,7 +84,7 @@ Examples:
|
|
|
84
84
|
|
|
85
85
|
Scaffold a new Notis app project.
|
|
86
86
|
|
|
87
|
-
When to use: Start a new Notis app. Creates a
|
|
87
|
+
When to use: Start a new Notis app. Creates a Vite + React project with @notis/sdk pre-configured.
|
|
88
88
|
|
|
89
89
|
Examples:
|
|
90
90
|
- `notis apps init "Mind the Flo"`
|
|
@@ -106,36 +106,48 @@ Examples:
|
|
|
106
106
|
|
|
107
107
|
### `notis apps dev [dir]`
|
|
108
108
|
|
|
109
|
-
|
|
109
|
+
Develop Notis apps inside the Electron desktop Portal with automatic local bundle reloads.
|
|
110
110
|
|
|
111
|
-
When to use:
|
|
111
|
+
When to use: Run this inside a single app or a monorepo root with apps/<name>/notis.config.ts. It discovers every app, starts the local bundle server, registers desktop-local dev sessions, and opens the Electron Portal Development tab.
|
|
112
|
+
|
|
113
|
+
Options:
|
|
114
|
+
- `--port <number>` — Local bundle server port (default: 5173).
|
|
115
|
+
- `--no-open` — Do not auto-open the desktop Portal Development tab.
|
|
112
116
|
|
|
113
117
|
Examples:
|
|
114
118
|
- `notis apps dev`
|
|
115
119
|
- `notis apps dev ./my-app`
|
|
120
|
+
- `notis apps dev ./workspace --port 5200`
|
|
116
121
|
|
|
117
122
|
### `notis apps build [dir]`
|
|
118
123
|
|
|
119
124
|
Build and package the app into .notis/output/.
|
|
120
125
|
|
|
121
|
-
When to use: Prepare the app for
|
|
126
|
+
When to use: Prepare the app for verification or deployment.
|
|
122
127
|
|
|
123
128
|
Examples:
|
|
124
129
|
- `notis apps build`
|
|
125
130
|
- `notis apps build ./my-app`
|
|
126
131
|
|
|
127
|
-
### `notis apps
|
|
132
|
+
### `notis apps verify [dir]`
|
|
128
133
|
|
|
129
|
-
|
|
134
|
+
Headless render smoke each route in a stub-runtime harness.
|
|
130
135
|
|
|
131
|
-
When to use:
|
|
136
|
+
When to use: After notis apps build, before deploy. Catches render-time crashes and missing runtime calls that the build step cannot detect.
|
|
132
137
|
|
|
133
138
|
Options:
|
|
134
|
-
- `--
|
|
139
|
+
- `--routes <slugs>` — Comma-separated route slugs. Default: every route in manifest.
|
|
140
|
+
- `--port <n>` — Loopback port. Default: auto-pick.
|
|
141
|
+
- `--skip-build` — Skip notis apps build; reuse existing .notis/output/.
|
|
142
|
+
- `--mode <mode>` — stub | live. Default stub. Live posts to /portal_views/runtime_query with the CLI JWT.
|
|
143
|
+
- `--no-browser` — Start the harness server and print URLs; do not drive agent-browser.
|
|
144
|
+
- `--keep-open` — Leave server + browser session running after report (for manual triage).
|
|
135
145
|
|
|
136
146
|
Examples:
|
|
137
|
-
- `notis apps
|
|
138
|
-
- `notis apps
|
|
147
|
+
- `notis apps verify`
|
|
148
|
+
- `notis apps verify --routes notes`
|
|
149
|
+
- `notis apps verify --mode live`
|
|
150
|
+
- `notis apps verify --no-browser # start the harness, drive agent-browser yourself`
|
|
139
151
|
|
|
140
152
|
### `notis apps link <app-id> [dir]`
|
|
141
153
|
|
|
@@ -147,6 +159,20 @@ Examples:
|
|
|
147
159
|
- `notis apps link abc123`
|
|
148
160
|
- `notis apps link abc123 ./my-app`
|
|
149
161
|
|
|
162
|
+
### `notis apps pull <app-id> [dir]`
|
|
163
|
+
|
|
164
|
+
Download a Notis app source snapshot into a local project folder.
|
|
165
|
+
|
|
166
|
+
When to use: Edit an installed app locally. Pulls the persisted source and links the directory to the app.
|
|
167
|
+
|
|
168
|
+
Options:
|
|
169
|
+
- `--force` — Overwrite a non-empty target directory.
|
|
170
|
+
- `--version <n>` — Pull a specific app source version (default: latest).
|
|
171
|
+
|
|
172
|
+
Examples:
|
|
173
|
+
- `notis apps pull abc123`
|
|
174
|
+
- `notis apps pull abc123 ./my-app --force`
|
|
175
|
+
|
|
150
176
|
### `notis apps deploy [dir]`
|
|
151
177
|
|
|
152
178
|
Build and upload the app to the linked Notis app.
|
|
@@ -156,11 +182,13 @@ When to use: Ship the installed app to production for the linked user/team app.
|
|
|
156
182
|
Options:
|
|
157
183
|
- `--app-id <id>` — Override linked app ID.
|
|
158
184
|
- `--skip-build` — Skip the build step (use existing .notis/output/).
|
|
185
|
+
- `--direct` — Upload directly to Supabase storage, bypassing the backend server. Auto-fallback on network errors.
|
|
159
186
|
|
|
160
187
|
Examples:
|
|
161
188
|
- `notis apps deploy`
|
|
162
189
|
- `notis apps deploy --skip-build`
|
|
163
190
|
- `notis apps deploy --app-id abc123`
|
|
191
|
+
- `notis apps deploy --direct`
|
|
164
192
|
|
|
165
193
|
### `notis apps doctor [dir]`
|
|
166
194
|
|
|
@@ -270,6 +298,7 @@ Options:
|
|
|
270
298
|
- `--get-schema` — Display the tool parameter schema without executing.
|
|
271
299
|
- `--dry-run` — Validate arguments against the tool schema without executing.
|
|
272
300
|
- `--watch <seconds>` — Re-execute on an interval and stream results.
|
|
301
|
+
- `--toolkits <csv-or-json>` — Optional toolkit namespace(s) to use when resolving the tool.
|
|
273
302
|
|
|
274
303
|
Examples:
|
|
275
304
|
- `notis tools exec notis-default-query --arguments '{"database_slug":"tasks","query":{}}'`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@notis_ai/cli",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.1",
|
|
4
4
|
"description": "Agent-first Notis CLI for apps, databases, and generic tool execution",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -9,11 +9,14 @@
|
|
|
9
9
|
"files": [
|
|
10
10
|
"bin/",
|
|
11
11
|
"src/",
|
|
12
|
+
"template/",
|
|
12
13
|
"README.md"
|
|
13
14
|
],
|
|
14
15
|
"scripts": {
|
|
15
16
|
"docs:generate": "node ./scripts/generate-docs.js",
|
|
16
17
|
"docs:check": "node ./scripts/generate-docs.js --check",
|
|
18
|
+
"release:prepare": "node ./scripts/prepare-publish.js --apply",
|
|
19
|
+
"cli:set-mode": "node ./scripts/set-cli-mode.js",
|
|
17
20
|
"test": "node --test"
|
|
18
21
|
},
|
|
19
22
|
"engines": {
|
|
@@ -29,5 +32,8 @@
|
|
|
29
32
|
"ai",
|
|
30
33
|
"agent-skills"
|
|
31
34
|
],
|
|
35
|
+
"publishConfig": {
|
|
36
|
+
"access": "public"
|
|
37
|
+
},
|
|
32
38
|
"license": "MIT"
|
|
33
39
|
}
|