@autohq/cli 0.1.125 → 0.1.126

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.
@@ -19791,7 +19791,6 @@ var AuthWhoamiResponseSchema = external_exports.object({
19791
19791
  });
19792
19792
  var SERVICE_ACCOUNT_READ_ONLY_SCOPES = [
19793
19793
  "environments:read",
19794
- "profiles:read",
19795
19794
  "tools:read",
19796
19795
  "sessions:read",
19797
19796
  "runs:read"
@@ -19801,7 +19800,6 @@ var SERVICE_ACCOUNT_SCOPE_PRESETS = {
19801
19800
  applier: [
19802
19801
  ...SERVICE_ACCOUNT_READ_ONLY_SCOPES,
19803
19802
  "environments:write",
19804
- "profiles:write",
19805
19803
  "tools:write",
19806
19804
  "sessions:write"
19807
19805
  ]
@@ -21140,7 +21138,6 @@ var ProjectServiceAccountListResponseSchema = external_exports.object({
21140
21138
  });
21141
21139
 
21142
21140
  // ../../packages/schemas/src/profiles.ts
21143
- var RESOURCE_KIND_PROFILE = "profile";
21144
21141
  var PROFILE_HARNESSES = ["claude-code"];
21145
21142
  var ProfileSpecSchema = external_exports.object({
21146
21143
  harness: external_exports.enum(PROFILE_HARNESSES),
@@ -21909,10 +21906,6 @@ var EnvironmentApplyDocumentSchema = resourceApplyDocumentSchema(
21909
21906
  RESOURCE_KIND_ENVIRONMENT,
21910
21907
  EnvironmentApplyRequestSchema.shape.spec
21911
21908
  );
21912
- var ProfileApplyDocumentSchema = resourceApplyDocumentSchema(
21913
- RESOURCE_KIND_PROFILE,
21914
- ProfileApplyRequestSchema.shape.spec
21915
- );
21916
21909
  var ToolApplyDocumentSchema = resourceApplyDocumentSchema(
21917
21910
  RESOURCE_KIND_TOOL,
21918
21911
  ToolApplyRequestSchema.shape.spec
@@ -21923,13 +21916,11 @@ var SessionApplyDocumentSchema = resourceApplyDocumentSchema(
21923
21916
  );
21924
21917
  var ProjectApplyResourceSchema = external_exports.discriminatedUnion("kind", [
21925
21918
  EnvironmentApplyDocumentSchema,
21926
- ProfileApplyDocumentSchema,
21927
21919
  ToolApplyDocumentSchema,
21928
21920
  SessionApplyDocumentSchema
21929
21921
  ]);
21930
21922
  var PROJECT_RESOURCE_APPLY_ORDER = [
21931
21923
  RESOURCE_KIND_ENVIRONMENT,
21932
- RESOURCE_KIND_PROFILE,
21933
21924
  RESOURCE_KIND_TOOL,
21934
21925
  RESOURCE_KIND_SESSION
21935
21926
  ];
@@ -21975,7 +21966,6 @@ var ProjectApplySystemConfigSchema = external_exports.object({
21975
21966
  });
21976
21967
  var ProjectAppliedResourceSchema = external_exports.union([
21977
21968
  EnvironmentResourceSchema,
21978
- ProfileResourceSchema,
21979
21969
  ToolResourceSchema,
21980
21970
  SessionResourceSchema
21981
21971
  ]);
@@ -21987,7 +21977,6 @@ var ProjectApplyDiagnosticSchema = external_exports.object({
21987
21977
  action: external_exports.enum(["create", "update", "unchanged"]),
21988
21978
  kind: external_exports.enum([
21989
21979
  RESOURCE_KIND_ENVIRONMENT,
21990
- RESOURCE_KIND_PROFILE,
21991
21980
  RESOURCE_KIND_TOOL,
21992
21981
  RESOURCE_KIND_SESSION
21993
21982
  ]),
@@ -22003,7 +21992,6 @@ var ProjectApplyResponseSchema = external_exports.object({
22003
21992
  action: external_exports.enum(["create", "update", "unchanged", "archive"]),
22004
21993
  kind: external_exports.enum([
22005
21994
  RESOURCE_KIND_ENVIRONMENT,
22006
- RESOURCE_KIND_PROFILE,
22007
21995
  RESOURCE_KIND_TOOL,
22008
21996
  RESOURCE_KIND_SESSION
22009
21997
  ]),
@@ -22015,7 +22003,6 @@ var ProjectApplyResponseSchema = external_exports.object({
22015
22003
  external_exports.object({
22016
22004
  kind: external_exports.enum([
22017
22005
  RESOURCE_KIND_ENVIRONMENT,
22018
- RESOURCE_KIND_PROFILE,
22019
22006
  RESOURCE_KIND_TOOL,
22020
22007
  RESOURCE_KIND_SESSION
22021
22008
  ]),
@@ -26294,7 +26281,7 @@ Object.assign(lookup, {
26294
26281
  // package.json
26295
26282
  var package_default = {
26296
26283
  name: "@autohq/cli",
26297
- version: "0.1.125",
26284
+ version: "0.1.126",
26298
26285
  license: "SEE LICENSE IN README.md",
26299
26286
  publishConfig: {
26300
26287
  access: "public"
package/dist/index.js CHANGED
@@ -16189,7 +16189,6 @@ var init_auth = __esm({
16189
16189
  });
16190
16190
  SERVICE_ACCOUNT_READ_ONLY_SCOPES = [
16191
16191
  "environments:read",
16192
- "profiles:read",
16193
16192
  "tools:read",
16194
16193
  "sessions:read",
16195
16194
  "runs:read"
@@ -16199,7 +16198,6 @@ var init_auth = __esm({
16199
16198
  applier: [
16200
16199
  ...SERVICE_ACCOUNT_READ_ONLY_SCOPES,
16201
16200
  "environments:write",
16202
- "profiles:write",
16203
16201
  "tools:write",
16204
16202
  "sessions:write"
16205
16203
  ]
@@ -17740,13 +17738,12 @@ var init_project_service_accounts = __esm({
17740
17738
  });
17741
17739
 
17742
17740
  // ../../packages/schemas/src/profiles.ts
17743
- var RESOURCE_KIND_PROFILE, PROFILE_HARNESSES, ProfileSpecSchema, ProfileResourceSchema, ProfileApplyRequestSchema;
17741
+ var PROFILE_HARNESSES, ProfileSpecSchema, ProfileResourceSchema, ProfileApplyRequestSchema;
17744
17742
  var init_profiles2 = __esm({
17745
17743
  "../../packages/schemas/src/profiles.ts"() {
17746
17744
  "use strict";
17747
17745
  init_zod();
17748
17746
  init_resources();
17749
- RESOURCE_KIND_PROFILE = "profile";
17750
17747
  PROFILE_HARNESSES = ["claude-code"];
17751
17748
  ProfileSpecSchema = external_exports.object({
17752
17749
  harness: external_exports.enum(PROFILE_HARNESSES),
@@ -18604,13 +18601,12 @@ var init_sessions = __esm({
18604
18601
  });
18605
18602
 
18606
18603
  // ../../packages/schemas/src/project-resources.ts
18607
- var EnvironmentApplyDocumentSchema, ProfileApplyDocumentSchema, ToolApplyDocumentSchema, SessionApplyDocumentSchema, ProjectApplyResourceSchema, PROJECT_RESOURCE_APPLY_ORDER, PROJECT_RESOURCE_KINDS, ProjectDeleteResourceSchema, AVATAR_ASSET_CONTENT_TYPES, MAX_AVATAR_ASSET_BASE64_LENGTH, ProjectApplyAssetSchema, ProjectApplyAssetsSchema, AvatarAssetUploadRequestSchema, AvatarAssetUploadResponseSchema, ProjectApplyRequestSchema, ProjectApplySystemConfigSchema, ProjectAppliedResourceSchema, ProjectApplyDiagnosticSchema, ProjectApplyResponseSchema;
18604
+ var EnvironmentApplyDocumentSchema, ToolApplyDocumentSchema, SessionApplyDocumentSchema, ProjectApplyResourceSchema, PROJECT_RESOURCE_APPLY_ORDER, PROJECT_RESOURCE_KINDS, ProjectDeleteResourceSchema, AVATAR_ASSET_CONTENT_TYPES, MAX_AVATAR_ASSET_BASE64_LENGTH, ProjectApplyAssetSchema, ProjectApplyAssetsSchema, AvatarAssetUploadRequestSchema, AvatarAssetUploadResponseSchema, ProjectApplyRequestSchema, ProjectApplySystemConfigSchema, ProjectAppliedResourceSchema, ProjectApplyDiagnosticSchema, ProjectApplyResponseSchema;
18608
18605
  var init_project_resources = __esm({
18609
18606
  "../../packages/schemas/src/project-resources.ts"() {
18610
18607
  "use strict";
18611
18608
  init_zod();
18612
18609
  init_environments();
18613
- init_profiles2();
18614
18610
  init_resources();
18615
18611
  init_sessions();
18616
18612
  init_tools();
@@ -18618,10 +18614,6 @@ var init_project_resources = __esm({
18618
18614
  RESOURCE_KIND_ENVIRONMENT,
18619
18615
  EnvironmentApplyRequestSchema.shape.spec
18620
18616
  );
18621
- ProfileApplyDocumentSchema = resourceApplyDocumentSchema(
18622
- RESOURCE_KIND_PROFILE,
18623
- ProfileApplyRequestSchema.shape.spec
18624
- );
18625
18617
  ToolApplyDocumentSchema = resourceApplyDocumentSchema(
18626
18618
  RESOURCE_KIND_TOOL,
18627
18619
  ToolApplyRequestSchema.shape.spec
@@ -18632,13 +18624,11 @@ var init_project_resources = __esm({
18632
18624
  );
18633
18625
  ProjectApplyResourceSchema = external_exports.discriminatedUnion("kind", [
18634
18626
  EnvironmentApplyDocumentSchema,
18635
- ProfileApplyDocumentSchema,
18636
18627
  ToolApplyDocumentSchema,
18637
18628
  SessionApplyDocumentSchema
18638
18629
  ]);
18639
18630
  PROJECT_RESOURCE_APPLY_ORDER = [
18640
18631
  RESOURCE_KIND_ENVIRONMENT,
18641
- RESOURCE_KIND_PROFILE,
18642
18632
  RESOURCE_KIND_TOOL,
18643
18633
  RESOURCE_KIND_SESSION
18644
18634
  ];
@@ -18684,7 +18674,6 @@ var init_project_resources = __esm({
18684
18674
  });
18685
18675
  ProjectAppliedResourceSchema = external_exports.union([
18686
18676
  EnvironmentResourceSchema,
18687
- ProfileResourceSchema,
18688
18677
  ToolResourceSchema,
18689
18678
  SessionResourceSchema
18690
18679
  ]);
@@ -18696,7 +18685,6 @@ var init_project_resources = __esm({
18696
18685
  action: external_exports.enum(["create", "update", "unchanged"]),
18697
18686
  kind: external_exports.enum([
18698
18687
  RESOURCE_KIND_ENVIRONMENT,
18699
- RESOURCE_KIND_PROFILE,
18700
18688
  RESOURCE_KIND_TOOL,
18701
18689
  RESOURCE_KIND_SESSION
18702
18690
  ]),
@@ -18712,7 +18700,6 @@ var init_project_resources = __esm({
18712
18700
  action: external_exports.enum(["create", "update", "unchanged", "archive"]),
18713
18701
  kind: external_exports.enum([
18714
18702
  RESOURCE_KIND_ENVIRONMENT,
18715
- RESOURCE_KIND_PROFILE,
18716
18703
  RESOURCE_KIND_TOOL,
18717
18704
  RESOURCE_KIND_SESSION
18718
18705
  ]),
@@ -18724,7 +18711,6 @@ var init_project_resources = __esm({
18724
18711
  external_exports.object({
18725
18712
  kind: external_exports.enum([
18726
18713
  RESOURCE_KIND_ENVIRONMENT,
18727
- RESOURCE_KIND_PROFILE,
18728
18714
  RESOURCE_KIND_TOOL,
18729
18715
  RESOURCE_KIND_SESSION
18730
18716
  ]),
@@ -19663,10 +19649,6 @@ function createResourceApi(context) {
19663
19649
  path: "/environments",
19664
19650
  applyResponseSchema: EnvironmentResourceSchema
19665
19651
  });
19666
- const profiles = projectResource(context, {
19667
- path: "/profiles",
19668
- applyResponseSchema: ProfileResourceSchema
19669
- });
19670
19652
  const sessions = projectResource(context, {
19671
19653
  path: "/sessions",
19672
19654
  applyResponseSchema: SessionApplyResponseSchema
@@ -19684,13 +19666,11 @@ function createResourceApi(context) {
19684
19666
  request,
19685
19667
  options ?? {}
19686
19668
  ),
19687
- applyProfileResource: profiles.apply,
19688
19669
  applySessionResource: sessions.apply,
19689
19670
  applyToolResource: tools.apply,
19690
19671
  createProjectServiceAccount: (request, options) => createProjectServiceAccount(context, request, options ?? {}),
19691
19672
  deleteProjectResource: (request, options) => deleteProjectResource(context, request, options ?? {}),
19692
19673
  listEnvironments: environments.list,
19693
- listProfiles: profiles.list,
19694
19674
  listProjectServiceAccounts: (options) => listProjectServiceAccounts(context, options ?? {}),
19695
19675
  listSessions: sessions.list,
19696
19676
  listTools: tools.list,
@@ -21195,33 +21175,6 @@ function createApiClient(input) {
21195
21175
  setActiveSelection(organizationId, projectId) {
21196
21176
  const config2 = readConfig(input.configPath);
21197
21177
  writeConfig({ ...config2, organizationId, projectId }, input.configPath);
21198
- },
21199
- async applySession(name, spec, options = {}) {
21200
- const project = await activeProject();
21201
- const response = await authenticatedFetch(
21202
- apiUrl(projectApiPath(project, "/sessions"), options.apiBaseUrl),
21203
- {
21204
- method: "POST",
21205
- headers: {
21206
- "content-type": "application/json"
21207
- },
21208
- body: JSON.stringify({
21209
- metadata: { name },
21210
- spec: {
21211
- profile: spec.profile ?? "default",
21212
- initialPrompt: spec.initialPrompt,
21213
- workingDirectory: spec.workingDirectory
21214
- }
21215
- })
21216
- },
21217
- options.apiBaseUrl
21218
- );
21219
- if (!response.ok) {
21220
- throw new Error(await responseErrorMessage(response));
21221
- }
21222
- const body = SessionApplyResponseSchema.parse(await response.json());
21223
- const resource = "resource" in body ? body.resource : body;
21224
- return { resource };
21225
21178
  }
21226
21179
  };
21227
21180
  }
@@ -21263,7 +21216,7 @@ var init_package = __esm({
21263
21216
  "package.json"() {
21264
21217
  package_default = {
21265
21218
  name: "@autohq/cli",
21266
- version: "0.1.125",
21219
+ version: "0.1.126",
21267
21220
  license: "SEE LICENSE IN README.md",
21268
21221
  publishConfig: {
21269
21222
  access: "public"
@@ -21843,13 +21796,11 @@ var init_files = __esm({
21843
21796
  init_src();
21844
21797
  APPLY_DIRECTORIES = {
21845
21798
  environment: "environments",
21846
- profile: "profiles",
21847
21799
  tool: "tools",
21848
21800
  session: "sessions"
21849
21801
  };
21850
21802
  APPLY_SCHEMAS = {
21851
21803
  environment: EnvironmentApplyRequestSchema,
21852
- profile: ProfileApplyRequestSchema,
21853
21804
  tool: ToolApplyRequestSchema,
21854
21805
  session: SessionApplyRequestSchema
21855
21806
  };
@@ -22021,8 +21972,6 @@ async function listProjectResources2(client, kind, options) {
22021
21972
  switch (kind) {
22022
21973
  case RESOURCE_KIND_ENVIRONMENT:
22023
21974
  return (await client.listEnvironments(options)).environments;
22024
- case RESOURCE_KIND_PROFILE:
22025
- return (await client.listProfiles(options)).profiles;
22026
21975
  case RESOURCE_KIND_TOOL:
22027
21976
  return (await client.listTools(options)).tools;
22028
21977
  case RESOURCE_KIND_SESSION:
@@ -22051,12 +22000,6 @@ var init_resources3 = __esm({
22051
22000
  label: "Environment",
22052
22001
  pluralLabel: "Environments"
22053
22002
  },
22054
- [RESOURCE_KIND_PROFILE]: {
22055
- kind: RESOURCE_KIND_PROFILE,
22056
- section: "profiles",
22057
- label: "Profile",
22058
- pluralLabel: "Profiles"
22059
- },
22060
22003
  [RESOURCE_KIND_TOOL]: {
22061
22004
  kind: RESOURCE_KIND_TOOL,
22062
22005
  section: "tools",
@@ -22072,7 +22015,6 @@ var init_resources3 = __esm({
22072
22015
  };
22073
22016
  PROJECT_RESOURCE_TUI_ORDER = [
22074
22017
  RESOURCE_KIND_SESSION,
22075
- RESOURCE_KIND_PROFILE,
22076
22018
  RESOURCE_KIND_ENVIRONMENT,
22077
22019
  RESOURCE_KIND_TOOL
22078
22020
  ];
@@ -24465,36 +24407,9 @@ var init_ProjectsView = __esm({
24465
24407
  // src/tui/ResourceViews.tsx
24466
24408
  import { Box as Box9, Text as Text9, useStdout as useStdout4 } from "ink";
24467
24409
  import { jsx as jsx9, jsxs as jsxs8 } from "react/jsx-runtime";
24468
- function ProfilesView({
24469
- resources,
24470
- selectedIndex,
24471
- error: error51
24472
- }) {
24473
- return /* @__PURE__ */ jsx9(
24474
- ResourceTable,
24475
- {
24476
- rows: resources.map((profile) => ({
24477
- id: profile.metadata.uid,
24478
- name: profile.metadata.name,
24479
- kind: profile.spec.harness,
24480
- target: profile.spec.environment,
24481
- detail: profile.spec.instructions?.replace(/\s+/g, " ").trim() ?? "",
24482
- updatedAt: profile.metadata.updatedAt
24483
- })),
24484
- selectedIndex,
24485
- error: error51,
24486
- empty: "no profiles found",
24487
- kindHeader: "HARNESS",
24488
- targetHeader: "ENVIRONMENT",
24489
- detailHeader: "INSTRUCTIONS",
24490
- flexColumn: "detail"
24491
- }
24492
- );
24493
- }
24494
24410
  function EnvironmentsView({
24495
24411
  resources,
24496
24412
  selectedIndex,
24497
- selectedProfile,
24498
24413
  error: error51
24499
24414
  }) {
24500
24415
  return /* @__PURE__ */ jsx9(
@@ -24509,7 +24424,7 @@ function EnvironmentsView({
24509
24424
  name: environment.metadata.name,
24510
24425
  kind: environment.spec.image.name,
24511
24426
  target: envEntries.map(([name, value]) => `${name}:${envValueKind(value)}`).join(", "),
24512
- detail: selectedProfile?.spec.environment === environment.metadata.name ? `profile:${selectedProfile.metadata.name}` : "",
24427
+ detail: "",
24513
24428
  updatedAt: environment.metadata.updatedAt
24514
24429
  };
24515
24430
  }),
@@ -24738,10 +24653,6 @@ function useEnvironments(apiUrl) {
24738
24653
  const client = useApiClient();
24739
24654
  return useQuery(environmentsQueryOptions(client, apiUrl));
24740
24655
  }
24741
- function useProfiles(apiUrl) {
24742
- const client = useApiClient();
24743
- return useQuery(profilesQueryOptions(client, apiUrl));
24744
- }
24745
24656
  function useTools(apiUrl) {
24746
24657
  const client = useApiClient();
24747
24658
  return useQuery(toolsQueryOptions(client, apiUrl));
@@ -24816,7 +24727,6 @@ function useSwitchProject() {
24816
24727
  onSuccess: () => {
24817
24728
  for (const queryKey of [
24818
24729
  ["sessions"],
24819
- ["profiles"],
24820
24730
  ["environments"],
24821
24731
  ["tools"],
24822
24732
  ["service-accounts"],
@@ -25020,16 +24930,6 @@ function environmentsQueryOptions(client, apiUrl) {
25020
24930
  staleTime: Number.POSITIVE_INFINITY
25021
24931
  });
25022
24932
  }
25023
- function profilesQueryOptions(client, apiUrl) {
25024
- return queryOptions({
25025
- queryKey: queryKeys.profiles(apiUrl),
25026
- queryFn: async () => {
25027
- const res = await client.listProfiles({ apiBaseUrl: apiUrl });
25028
- return sortByName(res.profiles);
25029
- },
25030
- staleTime: Number.POSITIVE_INFINITY
25031
- });
25032
- }
25033
24933
  function sessionsQueryOptions(client, apiUrl) {
25034
24934
  return queryOptions({
25035
24935
  queryKey: queryKeys.sessions(apiUrl),
@@ -25096,7 +24996,7 @@ function connectionProvidersQueryOptions(client, apiUrl, enabled = true) {
25096
24996
  }
25097
24997
  function sortSessions(list) {
25098
24998
  return list.slice().sort(
25099
- (a, b) => (a.spec.profile ?? "").localeCompare(b.spec.profile ?? "") || a.metadata.name.localeCompare(b.metadata.name)
24999
+ (a, b) => (a.spec.environment ?? "").localeCompare(b.spec.environment ?? "") || a.metadata.name.localeCompare(b.metadata.name)
25100
25000
  );
25101
25001
  }
25102
25002
  function sortByName(list) {
@@ -25125,7 +25025,6 @@ var init_queries = __esm({
25125
25025
  TUI_RUN_LIST_LIMIT = 200;
25126
25026
  queryKeys = {
25127
25027
  environments: (apiUrl) => ["environments", apiUrl],
25128
- profiles: (apiUrl) => ["profiles", apiUrl],
25129
25028
  sessions: (apiUrl) => ["sessions", apiUrl],
25130
25029
  tools: (apiUrl) => ["tools", apiUrl],
25131
25030
  projects: (apiUrl) => ["projects", apiUrl],
@@ -25590,8 +25489,6 @@ function selectedNamedResourceForSection(input) {
25590
25489
  switch (input.activeSection) {
25591
25490
  case "environments":
25592
25491
  return input.selectedEnvironment ?? null;
25593
- case "profiles":
25594
- return input.selectedProfile ?? null;
25595
25492
  case "sessions":
25596
25493
  return input.selectedSession ?? null;
25597
25494
  case "tools":
@@ -25633,7 +25530,6 @@ function HomeView({ apiUrl, notice, returnToSession }) {
25633
25530
  returnToSession ? "runs" : "sessions"
25634
25531
  );
25635
25532
  const [sessionIndex, setSessionIndex] = useState3(0);
25636
- const [profileIndex, setProfileIndex] = useState3(0);
25637
25533
  const [environmentIndex, setEnvironmentIndex] = useState3(0);
25638
25534
  const [toolIndex, setToolIndex] = useState3(0);
25639
25535
  const [projectIndex, setProjectIndex] = useState3(0);
@@ -25665,11 +25561,6 @@ function HomeView({ apiUrl, notice, returnToSession }) {
25665
25561
  isLoading,
25666
25562
  error: sessionsError
25667
25563
  } = useSessions(apiUrl);
25668
- const {
25669
- data: profiles = [],
25670
- isLoading: isProfilesLoading,
25671
- error: profilesError
25672
- } = useProfiles(apiUrl);
25673
25564
  const {
25674
25565
  data: environments = [],
25675
25566
  isLoading: isEnvironmentsLoading,
@@ -25766,14 +25657,12 @@ function HomeView({ apiUrl, notice, returnToSession }) {
25766
25657
  const selectedConnectionProvider = providerRows2(connectionProviders)[connectionProviderIndex];
25767
25658
  const selectedServiceAccount = serviceAccounts[serviceAccountIndex];
25768
25659
  const selectedSession = sessions[sessionIndex];
25769
- const selectedProfile = profiles[profileIndex];
25770
25660
  const selectedEnvironment = environments[environmentIndex];
25771
25661
  const selectedTool = tools[toolIndex];
25772
25662
  const selectedInspectableResource = useMemo3(() => {
25773
25663
  const selectedEditable = editableResourceForSelection({
25774
25664
  activeSection,
25775
25665
  selectedEnvironment,
25776
- selectedProfile,
25777
25666
  selectedSession,
25778
25667
  selectedTool
25779
25668
  });
@@ -25787,12 +25676,6 @@ function HomeView({ apiUrl, notice, returnToSession }) {
25787
25676
  name: selectedEditable.name,
25788
25677
  spec: selectedSession.spec
25789
25678
  } : null;
25790
- case "profiles":
25791
- return selectedProfile ? {
25792
- kind: selectedEditable.kind,
25793
- name: selectedEditable.name,
25794
- spec: selectedProfile.spec
25795
- } : null;
25796
25679
  case "environments":
25797
25680
  return selectedEnvironment ? {
25798
25681
  kind: selectedEditable.kind,
@@ -25808,28 +25691,15 @@ function HomeView({ apiUrl, notice, returnToSession }) {
25808
25691
  default:
25809
25692
  return null;
25810
25693
  }
25811
- }, [
25812
- activeSection,
25813
- selectedEnvironment,
25814
- selectedProfile,
25815
- selectedSession,
25816
- selectedTool
25817
- ]);
25694
+ }, [activeSection, selectedEnvironment, selectedSession, selectedTool]);
25818
25695
  const selectedEditableResource = useMemo3(
25819
25696
  () => editableResourceForSelection({
25820
25697
  activeSection,
25821
25698
  selectedEnvironment,
25822
- selectedProfile,
25823
25699
  selectedSession,
25824
25700
  selectedTool
25825
25701
  }),
25826
- [
25827
- activeSection,
25828
- selectedEnvironment,
25829
- selectedProfile,
25830
- selectedSession,
25831
- selectedTool
25832
- ]
25702
+ [activeSection, selectedEnvironment, selectedSession, selectedTool]
25833
25703
  );
25834
25704
  const inspectPanelHeight = Math.max(1, termHeight - 12);
25835
25705
  const scopedSession = runScopeSessionName ? sessions.find((session) => session.metadata.name === runScopeSessionName) : void 0;
@@ -25865,22 +25735,13 @@ function HomeView({ apiUrl, notice, returnToSession }) {
25865
25735
  });
25866
25736
  }, [visibleRunIdKey]);
25867
25737
  useEffect3(() => {
25868
- if (!selectedSession?.spec.profile) return;
25869
- const index = profiles.findIndex(
25870
- (profile) => profile.metadata.name === selectedSession.spec.profile
25871
- );
25872
- if (index >= 0) setProfileIndex(index);
25873
- }, [profiles, selectedSession]);
25874
- useEffect3(() => {
25875
- const environmentName = selectedProfile?.spec.environment ?? selectedSession?.spec.environment ?? profiles.find(
25876
- (profile) => profile.metadata.name === selectedSession?.spec.profile
25877
- )?.spec.environment;
25738
+ const environmentName = selectedSession?.spec.environment;
25878
25739
  if (!environmentName) return;
25879
25740
  const index = environments.findIndex(
25880
25741
  (environment) => environment.metadata.name === environmentName
25881
25742
  );
25882
25743
  if (index >= 0) setEnvironmentIndex(index);
25883
- }, [environments, profiles, selectedProfile, selectedSession]);
25744
+ }, [environments, selectedSession]);
25884
25745
  useEffect3(() => {
25885
25746
  const sessionToolRefs = selectedSession ? Object.values(selectedSession.spec.tools).flatMap((tool) => {
25886
25747
  if ("ref" in tool) {
@@ -26422,20 +26283,6 @@ function HomeView({ apiUrl, notice, returnToSession }) {
26422
26283
  return;
26423
26284
  }
26424
26285
  }
26425
- if (activeSection === "profiles") {
26426
- if (key.upArrow) {
26427
- setProfileIndex((i) => Math.max(0, i - 1));
26428
- return;
26429
- }
26430
- if (key.downArrow) {
26431
- setProfileIndex((i) => clampListIndex(i + 1, profiles.length));
26432
- return;
26433
- }
26434
- if (key.return && selectedProfile) {
26435
- setSection("environments");
26436
- return;
26437
- }
26438
- }
26439
26286
  if (activeSection === "environments") {
26440
26287
  if (key.upArrow) {
26441
26288
  setEnvironmentIndex((i) => Math.max(0, i - 1));
@@ -26735,11 +26582,10 @@ function HomeView({ apiUrl, notice, returnToSession }) {
26735
26582
  case "serviceAccounts":
26736
26583
  sectionTitle = `Service Accounts[${serviceAccounts.length}]`;
26737
26584
  break;
26738
- case "profiles":
26739
26585
  case "environments":
26740
26586
  case "tools": {
26741
26587
  const definition = PROJECT_RESOURCE_TUI_DEFINITIONS_BY_SECTION.get(activeSection);
26742
- const count = activeSection === "profiles" ? profiles.length : activeSection === "environments" ? environments.length : tools.length;
26588
+ const count = activeSection === "environments" ? environments.length : tools.length;
26743
26589
  sectionTitle = `${definition?.pluralLabel ?? activeSection}[${count}]`;
26744
26590
  break;
26745
26591
  }
@@ -26828,7 +26674,6 @@ function HomeView({ apiUrl, notice, returnToSession }) {
26828
26674
  {
26829
26675
  keys: [
26830
26676
  ...isApplyResourceSection(activeSection) || activeSection === "serviceAccounts" ? [{ k: "\u2191\u2193", label: "Navigate" }] : [],
26831
- ...activeSection === "profiles" ? [{ k: "enter", label: "Environment" }] : [],
26832
26677
  ...isApplyResourceSection(activeSection) ? [
26833
26678
  { k: "i", label: "Inspect" },
26834
26679
  { k: "e", label: "Edit" }
@@ -26903,21 +26748,11 @@ function HomeView({ apiUrl, notice, returnToSession }) {
26903
26748
  scrollOffset: inspectScrollOffset,
26904
26749
  height: inspectPanelHeight
26905
26750
  }
26906
- ) : activeSection === "profiles" ? isProfilesLoading ? /* @__PURE__ */ jsx14(Box13, { padding: 2, children: /* @__PURE__ */ jsx14(Spinner, { label: "loading profiles\u2026" }) }) : /* @__PURE__ */ jsx14(
26907
- ProfilesView,
26908
- {
26909
- resources: profiles,
26910
- selectedIndex: profileIndex,
26911
- selectedSession,
26912
- selectedEnvironmentName: selectedEnvironment?.metadata.name,
26913
- error: profilesError instanceof Error ? profilesError.message : profilesError ? String(profilesError) : null
26914
- }
26915
26751
  ) : activeSection === "environments" ? isEnvironmentsLoading ? /* @__PURE__ */ jsx14(Box13, { padding: 2, children: /* @__PURE__ */ jsx14(Spinner, { label: "loading environments\u2026" }) }) : /* @__PURE__ */ jsx14(
26916
26752
  EnvironmentsView,
26917
26753
  {
26918
26754
  resources: environments,
26919
26755
  selectedIndex: environmentIndex,
26920
- selectedProfile,
26921
26756
  selectedSession,
26922
26757
  error: environmentsError instanceof Error ? environmentsError.message : environmentsError ? String(environmentsError) : null
26923
26758
  }
@@ -27033,7 +26868,7 @@ function HomeView({ apiUrl, notice, returnToSession }) {
27033
26868
  /* @__PURE__ */ jsx14(Text14, { dimColor: true, children: ` ${inspectedResource.name} ` }),
27034
26869
  /* @__PURE__ */ jsx14(Text14, { dimColor: true, children: "\u203A" }),
27035
26870
  /* @__PURE__ */ jsx14(Text14, { backgroundColor: "cyan", color: "black", children: " inspect " })
27036
- ] }) : (activeSection === "projects" || activeSection === "profiles" || activeSection === "environments" || activeSection === "tools" || activeSection === "serviceAccounts" || activeSection === "connections") && /* @__PURE__ */ jsx14(
26871
+ ] }) : (activeSection === "projects" || activeSection === "environments" || activeSection === "tools" || activeSection === "serviceAccounts" || activeSection === "connections") && /* @__PURE__ */ jsx14(
27037
26872
  Text14,
27038
26873
  {
27039
26874
  backgroundColor: "cyan",
@@ -27090,9 +26925,7 @@ function ActionKey({ k, label }) {
27090
26925
  /* @__PURE__ */ jsx14(Box13, { width: 10, children: /* @__PURE__ */ jsx14(Text14, { dimColor: true, children: fitToWidth(label, 10) }) })
27091
26926
  ] });
27092
26927
  }
27093
- function ActionKeyColumns({
27094
- keys
27095
- }) {
26928
+ function ActionKeyColumns({ keys }) {
27096
26929
  const columns = chunkActionKeys(keys, 4);
27097
26930
  return /* @__PURE__ */ jsx14(Box13, { gap: 1, children: columns.map((column) => /* @__PURE__ */ jsx14(Box13, { flexDirection: "column", children: column.map(({ k, label }) => /* @__PURE__ */ jsx14(ActionKey, { k, label }, k)) }, column.map(({ k }) => k).join("-"))) });
27098
26931
  }
@@ -27274,12 +27107,11 @@ var init_HomeView = __esm({
27274
27107
  DASHBOARD_NAV_ITEMS = [
27275
27108
  resourceNavItem({ k: "1", section: "sessions" }),
27276
27109
  { k: "2", label: "Runs", activeSection: "runs" },
27277
- resourceNavItem({ k: "3", section: "profiles" }),
27278
- resourceNavItem({ k: "4", section: "environments" }),
27279
- resourceNavItem({ k: "5", section: "tools" }),
27280
- { k: "6", label: "Projects", activeSection: "projects" },
27281
- { k: "7", label: "Service Accounts", activeSection: "serviceAccounts" },
27282
- { k: "8", label: "Connections", activeSection: "connections" }
27110
+ resourceNavItem({ k: "3", section: "environments" }),
27111
+ resourceNavItem({ k: "4", section: "tools" }),
27112
+ { k: "5", label: "Projects", activeSection: "projects" },
27113
+ { k: "6", label: "Service Accounts", activeSection: "serviceAccounts" },
27114
+ { k: "7", label: "Connections", activeSection: "connections" }
27283
27115
  ];
27284
27116
  RESOURCES_PER_COLUMN = 4;
27285
27117
  }
@@ -27535,13 +27367,6 @@ var init_launcher = __esm({
27535
27367
  queryKey: queryKeys.environments,
27536
27368
  sort: sortByResourceName
27537
27369
  },
27538
- [RESOURCE_KIND_PROFILE]: {
27539
- async list({ apiClient, apiUrl }) {
27540
- return (await apiClient.listProfiles({ apiBaseUrl: apiUrl })).profiles;
27541
- },
27542
- queryKey: queryKeys.profiles,
27543
- sort: sortByResourceName
27544
- },
27545
27370
  [RESOURCE_KIND_TOOL]: {
27546
27371
  async list({ apiClient, apiUrl }) {
27547
27372
  return (await apiClient.listTools({ apiBaseUrl: apiUrl })).tools;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@autohq/cli",
3
- "version": "0.1.125",
3
+ "version": "0.1.126",
4
4
  "license": "SEE LICENSE IN README.md",
5
5
  "publishConfig": {
6
6
  "access": "public"