@aglit-ai/cli 1.0.17136 → 1.0.17150

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/bin/aglit.cjs CHANGED
@@ -78,8 +78,8 @@ async function main() {
78
78
  const [command = 'init', email, connectionId] = positionals;
79
79
  const options = {
80
80
  models: ['device','fingerprint','name','json','challenge','code','connection','connections','model','harness','attempt','reauth'],
81
- install: ['json', 'channel'], init: ['name', 'provider', 'account', 'json', 'channel'],
82
- start: ['json', 'channel'], ui: ['json'], status: ['json'], update: ['check', 'channel', 'json'], updates: ['json'], enable: ['two-factor'], disable: [], rename: ['name', 'json'], console: ['json'], teams: ['json', 'open'], team: ['name', 'team', 'workspace', 'json'], pipelines: ['open', 'json'], providers: ['json'], invite: ['team'], uninstall: [],
81
+ install: ['json', 'channel'], init: ['name', 'provider', 'account', 'json', 'channel', 'headed', 'headless'],
82
+ start: ['json', 'channel', 'headed', 'headless'], ui: ['json'], status: ['json'], update: ['check', 'channel', 'json'], updates: ['json'], enable: ['two-factor'], disable: [], rename: ['name', 'json'], console: ['json'], teams: ['json', 'open'], team: ['name', 'team', 'workspace', 'json'], pipelines: ['open', 'json'], providers: ['json'], invite: ['team'], uninstall: [],
83
83
  };
84
84
  if (!Object.hasOwn(options, command) || Object.keys(values).some(key => !options[command].includes(key)) || positionals.length > (command === 'models' ? 3 : ['invite', 'updates'].includes(command) ? 2 : 1)) throw Error('Invalid command or options. Run aglit --help.');
85
85
  if (values['two-factor'] !== undefined && !['on', 'off'].includes(values['two-factor']))
@@ -264,17 +264,12 @@ async function main() {
264
264
  }
265
265
  state = await ui.step('Connect this computer to your account', async () => {
266
266
  await control('enable');
267
- const deadline = Date.now() + 30000;
268
- do {
269
- const current = await control('status');
270
- if (current.connected) return current;
271
- await delay(1000);
272
- } while (Date.now() < deadline);
273
- throw Error('Anywhere Access is enabled but its connection is not ready. Check aglit status before retrying.');
267
+ return control('status');
274
268
  });
275
269
  if (!installation.development) updates.rememberStatus(state);
276
270
  if (typeof state.deviceId !== 'string' || !state.deviceId) throw Error('Registration returned no device ID. Check aglit status before retrying.');
277
- state = { ...state, employeeUrl: `https://console.aglit.ai/employees/${encodeURIComponent(state.deviceId)}` };
271
+ state = { ...state, ...await control('window', { mode }) };
272
+ state = { ...state, employeeUrl: new URL(`/employees/${encodeURIComponent(state.deviceId)}`, state.consoleUrl).href };
278
273
  ui.result(state); ui.finish('Anywhere Access enabled'); return;
279
274
  }
280
275
  if (command === 'invite') { ui.result(await control('invite', { teamId: values.team, email })); ui.finish('Invitation sent'); return; }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aglit-ai/cli",
3
- "version": "1.0.17136",
3
+ "version": "1.0.17150",
4
4
  "description": "Install and manage Aglit Computer Use",
5
5
  "license": "UNLICENSED",
6
6
  "type": "commonjs",
package/src/ui.cjs CHANGED
@@ -11,7 +11,7 @@ async function createUi(interactive) {
11
11
  result: value => process.stdout.write(JSON.stringify(value, null, 2) + '\n'),
12
12
  info: message => process.stderr.write(message + '\n'),
13
13
  selection: (label, value) => process.stderr.write(label + ': ' + clean(value) + '\n'),
14
- permissions: () => process.stderr.write('In System Settings → Privacy & Security, enable Aglit Computer Use in Screen Recording and Accessibility. Keep each pane open until its permission is granted. Previously denied permissions must be enabled there manually.\n'),
14
+ permissions: () => process.stderr.write('In System Settings → Privacy & Security, enable Aglit AI in Screen Recording and Accessibility. Keep each pane open until its permission is granted. Previously denied permissions must be enabled there manually.\n'),
15
15
  browserExtension: value => process.stderr.write('In Chrome, open '+value.storeUrl+' and choose Add to Chrome. If installed but disabled, enable Aglit AI in chrome://extensions.\n'),
16
16
  finish() {},
17
17
  };
@@ -32,7 +32,7 @@ async function createUi(interactive) {
32
32
  provider: (providers, preferred) => answer(p.select({ message: 'Choose your AI provider', initialValue: preferred,
33
33
  options: providers.map(value => ({ value, label: value === 'codex' ? 'Codex' : 'Claude' })) })),
34
34
  selection: (label, value) => p.log.step(clean(label) + '\n' + clean(value)),
35
- permissions: () => p.note('Enable Aglit Computer Use in System Settings → Privacy & Security:\n1. Screen Recording (Screen & System Audio Recording on newer macOS)\n2. Accessibility\n\nSetup waits for each grant before opening the next pane.\nPreviously denied permissions must be enabled there manually.\nIf macOS asks you to quit and reopen Aglit Computer Use, do so and rerun aglit init.', 'Allow screen sharing and input'),
35
+ permissions: () => p.note('Enable Aglit AI in System Settings → Privacy & Security:\n1. Screen Recording (Screen & System Audio Recording on newer macOS)\n2. Accessibility\n\nSetup waits for each grant before opening the next pane.\nPreviously denied permissions must be enabled there manually.\nIf macOS asks you to quit and reopen Aglit AI, do so and rerun aglit init.', 'Allow screen sharing and input'),
36
36
  browserExtension: value => p.note('Open this listing in Chrome:\n' + clean(value.storeUrl) + '\n\nChoose Add to Chrome and approve the browser prompt.\nIf already installed but disabled, enable Aglit AI in chrome://extensions.\nSetup continues when the extension is installed and enabled.\nInstallation alone does not verify browser-control connectivity.', 'Add Aglit AI to Chrome'),
37
37
  teams(value) {
38
38
  const teams = teamsFromRoles(value);