@lasso-ai/cli 1.0.1 → 1.0.3
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 +4 -4
- package/dist/cli/auth.d.ts +2 -1
- package/dist/cli/auth.js +3 -2
- package/dist/cli/index.js +2 -1
- package/dist/overlay.js +2 -3
- package/docs/PUBLISHING.md +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -235,7 +235,7 @@ and refuses any non-`.lasso` host. The secure URL is
|
|
|
235
235
|
### 1. Install
|
|
236
236
|
|
|
237
237
|
```bash
|
|
238
|
-
npm
|
|
238
|
+
npm i -g @lasso-ai/cli
|
|
239
239
|
```
|
|
240
240
|
|
|
241
241
|
Or:
|
|
@@ -252,15 +252,15 @@ You can also install the CLI globally and use `lasso` directly from any
|
|
|
252
252
|
project:
|
|
253
253
|
|
|
254
254
|
```bash
|
|
255
|
-
npm
|
|
255
|
+
npm i -g @lasso-ai/cli
|
|
256
256
|
# or
|
|
257
257
|
pnpm add --global @lasso-ai/cli
|
|
258
258
|
# or
|
|
259
259
|
yarn global add @lasso-ai/cli
|
|
260
260
|
```
|
|
261
261
|
|
|
262
|
-
Use
|
|
263
|
-
|
|
262
|
+
Use the global install for the supported hosted CLI. Set `LASSO_AUTH_URL=http://localhost:3005`
|
|
263
|
+
only when developing against a local Lasso server.
|
|
264
264
|
|
|
265
265
|
### 2. Start Lasso
|
|
266
266
|
|
package/dist/cli/auth.d.ts
CHANGED
|
@@ -10,7 +10,8 @@ export interface CliCredentials {
|
|
|
10
10
|
/**
|
|
11
11
|
* Base URL of the Lasso API (the main server, not the realtime server). The
|
|
12
12
|
* `lasso auth` flow lives here because the browser confirm needs the web session.
|
|
13
|
-
* Defaults to the
|
|
13
|
+
* Defaults to the hosted Lasso API. Set LASSO_AUTH_URL or LASSO_API_URL for
|
|
14
|
+
* local development.
|
|
14
15
|
*/
|
|
15
16
|
export declare function serverUrlFrom(fileEnv: Record<string, string>): string;
|
|
16
17
|
export declare function fetchWithTimeout(url: string, init?: RequestInit, timeoutMs?: number): Promise<Response>;
|
package/dist/cli/auth.js
CHANGED
|
@@ -22,14 +22,15 @@ const CREDENTIALS_FILE = node_path_1.default.join(CREDENTIALS_DIR, "credentials.
|
|
|
22
22
|
/**
|
|
23
23
|
* Base URL of the Lasso API (the main server, not the realtime server). The
|
|
24
24
|
* `lasso auth` flow lives here because the browser confirm needs the web session.
|
|
25
|
-
* Defaults to the
|
|
25
|
+
* Defaults to the hosted Lasso API. Set LASSO_AUTH_URL or LASSO_API_URL for
|
|
26
|
+
* local development.
|
|
26
27
|
*/
|
|
27
28
|
function serverUrlFrom(fileEnv) {
|
|
28
29
|
return (process.env.LASSO_AUTH_URL ||
|
|
29
30
|
fileEnv.LASSO_AUTH_URL ||
|
|
30
31
|
process.env.LASSO_API_URL ||
|
|
31
32
|
fileEnv.LASSO_API_URL ||
|
|
32
|
-
"
|
|
33
|
+
"https://api.lasso.byorello.space").replace(/\/$/, "");
|
|
33
34
|
}
|
|
34
35
|
function fetchWithTimeout(url, init, timeoutMs = 8000) {
|
|
35
36
|
const controller = new AbortController();
|
package/dist/cli/index.js
CHANGED
|
@@ -19,7 +19,8 @@ const paths_1 = require("./host/paths");
|
|
|
19
19
|
const install_1 = require("./host/install");
|
|
20
20
|
const client_1 = require("./host/client");
|
|
21
21
|
const registry_1 = require("./host/registry");
|
|
22
|
-
const
|
|
22
|
+
const package_json_1 = __importDefault(require("../../package.json"));
|
|
23
|
+
const VERSION = package_json_1.default.version;
|
|
23
24
|
const program = new commander_1.Command();
|
|
24
25
|
program.name("lasso").description("Select UI in your running app, describe a change, AI edits the real source.").version(VERSION);
|
|
25
26
|
function projectEnv() {
|
package/dist/overlay.js
CHANGED
|
@@ -15648,9 +15648,8 @@
|
|
|
15648
15648
|
}
|
|
15649
15649
|
const isLassoPage = typeof window !== "undefined" && window.location.hostname.endsWith(".lasso");
|
|
15650
15650
|
const candidateUrls = isLassoPage ? ["https://api.lasso.byorello.space/api/v1/transcribe"] : [
|
|
15651
|
-
"
|
|
15652
|
-
"/api/v1/transcribe"
|
|
15653
|
-
"https://api.lasso.byorello.space/api/v1/transcribe"
|
|
15651
|
+
"https://api.lasso.byorello.space/api/v1/transcribe",
|
|
15652
|
+
"/api/v1/transcribe"
|
|
15654
15653
|
];
|
|
15655
15654
|
let lastError = new Error("Failed to contact transcription service");
|
|
15656
15655
|
for (const url2 of candidateUrls) {
|
package/docs/PUBLISHING.md
CHANGED
package/package.json
CHANGED