@elaraai/e3-cli 0.0.2-beta.12 → 0.0.2-beta.14
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 +21 -9
- package/dist/src/cli.js +29 -14
- package/dist/src/cli.js.map +1 -1
- package/dist/src/commands/auth.d.ts +21 -0
- package/dist/src/commands/auth.d.ts.map +1 -0
- package/dist/src/commands/auth.js +185 -0
- package/dist/src/commands/auth.js.map +1 -0
- package/dist/src/commands/get.d.ts.map +1 -1
- package/dist/src/commands/get.js +32 -14
- package/dist/src/commands/get.js.map +1 -1
- package/dist/src/commands/list.d.ts.map +1 -1
- package/dist/src/commands/list.js +47 -14
- package/dist/src/commands/list.js.map +1 -1
- package/dist/src/commands/logs.d.ts.map +1 -1
- package/dist/src/commands/logs.js +126 -54
- package/dist/src/commands/logs.js.map +1 -1
- package/dist/src/commands/package.d.ts.map +1 -1
- package/dist/src/commands/package.js +55 -18
- package/dist/src/commands/package.js.map +1 -1
- package/dist/src/commands/repo.d.ts +29 -0
- package/dist/src/commands/repo.d.ts.map +1 -0
- package/dist/src/commands/repo.js +231 -0
- package/dist/src/commands/repo.js.map +1 -0
- package/dist/src/commands/run.d.ts.map +1 -1
- package/dist/src/commands/run.js +4 -3
- package/dist/src/commands/run.js.map +1 -1
- package/dist/src/commands/set.d.ts.map +1 -1
- package/dist/src/commands/set.js +16 -5
- package/dist/src/commands/set.js.map +1 -1
- package/dist/src/commands/start.d.ts.map +1 -1
- package/dist/src/commands/start.js +166 -47
- package/dist/src/commands/start.js.map +1 -1
- package/dist/src/commands/tree.d.ts.map +1 -1
- package/dist/src/commands/tree.js +110 -16
- package/dist/src/commands/tree.js.map +1 -1
- package/dist/src/commands/watch.d.ts.map +1 -1
- package/dist/src/commands/watch.js +8 -6
- package/dist/src/commands/watch.js.map +1 -1
- package/dist/src/commands/workspace.d.ts +4 -0
- package/dist/src/commands/workspace.d.ts.map +1 -1
- package/dist/src/commands/workspace.js +269 -29
- package/dist/src/commands/workspace.js.map +1 -1
- package/dist/src/credentials.d.ts +123 -0
- package/dist/src/credentials.d.ts.map +1 -0
- package/dist/src/credentials.js +213 -0
- package/dist/src/credentials.js.map +1 -0
- package/dist/src/utils.d.ts +48 -0
- package/dist/src/utils.d.ts.map +1 -1
- package/dist/src/utils.js +58 -0
- package/dist/src/utils.js.map +1 -1
- package/package.json +6 -5
- package/dist/src/commands/gc.d.ts +0 -12
- package/dist/src/commands/gc.d.ts.map +0 -1
- package/dist/src/commands/gc.js +0 -44
- package/dist/src/commands/gc.js.map +0 -1
- package/dist/src/commands/init.d.ts +0 -9
- package/dist/src/commands/init.d.ts.map +0 -1
- package/dist/src/commands/init.js +0 -33
- package/dist/src/commands/init.js.map +0 -1
- package/dist/src/commands/status.d.ts +0 -9
- package/dist/src/commands/status.d.ts.map +0 -1
- package/dist/src/commands/status.js +0 -157
- package/dist/src/commands/status.js.map +0 -1
package/README.md
CHANGED
|
@@ -13,18 +13,19 @@ npm install -g @elaraai/e3-cli
|
|
|
13
13
|
### Repository
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
|
-
e3
|
|
17
|
-
e3 status <repo>
|
|
18
|
-
e3
|
|
16
|
+
e3 repo create <repo> # Create a new repository
|
|
17
|
+
e3 repo status <repo> # Show repository status
|
|
18
|
+
e3 repo remove <repo> # Remove a repository
|
|
19
|
+
e3 repo gc <repo> [--dry-run] # Remove unreferenced objects
|
|
19
20
|
```
|
|
20
21
|
|
|
21
22
|
### Packages
|
|
22
23
|
|
|
23
24
|
```bash
|
|
24
|
-
e3 package import <repo> <zip>
|
|
25
|
+
e3 package import <repo> <zip> # Import package from .zip
|
|
25
26
|
e3 package export <repo> <pkg> <zip> # Export package to .zip
|
|
26
|
-
e3 package list <repo>
|
|
27
|
-
e3 package remove <repo> <pkg>
|
|
27
|
+
e3 package list <repo> # List installed packages
|
|
28
|
+
e3 package remove <repo> <pkg> # Remove a package
|
|
28
29
|
```
|
|
29
30
|
|
|
30
31
|
### Workspaces
|
|
@@ -34,6 +35,7 @@ e3 workspace create <repo> <name> # Create empty workspace
|
|
|
34
35
|
e3 workspace deploy <repo> <ws> <pkg> # Deploy package to workspace
|
|
35
36
|
e3 workspace export <repo> <ws> <zip> # Export workspace as package
|
|
36
37
|
e3 workspace list <repo> # List workspaces
|
|
38
|
+
e3 workspace status <repo> <ws> # Show workspace status
|
|
37
39
|
e3 workspace remove <repo> <ws> # Remove workspace
|
|
38
40
|
```
|
|
39
41
|
|
|
@@ -41,6 +43,7 @@ e3 workspace remove <repo> <ws> # Remove workspace
|
|
|
41
43
|
|
|
42
44
|
```bash
|
|
43
45
|
e3 list <repo> [path] # List workspaces or tree contents
|
|
46
|
+
e3 tree <repo> <path> # Show full tree structure
|
|
44
47
|
e3 get <repo> <path> [-f format] # Get dataset value (east/json/beast2)
|
|
45
48
|
e3 set <repo> <path> <file> # Set dataset value from file
|
|
46
49
|
```
|
|
@@ -48,8 +51,9 @@ e3 set <repo> <path> <file> # Set dataset value from file
|
|
|
48
51
|
### Execution
|
|
49
52
|
|
|
50
53
|
```bash
|
|
51
|
-
e3 run <repo> <task> [inputs...] # Run task ad-hoc
|
|
52
54
|
e3 start <repo> <ws> # Execute tasks in workspace
|
|
55
|
+
e3 run <repo> <task> [inputs...] # Run task ad-hoc
|
|
56
|
+
e3 watch <repo> <ws> <source.ts> # Watch and auto-deploy on changes
|
|
53
57
|
e3 logs <repo> <path> [--follow] # View task logs
|
|
54
58
|
```
|
|
55
59
|
|
|
@@ -59,11 +63,19 @@ e3 logs <repo> <path> [--follow] # View task logs
|
|
|
59
63
|
e3 convert [input] --to <format> # Convert between .east/.json/.beast2
|
|
60
64
|
```
|
|
61
65
|
|
|
66
|
+
### Authentication (for remote servers)
|
|
67
|
+
|
|
68
|
+
```bash
|
|
69
|
+
e3 login <url> # Authenticate with remote server
|
|
70
|
+
e3 logout <url> # Clear stored credentials
|
|
71
|
+
e3 auth status # Show authentication status
|
|
72
|
+
```
|
|
73
|
+
|
|
62
74
|
## Example
|
|
63
75
|
|
|
64
76
|
```bash
|
|
65
|
-
#
|
|
66
|
-
e3
|
|
77
|
+
# Create repository and import a package
|
|
78
|
+
e3 repo create ./my-project
|
|
67
79
|
e3 package import ./my-project ./greeting-pkg-1.0.0.zip
|
|
68
80
|
|
|
69
81
|
# Create workspace and deploy package
|
package/dist/src/cli.js
CHANGED
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import { createRequire } from 'node:module';
|
|
12
12
|
import { Command } from 'commander';
|
|
13
|
-
import { initCommand } from './commands/init.js';
|
|
14
13
|
const require = createRequire(import.meta.url);
|
|
15
14
|
const packageJson = require('../../package.json');
|
|
15
|
+
import { repoCommand } from './commands/repo.js';
|
|
16
16
|
import { packageCommand } from './commands/package.js';
|
|
17
17
|
import { workspaceCommand } from './commands/workspace.js';
|
|
18
18
|
import { listCommand } from './commands/list.js';
|
|
@@ -22,10 +22,9 @@ import { setCommand } from './commands/set.js';
|
|
|
22
22
|
import { startCommand } from './commands/start.js';
|
|
23
23
|
import { runCommand } from './commands/run.js';
|
|
24
24
|
import { logsCommand } from './commands/logs.js';
|
|
25
|
-
import { statusCommand } from './commands/status.js';
|
|
26
|
-
import { gcCommand } from './commands/gc.js';
|
|
27
25
|
import { convertCommand } from './commands/convert.js';
|
|
28
26
|
import { watchCommand } from './commands/watch.js';
|
|
27
|
+
import { createAuthCommand, createLoginCommand, createLogoutCommand } from './commands/auth.js';
|
|
29
28
|
const program = new Command();
|
|
30
29
|
program
|
|
31
30
|
.name('e3')
|
|
@@ -33,19 +32,26 @@ program
|
|
|
33
32
|
.version(packageJson.version);
|
|
34
33
|
// Repository commands
|
|
35
34
|
program
|
|
36
|
-
.command('
|
|
37
|
-
.description('
|
|
38
|
-
.
|
|
39
|
-
|
|
40
|
-
.
|
|
41
|
-
.
|
|
42
|
-
.
|
|
43
|
-
|
|
44
|
-
.
|
|
35
|
+
.command('repo')
|
|
36
|
+
.description('Repository operations')
|
|
37
|
+
.addCommand(new Command('create')
|
|
38
|
+
.description('Create a new repository')
|
|
39
|
+
.argument('<repo>', 'Repository path or URL')
|
|
40
|
+
.action(repoCommand.create))
|
|
41
|
+
.addCommand(new Command('remove')
|
|
42
|
+
.description('Remove a repository')
|
|
43
|
+
.argument('<repo>', 'Repository path or URL')
|
|
44
|
+
.action(repoCommand.remove))
|
|
45
|
+
.addCommand(new Command('status')
|
|
46
|
+
.description('Show repository status')
|
|
47
|
+
.argument('<repo>', 'Repository path or URL')
|
|
48
|
+
.action(repoCommand.status))
|
|
49
|
+
.addCommand(new Command('gc')
|
|
45
50
|
.description('Remove unreferenced objects')
|
|
51
|
+
.argument('<repo>', 'Repository path or URL')
|
|
46
52
|
.option('--dry-run', 'Report what would be deleted without deleting')
|
|
47
53
|
.option('--min-age <ms>', 'Minimum file age in ms before deletion', '60000')
|
|
48
|
-
.action(
|
|
54
|
+
.action(repoCommand.gc));
|
|
49
55
|
// Package commands
|
|
50
56
|
program
|
|
51
57
|
.command('package')
|
|
@@ -101,7 +107,12 @@ program
|
|
|
101
107
|
.description('Remove a workspace')
|
|
102
108
|
.argument('<repo>', 'Repository path')
|
|
103
109
|
.argument('<ws>', 'Workspace name')
|
|
104
|
-
.action(workspaceCommand.remove))
|
|
110
|
+
.action(workspaceCommand.remove))
|
|
111
|
+
.addCommand(new Command('status')
|
|
112
|
+
.description('Show detailed workspace status (tasks, datasets, locks)')
|
|
113
|
+
.argument('<repo>', 'Repository path')
|
|
114
|
+
.argument('<ws>', 'Workspace name')
|
|
115
|
+
.action(workspaceCommand.status));
|
|
105
116
|
// Dataset commands
|
|
106
117
|
program
|
|
107
118
|
.command('list <repo> [path]')
|
|
@@ -158,5 +169,9 @@ program
|
|
|
158
169
|
.option('-o, --output <path>', 'Output file path (default: stdout)')
|
|
159
170
|
.option('--type <typespec>', 'Type specification in .east format')
|
|
160
171
|
.action(convertCommand);
|
|
172
|
+
// Authentication commands
|
|
173
|
+
program.addCommand(createLoginCommand());
|
|
174
|
+
program.addCommand(createLogoutCommand());
|
|
175
|
+
program.addCommand(createAuthCommand());
|
|
161
176
|
program.parse();
|
|
162
177
|
//# sourceMappingURL=cli.js.map
|
package/dist/src/cli.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":";AAEA;;;GAGG;AAEH;;;;GAIG;AAEH,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":";AAEA;;;GAGG;AAEH;;;;GAIG;AAEH,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,MAAM,OAAO,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC/C,MAAM,WAAW,GAAG,OAAO,CAAC,oBAAoB,CAAwB,CAAC;AACzE,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,E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|
8
|
+
import { Command } from 'commander';
|
|
9
|
+
/**
|
|
10
|
+
* Create the auth command group.
|
|
11
|
+
*/
|
|
12
|
+
export declare function createAuthCommand(): Command;
|
|
13
|
+
/**
|
|
14
|
+
* Create the login command.
|
|
15
|
+
*/
|
|
16
|
+
export declare function createLoginCommand(): Command;
|
|
17
|
+
/**
|
|
18
|
+
* Create the logout command.
|
|
19
|
+
*/
|
|
20
|
+
export declare function createLogoutCommand(): Command;
|
|
21
|
+
//# sourceMappingURL=auth.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../../src/commands/auth.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAyCpC;;GAEG;AACH,wBAAgB,iBAAiB,IAAI,OAAO,CA8D3C;AAED;;GAEG;AACH,wBAAgB,kBAAkB,IAAI,OAAO,CA6E5C;AAED;;GAEG;AACH,wBAAgB,mBAAmB,IAAI,OAAO,CAa7C"}
|
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025 Elara AI Pty Ltd
|
|
3
|
+
* Licensed under BSL 1.1. See LICENSE for details.
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Authentication commands for e3 CLI.
|
|
7
|
+
*/
|
|
8
|
+
import { Command } from 'commander';
|
|
9
|
+
import { fetchDiscovery, startDeviceAuth, pollForTokens, setCredential, removeCredential, listCredentials, getCredential, isExpired, decodeJwtPayload, normalizeServerUrl, } from '../credentials.js';
|
|
10
|
+
/**
|
|
11
|
+
* Try to open a URL in the default browser.
|
|
12
|
+
*/
|
|
13
|
+
async function openBrowser(url) {
|
|
14
|
+
const { exec } = await import('node:child_process');
|
|
15
|
+
const { platform } = await import('node:os');
|
|
16
|
+
return new Promise((resolve) => {
|
|
17
|
+
let command;
|
|
18
|
+
switch (platform()) {
|
|
19
|
+
case 'darwin':
|
|
20
|
+
command = `open "${url}"`;
|
|
21
|
+
break;
|
|
22
|
+
case 'win32':
|
|
23
|
+
command = `start "" "${url}"`;
|
|
24
|
+
break;
|
|
25
|
+
default:
|
|
26
|
+
command = `xdg-open "${url}"`;
|
|
27
|
+
}
|
|
28
|
+
exec(command, (error) => {
|
|
29
|
+
resolve(!error);
|
|
30
|
+
});
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Create the auth command group.
|
|
35
|
+
*/
|
|
36
|
+
export function createAuthCommand() {
|
|
37
|
+
const auth = new Command('auth')
|
|
38
|
+
.description('Authentication commands');
|
|
39
|
+
// e3 auth status - List all saved credentials
|
|
40
|
+
auth
|
|
41
|
+
.command('status')
|
|
42
|
+
.description('List saved credentials')
|
|
43
|
+
.action(() => {
|
|
44
|
+
const creds = listCredentials();
|
|
45
|
+
if (creds.length === 0) {
|
|
46
|
+
console.log('No saved credentials.');
|
|
47
|
+
console.log('Run: e3 login <server>');
|
|
48
|
+
return;
|
|
49
|
+
}
|
|
50
|
+
console.log('Saved credentials:\n');
|
|
51
|
+
for (const { server, expiresAt } of creds) {
|
|
52
|
+
const expired = isExpired(expiresAt);
|
|
53
|
+
const status = expired ? '(expired)' : '(valid)';
|
|
54
|
+
console.log(` ${server} ${status}`);
|
|
55
|
+
console.log(` Token expires: ${expiresAt}`);
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
// e3 auth whoami [server] - Show current identity
|
|
59
|
+
auth
|
|
60
|
+
.command('whoami')
|
|
61
|
+
.description('Show current identity')
|
|
62
|
+
.argument('[server]', 'Server URL')
|
|
63
|
+
.action((server) => {
|
|
64
|
+
const creds = listCredentials();
|
|
65
|
+
if (creds.length === 0) {
|
|
66
|
+
console.log('Not logged in to any servers.');
|
|
67
|
+
return;
|
|
68
|
+
}
|
|
69
|
+
const servers = server ? [server] : creds.map((c) => c.server);
|
|
70
|
+
for (const serverUrl of servers) {
|
|
71
|
+
const credential = getCredential(serverUrl);
|
|
72
|
+
if (!credential) {
|
|
73
|
+
console.log(`${serverUrl}: Not logged in`);
|
|
74
|
+
continue;
|
|
75
|
+
}
|
|
76
|
+
try {
|
|
77
|
+
const payload = decodeJwtPayload(credential.accessToken);
|
|
78
|
+
const expired = isExpired(credential.expiresAt);
|
|
79
|
+
const status = expired ? '(token expired)' : '';
|
|
80
|
+
console.log(`${serverUrl}: ${status}`);
|
|
81
|
+
console.log(` Subject: ${payload.sub ?? 'unknown'}`);
|
|
82
|
+
if (payload.email) {
|
|
83
|
+
console.log(` Email: ${payload.email}`);
|
|
84
|
+
}
|
|
85
|
+
console.log(` Issuer: ${payload.iss ?? 'unknown'}`);
|
|
86
|
+
}
|
|
87
|
+
catch {
|
|
88
|
+
console.log(`${serverUrl}: Invalid token`);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
});
|
|
92
|
+
return auth;
|
|
93
|
+
}
|
|
94
|
+
/**
|
|
95
|
+
* Create the login command.
|
|
96
|
+
*/
|
|
97
|
+
export function createLoginCommand() {
|
|
98
|
+
return new Command('login')
|
|
99
|
+
.description('Log in to a server using OAuth2 Device Flow')
|
|
100
|
+
.argument('<server>', 'Server URL (e.g., http://localhost:3000)')
|
|
101
|
+
.option('--no-browser', 'Do not open browser (for CI/headless environments)')
|
|
102
|
+
.action(async (server, options) => {
|
|
103
|
+
const serverUrl = normalizeServerUrl(server);
|
|
104
|
+
console.log(`Logging in to ${serverUrl}...`);
|
|
105
|
+
// Fetch OIDC discovery document
|
|
106
|
+
let discovery;
|
|
107
|
+
try {
|
|
108
|
+
discovery = await fetchDiscovery(serverUrl);
|
|
109
|
+
}
|
|
110
|
+
catch (err) {
|
|
111
|
+
const message = err instanceof Error ? err.message : 'unknown error';
|
|
112
|
+
console.error(`Failed to connect to server: ${message}`);
|
|
113
|
+
console.error('Make sure the server is running with --oidc enabled.');
|
|
114
|
+
process.exit(1);
|
|
115
|
+
}
|
|
116
|
+
// Start device authorization
|
|
117
|
+
let deviceAuth;
|
|
118
|
+
try {
|
|
119
|
+
deviceAuth = await startDeviceAuth(discovery);
|
|
120
|
+
}
|
|
121
|
+
catch (err) {
|
|
122
|
+
const message = err instanceof Error ? err.message : 'unknown error';
|
|
123
|
+
console.error(`Failed to start login: ${message}`);
|
|
124
|
+
process.exit(1);
|
|
125
|
+
}
|
|
126
|
+
// Display user code and URL (unless in quiet CI mode)
|
|
127
|
+
if (options.browser) {
|
|
128
|
+
console.log('\nTo complete login:');
|
|
129
|
+
console.log(` 1. Open: ${deviceAuth.verification_uri}`);
|
|
130
|
+
console.log(` 2. Enter code: ${deviceAuth.user_code}`);
|
|
131
|
+
console.log(`\nOr visit this URL directly:`);
|
|
132
|
+
console.log(` ${deviceAuth.verification_uri_complete}`);
|
|
133
|
+
// Try to open browser
|
|
134
|
+
const opened = await openBrowser(deviceAuth.verification_uri_complete);
|
|
135
|
+
if (opened) {
|
|
136
|
+
console.log('\nBrowser opened. Waiting for approval...');
|
|
137
|
+
}
|
|
138
|
+
else {
|
|
139
|
+
console.log('\nWaiting for approval...');
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
else {
|
|
143
|
+
console.log('Waiting for server approval (--no-browser mode)...');
|
|
144
|
+
}
|
|
145
|
+
// Poll for tokens
|
|
146
|
+
try {
|
|
147
|
+
const tokens = await pollForTokens(discovery, deviceAuth.device_code, deviceAuth.interval, deviceAuth.expires_in);
|
|
148
|
+
// Save credentials
|
|
149
|
+
const entry = {
|
|
150
|
+
accessToken: tokens.access_token,
|
|
151
|
+
refreshToken: tokens.refresh_token,
|
|
152
|
+
expiresAt: new Date(Date.now() + tokens.expires_in * 1000).toISOString(),
|
|
153
|
+
};
|
|
154
|
+
setCredential(serverUrl, entry);
|
|
155
|
+
// Show identity
|
|
156
|
+
const payload = decodeJwtPayload(tokens.access_token);
|
|
157
|
+
console.log(`\nSuccessfully logged in as: ${payload.sub ?? 'unknown'}`);
|
|
158
|
+
console.log(`Token expires: ${entry.expiresAt}`);
|
|
159
|
+
}
|
|
160
|
+
catch (err) {
|
|
161
|
+
const message = err instanceof Error ? err.message : 'unknown error';
|
|
162
|
+
console.error(`\nLogin failed: ${message}`);
|
|
163
|
+
process.exit(1);
|
|
164
|
+
}
|
|
165
|
+
});
|
|
166
|
+
}
|
|
167
|
+
/**
|
|
168
|
+
* Create the logout command.
|
|
169
|
+
*/
|
|
170
|
+
export function createLogoutCommand() {
|
|
171
|
+
return new Command('logout')
|
|
172
|
+
.description('Log out from a server')
|
|
173
|
+
.argument('<server>', 'Server URL')
|
|
174
|
+
.action((server) => {
|
|
175
|
+
const serverUrl = normalizeServerUrl(server);
|
|
176
|
+
const removed = removeCredential(serverUrl);
|
|
177
|
+
if (removed) {
|
|
178
|
+
console.log(`Logged out from ${serverUrl}`);
|
|
179
|
+
}
|
|
180
|
+
else {
|
|
181
|
+
console.log(`Not logged in to ${serverUrl}`);
|
|
182
|
+
}
|
|
183
|
+
});
|
|
184
|
+
}
|
|
185
|
+
//# sourceMappingURL=auth.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"auth.js","sourceRoot":"","sources":["../../../src/commands/auth.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EACL,cAAc,EACd,eAAe,EACf,aAAa,EACb,aAAa,EACb,gBAAgB,EAChB,eAAe,EACf,aAAa,EACb,SAAS,EACT,gBAAgB,EAChB,kBAAkB,GAEnB,MAAM,mBAAmB,CAAC;AAE3B;;GAEG;AACH,KAAK,UAAU,WAAW,CAAC,GAAW;IACpC,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,oBAAoB,CAAC,CAAC;IACpD,MAAM,EAAE,QAAQ,EAAE,GAAG,MAAM,MAAM,CAAC,SAAS,CAAC,CAAC;IAE7C,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAA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AC,GAAG,CAAC,mBAAmB,SAAS,EAAE,CAAC,CAAC;QAC9C,CAAC;aAAM,CAAC;YACN,OAAO,CAAC,GAAG,CAAC,oBAAoB,SAAS,EAAE,CAAC,CAAC;QAC/C,CAAC;IACH,CAAC,CAAC,CAAC;AACP,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../../src/commands/get.ts"],"names":[],"mappings":"AAAA;;;GAGG;
|
|
1
|
+
{"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../../src/commands/get.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAgBH;;GAEG;AACH,wBAAsB,UAAU,CAC9B,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,MAAM,EAChB,OAAO,EAAE;IAAE,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,GAC3B,OAAO,CAAC,IAAI,CAAC,CAuEf"}
|
package/dist/src/commands/get.js
CHANGED
|
@@ -8,32 +8,50 @@
|
|
|
8
8
|
* Usage:
|
|
9
9
|
* e3 get . ws.path.to.dataset
|
|
10
10
|
* e3 get . ws.path.to.dataset -f json
|
|
11
|
+
* e3 get https://server/repos/myrepo ws.path.to.dataset
|
|
11
12
|
*/
|
|
12
|
-
import { workspaceGetDatasetHash, datasetRead } from '@elaraai/e3-core';
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
13
|
+
import { workspaceGetDatasetHash, datasetRead, LocalStorage } from '@elaraai/e3-core';
|
|
14
|
+
import { datasetGet as datasetGetRemote } from '@elaraai/e3-api-client';
|
|
15
|
+
import { printFor, toJSONFor, decodeBeast2, toEastTypeValue, isVariant } from '@elaraai/east';
|
|
16
|
+
import { parseRepoLocation, parseDatasetPath, formatError, exitError } from '../utils.js';
|
|
15
17
|
/**
|
|
16
18
|
* Get dataset value at a path.
|
|
17
19
|
*/
|
|
18
20
|
export async function getCommand(repoArg, pathSpec, options) {
|
|
19
21
|
try {
|
|
20
|
-
const
|
|
22
|
+
const location = await parseRepoLocation(repoArg);
|
|
21
23
|
const { ws, path } = parseDatasetPath(pathSpec);
|
|
22
24
|
if (path.length === 0) {
|
|
23
25
|
exitError('Path must include at least one field (e.g., ws.field)');
|
|
24
26
|
}
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
const format = options.format ?? 'east';
|
|
28
|
+
let type;
|
|
29
|
+
let value;
|
|
30
|
+
if (location.type === 'local') {
|
|
31
|
+
const storage = new LocalStorage();
|
|
32
|
+
// Get the hash first, then read with type info
|
|
33
|
+
const { refType, hash } = await workspaceGetDatasetHash(storage, location.path, ws, path);
|
|
34
|
+
if (refType === 'unassigned') {
|
|
35
|
+
exitError('Dataset is unassigned (pending task output)');
|
|
36
|
+
}
|
|
37
|
+
if (refType === 'null' || hash === null) {
|
|
38
|
+
console.log('null');
|
|
39
|
+
return;
|
|
40
|
+
}
|
|
41
|
+
// Read the dataset to get both value and type
|
|
42
|
+
const dataset = await datasetRead(storage, location.path, hash);
|
|
43
|
+
// Convert EastType to EastTypeValue if necessary
|
|
44
|
+
type = isVariant(dataset.type) ? dataset.type : toEastTypeValue(dataset.type);
|
|
45
|
+
value = dataset.value;
|
|
29
46
|
}
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
47
|
+
else {
|
|
48
|
+
// Remote: get raw BEAST2 bytes and decode
|
|
49
|
+
const beast2Data = await datasetGetRemote(location.baseUrl, location.repo, ws, path, { token: location.token });
|
|
50
|
+
// Decode BEAST2 to get type and value
|
|
51
|
+
const decoded = decodeBeast2(beast2Data);
|
|
52
|
+
type = decoded.type;
|
|
53
|
+
value = decoded.value;
|
|
33
54
|
}
|
|
34
|
-
// Read the dataset to get both value and type
|
|
35
|
-
const { type, value } = await datasetRead(repoPath, hash);
|
|
36
|
-
const format = options.format ?? 'east';
|
|
37
55
|
switch (format) {
|
|
38
56
|
case 'east': {
|
|
39
57
|
const printer = printFor(type);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get.js","sourceRoot":"","sources":["../../../src/commands/get.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH
|
|
1
|
+
{"version":3,"file":"get.js","sourceRoot":"","sources":["../../../src/commands/get.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;GAOG;AAEH,OAAO,EAAE,uBAAuB,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AACtF,OAAO,EAAE,UAAU,IAAI,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AACxE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,YAAY,EAAE,eAAe,EAAE,SAAS,EAAsB,MAAM,eAAe,CAAC;AAClH,OAAO,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAE1F;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,UAAU,CAC9B,OAAe,EACf,QAAgB,EAChB,OAA4B;IAE5B,IAAI,CAAC;QACH,MAAM,QAAQ,GAAG,MAAM,iBAAiB,CAAC,OAAO,CAAC,CAAC;QAClD,MAAM,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,gBAAgB,CAAC,QAAQ,CAAC,CAAC;QAEhD,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;YACtB,SAAS,CAAC,uDAAuD,CAAC,CAAC;QACrE,CAAC;QAED,MAAM,MAAM,GAAG,OAAO,CAAC,MAAM,IAAI,MAAM,CAAC;QAExC,IAAI,IAAmB,CAAC;QACxB,IAAI,KAAc,CAAC;QAEnB,IAAI,QAAQ,CAAC,IAAI,KAAK,OAAO,EAAE,CAAC;YAC9B,MAAM,OAAO,GAAG,IAAI,YAAY,EAAE,CAAC;YAEnC,+CAA+C;YAC/C,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,GAAG,MAAM,uBAAuB,CAAC,OAAO,EAAE,QAAQ,CAAC,IAAI,EAAE,EAAE,EAA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AS,CAAC,IAAI,CAAC,CAAC;gBAC/B,MAAM,SAAS,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC;gBAChC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,SAAS,CAAC,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;gBAChD,MAAM;YACR,CAAC;YACD,KAAK,QAAQ;gBACX,SAAS,CAAC,0DAA0D,CAAC,CAAC;gBACtE,MAAM;YACR;gBACE,SAAS,CAAC,mBAAmB,MAAM,2BAA2B,CAAC,CAAC;QACpE,CAAC;IACH,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,SAAS,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAC;IAC9B,CAAC;AACH,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list.d.ts","sourceRoot":"","sources":["../../../src/commands/list.ts"],"names":[],"mappings":"AAAA;;;GAGG;
|
|
1
|
+
{"version":3,"file":"list.d.ts","sourceRoot":"","sources":["../../../src/commands/list.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAwBH;;GAEG;AACH,wBAAsB,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAqFnF"}
|
|
@@ -10,35 +10,68 @@
|
|
|
10
10
|
* e3 list . ws # List root tree of workspace
|
|
11
11
|
* e3 list . ws.inputs # List fields under inputs
|
|
12
12
|
*/
|
|
13
|
-
import { workspaceList, workspaceListTree, workspaceGetState, } from '@elaraai/e3-core';
|
|
14
|
-
import {
|
|
13
|
+
import { workspaceList, workspaceListTree, workspaceGetState, LocalStorage, } from '@elaraai/e3-core';
|
|
14
|
+
import { workspaceList as workspaceListRemote, datasetList as datasetListRemote, datasetListAt as datasetListAtRemote, } from '@elaraai/e3-api-client';
|
|
15
|
+
import { parseRepoLocation, parseDatasetPath, formatError, exitError } from '../utils.js';
|
|
15
16
|
/**
|
|
16
17
|
* List workspaces or tree contents at a path.
|
|
17
18
|
*/
|
|
18
19
|
export async function listCommand(repoArg, pathSpec) {
|
|
19
20
|
try {
|
|
20
|
-
const
|
|
21
|
+
const location = await parseRepoLocation(repoArg);
|
|
21
22
|
// If no path, list workspaces
|
|
22
23
|
if (!pathSpec) {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
24
|
+
if (location.type === 'local') {
|
|
25
|
+
const storage = new LocalStorage();
|
|
26
|
+
const workspaces = await workspaceList(storage, location.path);
|
|
27
|
+
if (workspaces.length === 0) {
|
|
28
|
+
console.log('No workspaces');
|
|
29
|
+
return;
|
|
30
|
+
}
|
|
31
|
+
for (const ws of workspaces) {
|
|
32
|
+
const state = await workspaceGetState(storage, location.path, ws);
|
|
33
|
+
if (state) {
|
|
34
|
+
console.log(`${ws} (${state.packageName}@${state.packageVersion})`);
|
|
35
|
+
}
|
|
36
|
+
else {
|
|
37
|
+
console.log(`${ws} (not deployed)`);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
27
40
|
}
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
41
|
+
else {
|
|
42
|
+
// Remote: list workspaces
|
|
43
|
+
const workspaces = await workspaceListRemote(location.baseUrl, location.repo, { token: location.token });
|
|
44
|
+
if (workspaces.length === 0) {
|
|
45
|
+
console.log('No workspaces');
|
|
46
|
+
return;
|
|
32
47
|
}
|
|
33
|
-
|
|
34
|
-
|
|
48
|
+
for (const ws of workspaces) {
|
|
49
|
+
if (ws.deployed && ws.packageName.type === 'some' && ws.packageVersion.type === 'some') {
|
|
50
|
+
console.log(`${ws.name} (${ws.packageName.value}@${ws.packageVersion.value})`);
|
|
51
|
+
}
|
|
52
|
+
else {
|
|
53
|
+
console.log(`${ws.name} (not deployed)`);
|
|
54
|
+
}
|
|
35
55
|
}
|
|
36
56
|
}
|
|
37
57
|
return;
|
|
38
58
|
}
|
|
39
59
|
// Parse path and list tree contents
|
|
40
60
|
const { ws, path } = parseDatasetPath(pathSpec);
|
|
41
|
-
|
|
61
|
+
let fields;
|
|
62
|
+
if (location.type === 'local') {
|
|
63
|
+
const storage = new LocalStorage();
|
|
64
|
+
fields = await workspaceListTree(storage, location.path, ws, path);
|
|
65
|
+
}
|
|
66
|
+
else {
|
|
67
|
+
// Remote: list tree contents
|
|
68
|
+
if (path.length === 0) {
|
|
69
|
+
fields = await datasetListRemote(location.baseUrl, location.repo, ws, { token: location.token });
|
|
70
|
+
}
|
|
71
|
+
else {
|
|
72
|
+
fields = await datasetListAtRemote(location.baseUrl, location.repo, ws, path, { token: location.token });
|
|
73
|
+
}
|
|
74
|
+
}
|
|
42
75
|
if (fields.length === 0) {
|
|
43
76
|
console.log('(empty)');
|
|
44
77
|
return;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list.js","sourceRoot":"","sources":["../../../src/commands/list.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;GAOG;AAEH,OAAO,EACL,aAAa,EACb,iBAAiB,EACjB,iBAAiB,
|
|
1
|
+
{"version":3,"file":"list.js","sourceRoot":"","sources":["../../../src/commands/list.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;GAOG;AAEH,OAAO,EACL,aAAa,EACb,iBAAiB,EACjB,iBAAiB,EACjB,YAAY,GACb,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,aAAa,IAAI,mBAAmB,EACpC,WAAW,IAAI,iBAAiB,EAChC,aAAa,IAAI,mBAAmB,GACrC,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAE1F;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,WAAW,CAAC,OAAe,EAAE,QAAiB;IAClE,IAAI,CAAC;QACH,MAAM,QAAQ,GAAG,MAAM,iBAAiB,CAAC,OAAO,CAAC,CAAC;QAElD,8BAA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,CAAC,SAAS,CAAC,CAAC;YACvB,OAAO;QACT,CAAC;QAED,KAAK,MAAM,KAAK,IAAI,MAAM,EAAE,CAAC;YAC3B,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;QACrB,CAAC;IACH,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,SAAS,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAC;IAC9B,CAAC;AACH,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"logs.d.ts","sourceRoot":"","sources":["../../../src/commands/logs.ts"],"names":[],"mappings":"AAAA;;;GAGG;
|
|
1
|
+
{"version":3,"file":"logs.d.ts","sourceRoot":"","sources":["../../../src/commands/logs.ts"],"names":[],"mappings":"AAAA;;;GAGG;AA6RH;;GAEG;AACH,wBAAsB,WAAW,CAC/B,OAAO,EAAE,MAAM,EACf,QAAQ,CAAC,EAAE,MAAM,EACjB,OAAO,GAAE;IAAE,MAAM,CAAC,EAAE,OAAO,CAAA;CAAO,GACjC,OAAO,CAAC,IAAI,CAAC,CAgDf"}
|