nomoreide 0.1.100 → 0.1.101
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/dist/core/agent-profiles/index.d.ts +3 -2
- package/dist/core/agent-profiles/index.js +2 -1
- package/dist/core/agent-profiles/index.js.map +1 -1
- package/dist/core/agent-profiles/publication.d.ts +105 -0
- package/dist/core/agent-profiles/publication.js +126 -0
- package/dist/core/agent-profiles/publication.js.map +1 -0
- package/dist/core/agent-profiles/registry-client.d.ts +32 -0
- package/dist/core/agent-profiles/registry-client.js +12 -0
- package/dist/core/agent-profiles/registry-client.js.map +1 -1
- package/dist/core/agent-profiles/registry-transfer.js +13 -1
- package/dist/core/agent-profiles/registry-transfer.js.map +1 -1
- package/dist/core/agent-profiles/store.d.ts +15 -0
- package/dist/core/agent-profiles/store.js +139 -5
- package/dist/core/agent-profiles/store.js.map +1 -1
- package/dist/core/agent-profiles/transfer.js +36 -24
- package/dist/core/agent-profiles/transfer.js.map +1 -1
- package/dist/core/agent-profiles/types.d.ts +13 -6
- package/dist/core/agent-profiles/types.js.map +1 -1
- package/dist/core/app-settings.d.ts +7 -0
- package/dist/core/app-settings.js +6 -0
- package/dist/core/app-settings.js.map +1 -1
- package/dist/core/context-library.d.ts +53 -0
- package/dist/core/context-library.js +510 -0
- package/dist/core/context-library.js.map +1 -0
- package/dist/core/context-types.d.ts +83 -0
- package/dist/core/context-types.js +9 -0
- package/dist/core/context-types.js.map +1 -0
- package/dist/core/daemon-client.d.ts +4 -0
- package/dist/core/daemon-client.js +18 -3
- package/dist/core/daemon-client.js.map +1 -1
- package/dist/core/db/sqlite-driver.d.ts +1 -0
- package/dist/core/db/sqlite-driver.js +35 -19
- package/dist/core/db/sqlite-driver.js.map +1 -1
- package/dist/core/external-terminal.d.ts +60 -0
- package/dist/core/external-terminal.js +429 -0
- package/dist/core/external-terminal.js.map +1 -0
- package/dist/core/ssh-setup.d.ts +11 -0
- package/dist/core/ssh-setup.js +49 -0
- package/dist/core/ssh-setup.js.map +1 -0
- package/dist/core/terminal-manager.d.ts +40 -0
- package/dist/core/terminal-manager.js +320 -11
- package/dist/core/terminal-manager.js.map +1 -1
- package/dist/core/terminal-session.d.ts +4 -3
- package/dist/core/terminal-session.js +33 -4
- package/dist/core/terminal-session.js.map +1 -1
- package/dist/index.js +13 -1
- package/dist/index.js.map +1 -1
- package/dist/mcp/tools/index.d.ts +1 -1
- package/dist/mcp/tools/index.js +3 -0
- package/dist/mcp/tools/index.js.map +1 -1
- package/dist/mcp/tools/terminal.d.ts +4 -0
- package/dist/mcp/tools/terminal.js +38 -0
- package/dist/mcp/tools/terminal.js.map +1 -0
- package/dist/web/client/assets/{code-editor-DFOGG6ys.js → code-editor-rHWIXkKg.js} +1 -1
- package/dist/web/client/assets/context-graph-CcfJNAob.js +7 -0
- package/dist/web/client/assets/index-BnFtcUqj.js +352 -0
- package/dist/web/client/assets/index-CqsghUD9.css +1 -0
- package/dist/web/client/assets/system-process-table-S4umMSEK.js +1 -0
- package/dist/web/client/index.html +2 -2
- package/dist/web/http-utils.d.ts +4 -1
- package/dist/web/http-utils.js +12 -2
- package/dist/web/http-utils.js.map +1 -1
- package/dist/web/routes/agent-profile-routes.js +19 -1
- package/dist/web/routes/agent-profile-routes.js.map +1 -1
- package/dist/web/routes/agent-registry-routes.js +68 -2
- package/dist/web/routes/agent-registry-routes.js.map +1 -1
- package/dist/web/routes/context-library-routes.d.ts +2 -0
- package/dist/web/routes/context-library-routes.js +139 -0
- package/dist/web/routes/context-library-routes.js.map +1 -0
- package/dist/web/routes/context.d.ts +2 -0
- package/dist/web/routes/context.js.map +1 -1
- package/dist/web/routes/index.js +2 -0
- package/dist/web/routes/index.js.map +1 -1
- package/dist/web/routes/shell-routes.js +1 -0
- package/dist/web/routes/shell-routes.js.map +1 -1
- package/dist/web/routes/ssh-server-routes.js +20 -0
- package/dist/web/routes/ssh-server-routes.js.map +1 -1
- package/dist/web/routes/terminal-routes.js +158 -3
- package/dist/web/routes/terminal-routes.js.map +1 -1
- package/dist/web/server.d.ts +1 -0
- package/dist/web/server.js +30 -8
- package/dist/web/server.js.map +1 -1
- package/package.json +2 -1
- package/dist/core/service-detect.d.ts +0 -19
- package/dist/core/service-detect.js +0 -141
- package/dist/core/service-detect.js.map +0 -1
- package/dist/mcp/tools.d.ts +0 -19
- package/dist/mcp/tools.js +0 -354
- package/dist/mcp/tools.js.map +0 -1
- package/dist/web/client/assets/index-BG_E_64s.css +0 -1
- package/dist/web/client/assets/index-CYgm7PZW.js +0 -346
- package/dist/web/client/assets/system-process-table-B9uNpXW9.js +0 -1
- package/dist/web/ui-lifecycle.d.ts +0 -30
- package/dist/web/ui-lifecycle.js +0 -129
- package/dist/web/ui-lifecycle.js.map +0 -1
|
@@ -7,11 +7,12 @@ export { applyProfile, applyProfileContents, previewProfileApply, type ProfileCo
|
|
|
7
7
|
export { loadBundledDebugProfile, NOMOREIDE_DEBUG_PROFILE_NAME, type BundledAgentProfile, } from "./builtin.js";
|
|
8
8
|
export { DebugSetupConflictError, installBundledDebugSetup, type DebugSetupAgent, type DebugSetupResult, type DebugSetupStatus, } from "./debug-setup.js";
|
|
9
9
|
export { findUnresolvedCredentialKeys, redactMcpCredentials, resolveMcpCredentials, } from "./credentials.js";
|
|
10
|
-
export { assertValidProfileName, copySkillBetweenProfiles, copyPluginBetweenProfiles, createProfile, deleteProfile, getProfile, listProfiles, profileDir, profilePluginsDir, profilesRoot, profileSkillsDir, refreshProfileFromAgent, snapshotProfileFromAgent, updateProfile, writeProfile, type ProfileStoreOptions, } from "./store.js";
|
|
10
|
+
export { assertValidProfileName, copySkillBetweenProfiles, copyPluginBetweenProfiles, clearProfileRegistryLink, createProfile, deleteProfile, getProfile, getProfileRegistryDiff, listProfiles, profileDir, profilePluginsDir, profilesRoot, profileSkillsDir, refreshProfileFromAgent, readProfileRegistryLink, snapshotProfileFromAgent, updateProfile, writeProfile, writeProfileRegistryLink, type ProfileStoreOptions, } from "./store.js";
|
|
11
|
+
export { createProfileRegistrySnapshot, diffProfileRegistrySnapshots, profileRegistryLinkSchema, profileRegistrySnapshotSchema, type ProfileRegistryDiff, type ProfileRegistryItemDiff, type ProfileRegistryLink, type ProfileRegistrySnapshot, } from "./publication.js";
|
|
11
12
|
export { exportProfile, importProfile, type ExportResult, type ImportResult } from "./transfer.js";
|
|
12
13
|
export { createRegistryConfigService, DEFAULT_REGISTRY_API_BASE_URL, DEFAULT_REGISTRY_FRONTEND_URL, registryConfigPath, resolveRegistryApiBaseUrl, resolveRegistryApiTarget, resolveRegistryApiToken, resolveRegistryFrontendUrl, type RegistryApiTarget, type RegistryConfigOptions, type RegistryConfigService, } from "./registry-config.js";
|
|
13
14
|
export { createRegistryTokenManager, type RegistryTokenManager, type RegistryTokenManagerOptions, } from "./registry-auth.js";
|
|
14
|
-
export { createRegistryClient, type RegisterGithubProfileInput, type RegistryClient, type RegistryInstallDescriptor, type RegistryProfile, } from "./registry-client.js";
|
|
15
|
+
export { createRegistryClient, type RegisterGithubProfileInput, type RegistryClient, type RegistryInstallDescriptor, type RegistryProfile, type RegistryProfileSort, type RegistryPublicProfile, } from "./registry-client.js";
|
|
15
16
|
export { installProfileFromRegistry, publishProfileToRegistry, type InstallFromRegistryInput, type InstallFromRegistryResult, type PublishProfileInput, type PublishProfileResult, } from "./registry-transfer.js";
|
|
16
17
|
export { PROFILE_NAME_PATTERN, profileManifestSchema, profileMcpSchema, profilePluginSchema, profileSchema, slugifyProfileName, type CredentialSpec, type Profile, type ProfileManifest, type ProfileMcp, type ProfilePlugin, type ProfileSummary, } from "./types.js";
|
|
17
18
|
export { pluginIdentity } from "./plugin-bundle.js";
|
|
@@ -7,7 +7,8 @@ export { applyProfile, applyProfileContents, previewProfileApply, } from "./appl
|
|
|
7
7
|
export { loadBundledDebugProfile, NOMOREIDE_DEBUG_PROFILE_NAME, } from "./builtin.js";
|
|
8
8
|
export { DebugSetupConflictError, installBundledDebugSetup, } from "./debug-setup.js";
|
|
9
9
|
export { findUnresolvedCredentialKeys, redactMcpCredentials, resolveMcpCredentials, } from "./credentials.js";
|
|
10
|
-
export { assertValidProfileName, copySkillBetweenProfiles, copyPluginBetweenProfiles, createProfile, deleteProfile, getProfile, listProfiles, profileDir, profilePluginsDir, profilesRoot, profileSkillsDir, refreshProfileFromAgent, snapshotProfileFromAgent, updateProfile, writeProfile, } from "./store.js";
|
|
10
|
+
export { assertValidProfileName, copySkillBetweenProfiles, copyPluginBetweenProfiles, clearProfileRegistryLink, createProfile, deleteProfile, getProfile, getProfileRegistryDiff, listProfiles, profileDir, profilePluginsDir, profilesRoot, profileSkillsDir, refreshProfileFromAgent, readProfileRegistryLink, snapshotProfileFromAgent, updateProfile, writeProfile, writeProfileRegistryLink, } from "./store.js";
|
|
11
|
+
export { createProfileRegistrySnapshot, diffProfileRegistrySnapshots, profileRegistryLinkSchema, profileRegistrySnapshotSchema, } from "./publication.js";
|
|
11
12
|
export { exportProfile, importProfile } from "./transfer.js";
|
|
12
13
|
export { createRegistryConfigService, DEFAULT_REGISTRY_API_BASE_URL, DEFAULT_REGISTRY_FRONTEND_URL, registryConfigPath, resolveRegistryApiBaseUrl, resolveRegistryApiTarget, resolveRegistryApiToken, resolveRegistryFrontendUrl, } from "./registry-config.js";
|
|
13
14
|
export { createRegistryTokenManager, } from "./registry-auth.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/core/agent-profiles/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EACL,YAAY,EACZ,oBAAoB,EACpB,mBAAmB,GAMpB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,uBAAuB,EACvB,4BAA4B,GAE7B,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,uBAAuB,EACvB,wBAAwB,GAIzB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,4BAA4B,EAC5B,oBAAoB,EACpB,qBAAqB,GACtB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,sBAAsB,EACtB,wBAAwB,EACxB,yBAAyB,EACzB,aAAa,EACb,aAAa,EACb,UAAU,EACV,YAAY,EACZ,UAAU,EACV,iBAAiB,EACjB,YAAY,EACZ,gBAAgB,EAChB,uBAAuB,EACvB,wBAAwB,EACxB,aAAa,EACb,YAAY,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/core/agent-profiles/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EACL,YAAY,EACZ,oBAAoB,EACpB,mBAAmB,GAMpB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,uBAAuB,EACvB,4BAA4B,GAE7B,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,uBAAuB,EACvB,wBAAwB,GAIzB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,4BAA4B,EAC5B,oBAAoB,EACpB,qBAAqB,GACtB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,sBAAsB,EACtB,wBAAwB,EACxB,yBAAyB,EACzB,wBAAwB,EACxB,aAAa,EACb,aAAa,EACb,UAAU,EACV,sBAAsB,EACtB,YAAY,EACZ,UAAU,EACV,iBAAiB,EACjB,YAAY,EACZ,gBAAgB,EAChB,uBAAuB,EACvB,uBAAuB,EACvB,wBAAwB,EACxB,aAAa,EACb,YAAY,EACZ,wBAAwB,GAEzB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,6BAA6B,EAC7B,4BAA4B,EAC5B,yBAAyB,EACzB,6BAA6B,GAK9B,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAE,aAAa,EAAE,aAAa,EAAwC,MAAM,eAAe,CAAC;AACnG,OAAO,EACL,2BAA2B,EAC3B,6BAA6B,EAC7B,6BAA6B,EAC7B,kBAAkB,EAClB,yBAAyB,EACzB,wBAAwB,EACxB,uBAAuB,EACvB,0BAA0B,GAI3B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACL,0BAA0B,GAG3B,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EACL,oBAAoB,GAOrB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACL,0BAA0B,EAC1B,wBAAwB,GAKzB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,oBAAoB,EACpB,qBAAqB,EACrB,gBAAgB,EAChB,mBAAmB,EACnB,aAAa,EACb,kBAAkB,GAOnB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import type { Profile } from "./types.js";
|
|
3
|
+
export declare const profileRegistrySnapshotSchema: z.ZodObject<{
|
|
4
|
+
description: z.ZodOptional<z.ZodString>;
|
|
5
|
+
sourceAgent: z.ZodOptional<z.ZodEnum<["claude", "codex", "antigravity"]>>;
|
|
6
|
+
mcps: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
7
|
+
skills: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
8
|
+
plugins: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
9
|
+
contentDigest: z.ZodString;
|
|
10
|
+
}, "strip", z.ZodTypeAny, {
|
|
11
|
+
skills: Record<string, string>;
|
|
12
|
+
plugins: Record<string, string>;
|
|
13
|
+
mcps: Record<string, string>;
|
|
14
|
+
contentDigest: string;
|
|
15
|
+
description?: string | undefined;
|
|
16
|
+
sourceAgent?: "claude" | "codex" | "antigravity" | undefined;
|
|
17
|
+
}, {
|
|
18
|
+
skills: Record<string, string>;
|
|
19
|
+
plugins: Record<string, string>;
|
|
20
|
+
mcps: Record<string, string>;
|
|
21
|
+
contentDigest: string;
|
|
22
|
+
description?: string | undefined;
|
|
23
|
+
sourceAgent?: "claude" | "codex" | "antigravity" | undefined;
|
|
24
|
+
}>;
|
|
25
|
+
export type ProfileRegistrySnapshot = z.infer<typeof profileRegistrySnapshotSchema>;
|
|
26
|
+
export declare const profileRegistryLinkSchema: z.ZodObject<{
|
|
27
|
+
schemaVersion: z.ZodLiteral<1>;
|
|
28
|
+
origin: z.ZodEnum<["published", "installed"]>;
|
|
29
|
+
slug: z.ZodString;
|
|
30
|
+
version: z.ZodString;
|
|
31
|
+
profileId: z.ZodOptional<z.ZodString>;
|
|
32
|
+
versionId: z.ZodOptional<z.ZodString>;
|
|
33
|
+
linkedAt: z.ZodString;
|
|
34
|
+
baseline: z.ZodObject<{
|
|
35
|
+
description: z.ZodOptional<z.ZodString>;
|
|
36
|
+
sourceAgent: z.ZodOptional<z.ZodEnum<["claude", "codex", "antigravity"]>>;
|
|
37
|
+
mcps: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
38
|
+
skills: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
39
|
+
plugins: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
40
|
+
contentDigest: z.ZodString;
|
|
41
|
+
}, "strip", z.ZodTypeAny, {
|
|
42
|
+
skills: Record<string, string>;
|
|
43
|
+
plugins: Record<string, string>;
|
|
44
|
+
mcps: Record<string, string>;
|
|
45
|
+
contentDigest: string;
|
|
46
|
+
description?: string | undefined;
|
|
47
|
+
sourceAgent?: "claude" | "codex" | "antigravity" | undefined;
|
|
48
|
+
}, {
|
|
49
|
+
skills: Record<string, string>;
|
|
50
|
+
plugins: Record<string, string>;
|
|
51
|
+
mcps: Record<string, string>;
|
|
52
|
+
contentDigest: string;
|
|
53
|
+
description?: string | undefined;
|
|
54
|
+
sourceAgent?: "claude" | "codex" | "antigravity" | undefined;
|
|
55
|
+
}>;
|
|
56
|
+
}, "strip", z.ZodTypeAny, {
|
|
57
|
+
origin: "published" | "installed";
|
|
58
|
+
version: string;
|
|
59
|
+
schemaVersion: 1;
|
|
60
|
+
slug: string;
|
|
61
|
+
linkedAt: string;
|
|
62
|
+
baseline: {
|
|
63
|
+
skills: Record<string, string>;
|
|
64
|
+
plugins: Record<string, string>;
|
|
65
|
+
mcps: Record<string, string>;
|
|
66
|
+
contentDigest: string;
|
|
67
|
+
description?: string | undefined;
|
|
68
|
+
sourceAgent?: "claude" | "codex" | "antigravity" | undefined;
|
|
69
|
+
};
|
|
70
|
+
profileId?: string | undefined;
|
|
71
|
+
versionId?: string | undefined;
|
|
72
|
+
}, {
|
|
73
|
+
origin: "published" | "installed";
|
|
74
|
+
version: string;
|
|
75
|
+
schemaVersion: 1;
|
|
76
|
+
slug: string;
|
|
77
|
+
linkedAt: string;
|
|
78
|
+
baseline: {
|
|
79
|
+
skills: Record<string, string>;
|
|
80
|
+
plugins: Record<string, string>;
|
|
81
|
+
mcps: Record<string, string>;
|
|
82
|
+
contentDigest: string;
|
|
83
|
+
description?: string | undefined;
|
|
84
|
+
sourceAgent?: "claude" | "codex" | "antigravity" | undefined;
|
|
85
|
+
};
|
|
86
|
+
profileId?: string | undefined;
|
|
87
|
+
versionId?: string | undefined;
|
|
88
|
+
}>;
|
|
89
|
+
export type ProfileRegistryLink = z.infer<typeof profileRegistryLinkSchema>;
|
|
90
|
+
export interface ProfileRegistryDiff {
|
|
91
|
+
descriptionChanged: boolean;
|
|
92
|
+
sourceAgentChanged: boolean;
|
|
93
|
+
hasLocalChanges: boolean;
|
|
94
|
+
mcps: ProfileRegistryItemDiff;
|
|
95
|
+
skills: ProfileRegistryItemDiff;
|
|
96
|
+
plugins: ProfileRegistryItemDiff;
|
|
97
|
+
}
|
|
98
|
+
export interface ProfileRegistryItemDiff {
|
|
99
|
+
added: string[];
|
|
100
|
+
removed: string[];
|
|
101
|
+
changed: string[];
|
|
102
|
+
}
|
|
103
|
+
/** Stable snapshot of local profile content. Only hashes—not secret values—are persisted. */
|
|
104
|
+
export declare function createProfileRegistrySnapshot(profile: Profile, directory: string): Promise<ProfileRegistrySnapshot>;
|
|
105
|
+
export declare function diffProfileRegistrySnapshots(baseline: ProfileRegistrySnapshot, current: ProfileRegistrySnapshot): ProfileRegistryDiff;
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
import { createHash } from "node:crypto";
|
|
2
|
+
import { readdir, readFile } from "node:fs/promises";
|
|
3
|
+
import path from "node:path";
|
|
4
|
+
import { z } from "zod";
|
|
5
|
+
import { redactMcpCredentials } from "./credentials.js";
|
|
6
|
+
const digestSchema = z.string().regex(/^[a-f0-9]{64}$/);
|
|
7
|
+
export const profileRegistrySnapshotSchema = z.object({
|
|
8
|
+
description: z.string().optional(),
|
|
9
|
+
sourceAgent: z.enum(["claude", "codex", "antigravity"]).optional(),
|
|
10
|
+
mcps: z.record(digestSchema),
|
|
11
|
+
skills: z.record(digestSchema),
|
|
12
|
+
plugins: z.record(digestSchema),
|
|
13
|
+
contentDigest: digestSchema,
|
|
14
|
+
});
|
|
15
|
+
export const profileRegistryLinkSchema = z.object({
|
|
16
|
+
schemaVersion: z.literal(1),
|
|
17
|
+
origin: z.enum(["published", "installed"]),
|
|
18
|
+
slug: z.string().min(1),
|
|
19
|
+
version: z.string().min(1),
|
|
20
|
+
profileId: z.string().optional(),
|
|
21
|
+
versionId: z.string().optional(),
|
|
22
|
+
linkedAt: z.string().datetime(),
|
|
23
|
+
baseline: profileRegistrySnapshotSchema,
|
|
24
|
+
});
|
|
25
|
+
/** Stable snapshot of local profile content. Only hashes—not secret values—are persisted. */
|
|
26
|
+
export async function createProfileRegistrySnapshot(profile, directory) {
|
|
27
|
+
const mcps = Object.fromEntries(Object.entries(profile.mcps)
|
|
28
|
+
.sort(([left], [right]) => left.localeCompare(right))
|
|
29
|
+
.map(([name, value]) => [name, digestValue(redactMcpCredentials(value).redacted)]));
|
|
30
|
+
const skills = Object.fromEntries(await Promise.all(profile.skills
|
|
31
|
+
.map((skill) => skill.name)
|
|
32
|
+
.sort()
|
|
33
|
+
.map(async (name) => [
|
|
34
|
+
name,
|
|
35
|
+
await digestDirectory(path.join(directory, "skills", path.basename(name))),
|
|
36
|
+
])));
|
|
37
|
+
const plugins = Object.fromEntries(await Promise.all([...profile.plugins]
|
|
38
|
+
.sort((left, right) => left.name.localeCompare(right.name))
|
|
39
|
+
.map(async (plugin) => [
|
|
40
|
+
plugin.name,
|
|
41
|
+
digestValue({
|
|
42
|
+
metadata: plugin,
|
|
43
|
+
files: await digestDirectory(path.join(directory, "plugins", plugin.bundleKey)),
|
|
44
|
+
}),
|
|
45
|
+
])));
|
|
46
|
+
const content = {
|
|
47
|
+
...(profile.description ? { description: profile.description } : {}),
|
|
48
|
+
...(profile.sourceAgent ? { sourceAgent: profile.sourceAgent } : {}),
|
|
49
|
+
mcps,
|
|
50
|
+
skills,
|
|
51
|
+
plugins,
|
|
52
|
+
};
|
|
53
|
+
return { ...content, contentDigest: digestValue(content) };
|
|
54
|
+
}
|
|
55
|
+
export function diffProfileRegistrySnapshots(baseline, current) {
|
|
56
|
+
const mcps = diffItems(baseline.mcps, current.mcps);
|
|
57
|
+
const skills = diffItems(baseline.skills, current.skills);
|
|
58
|
+
const plugins = diffItems(baseline.plugins, current.plugins);
|
|
59
|
+
const descriptionChanged = baseline.description !== current.description;
|
|
60
|
+
const sourceAgentChanged = baseline.sourceAgent !== current.sourceAgent;
|
|
61
|
+
return {
|
|
62
|
+
descriptionChanged,
|
|
63
|
+
sourceAgentChanged,
|
|
64
|
+
hasLocalChanges: baseline.contentDigest !== current.contentDigest,
|
|
65
|
+
mcps,
|
|
66
|
+
skills,
|
|
67
|
+
plugins,
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
function diffItems(baseline, current) {
|
|
71
|
+
const before = new Set(Object.keys(baseline));
|
|
72
|
+
const after = new Set(Object.keys(current));
|
|
73
|
+
return {
|
|
74
|
+
added: [...after].filter((name) => !before.has(name)).sort(),
|
|
75
|
+
removed: [...before].filter((name) => !after.has(name)).sort(),
|
|
76
|
+
changed: [...after]
|
|
77
|
+
.filter((name) => before.has(name) && baseline[name] !== current[name])
|
|
78
|
+
.sort(),
|
|
79
|
+
};
|
|
80
|
+
}
|
|
81
|
+
async function digestDirectory(directory) {
|
|
82
|
+
const hash = createHash("sha256");
|
|
83
|
+
async function visit(current, relative) {
|
|
84
|
+
let entries;
|
|
85
|
+
try {
|
|
86
|
+
entries = await readdir(current, { withFileTypes: true });
|
|
87
|
+
}
|
|
88
|
+
catch {
|
|
89
|
+
hash.update("missing\0");
|
|
90
|
+
return;
|
|
91
|
+
}
|
|
92
|
+
for (const entry of entries.sort((left, right) => left.name.localeCompare(right.name))) {
|
|
93
|
+
if (entry.name === ".git" || entry.name === ".DS_Store")
|
|
94
|
+
continue;
|
|
95
|
+
const entryRelative = relative ? `${relative}/${entry.name}` : entry.name;
|
|
96
|
+
const entryPath = path.join(current, entry.name);
|
|
97
|
+
if (entry.isDirectory()) {
|
|
98
|
+
hash.update(`dir\0${entryRelative}\0`);
|
|
99
|
+
await visit(entryPath, entryRelative);
|
|
100
|
+
}
|
|
101
|
+
else if (entry.isFile()) {
|
|
102
|
+
hash.update(`file\0${entryRelative}\0`);
|
|
103
|
+
hash.update(await readFile(entryPath));
|
|
104
|
+
hash.update("\0");
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
await visit(directory, "");
|
|
109
|
+
return hash.digest("hex");
|
|
110
|
+
}
|
|
111
|
+
function digestValue(value) {
|
|
112
|
+
return createHash("sha256").update(canonicalJson(value)).digest("hex");
|
|
113
|
+
}
|
|
114
|
+
function canonicalJson(value) {
|
|
115
|
+
if (Array.isArray(value))
|
|
116
|
+
return `[${value.map(canonicalJson).join(",")}]`;
|
|
117
|
+
if (value && typeof value === "object") {
|
|
118
|
+
const record = value;
|
|
119
|
+
return `{${Object.keys(record)
|
|
120
|
+
.sort()
|
|
121
|
+
.map((key) => `${JSON.stringify(key)}:${canonicalJson(record[key])}`)
|
|
122
|
+
.join(",")}}`;
|
|
123
|
+
}
|
|
124
|
+
return JSON.stringify(value) ?? "null";
|
|
125
|
+
}
|
|
126
|
+
//# sourceMappingURL=publication.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"publication.js","sourceRoot":"","sources":["../../../src/core/agent-profiles/publication.ts"],"names":[],"m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,CAAC,KAAK,CAAC,CAAC;AACzE,CAAC;AAED,SAAS,aAAa,CAAC,KAAc;IACnC,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC;QAAE,OAAO,IAAI,KAAK,CAAC,GAAG,CAAC,aAAa,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC;IAC3E,IAAI,KAAK,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;QACvC,MAAM,MAAM,GAAG,KAAgC,CAAC;QAChD,OAAO,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC;aAC3B,IAAI,EAAE;aACN,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,aAAa,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC;aACpE,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC;IAClB,CAAC;IACD,OAAO,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,IAAI,MAAM,CAAC;AACzC,CAAC"}
|
|
@@ -15,6 +15,34 @@ export interface RegistryProfileVersion {
|
|
|
15
15
|
profile_id: string;
|
|
16
16
|
version: string;
|
|
17
17
|
}
|
|
18
|
+
export type RegistryProfileSort = "recent" | "stars" | "downloads" | "alpha";
|
|
19
|
+
export interface RegistryPublicProfile {
|
|
20
|
+
id: string;
|
|
21
|
+
slug: string;
|
|
22
|
+
title: string;
|
|
23
|
+
summary: string;
|
|
24
|
+
stars_count: number;
|
|
25
|
+
downloads_count: number;
|
|
26
|
+
author?: {
|
|
27
|
+
id: string;
|
|
28
|
+
display_name?: string | null;
|
|
29
|
+
avatar_url?: string | null;
|
|
30
|
+
} | null;
|
|
31
|
+
source: {
|
|
32
|
+
kind: string;
|
|
33
|
+
github_repo_url?: string | null;
|
|
34
|
+
github_stars_count?: number | null;
|
|
35
|
+
};
|
|
36
|
+
latest_version: {
|
|
37
|
+
id: string;
|
|
38
|
+
profile_id: string;
|
|
39
|
+
version: string;
|
|
40
|
+
changelog: string;
|
|
41
|
+
manifest_json: Record<string, unknown>;
|
|
42
|
+
created_at: string;
|
|
43
|
+
published_at?: string | null;
|
|
44
|
+
};
|
|
45
|
+
}
|
|
18
46
|
export interface RegistryInstallDescriptor {
|
|
19
47
|
slug: string;
|
|
20
48
|
version: string;
|
|
@@ -33,6 +61,10 @@ export interface RegisterGithubProfileInput {
|
|
|
33
61
|
manifestJson: Record<string, unknown>;
|
|
34
62
|
}
|
|
35
63
|
export interface RegistryClient {
|
|
64
|
+
listPublicProfiles(input?: {
|
|
65
|
+
query?: string;
|
|
66
|
+
sort?: RegistryProfileSort;
|
|
67
|
+
}): Promise<RegistryPublicProfile[]>;
|
|
36
68
|
getProfileBySlug(slug: string): Promise<RegistryProfile | null>;
|
|
37
69
|
createProfile(input: {
|
|
38
70
|
slug: string;
|
|
@@ -18,6 +18,18 @@ export function createRegistryClient(options) {
|
|
|
18
18
|
throw new Error(`${action} failed: HTTP ${response.status}${text ? ` — ${text}` : ""}`);
|
|
19
19
|
}
|
|
20
20
|
return {
|
|
21
|
+
async listPublicProfiles(input = {}) {
|
|
22
|
+
const url = new URL(`${baseUrl}/profiles`);
|
|
23
|
+
const query = input.query?.trim();
|
|
24
|
+
if (query)
|
|
25
|
+
url.searchParams.set("q", query);
|
|
26
|
+
if (input.sort && input.sort !== "recent") {
|
|
27
|
+
url.searchParams.set("sort", input.sort);
|
|
28
|
+
}
|
|
29
|
+
const response = await fetchImpl(url, { headers: authHeaders });
|
|
30
|
+
await failIfNotOk(response, "List profiles");
|
|
31
|
+
return (await response.json());
|
|
32
|
+
},
|
|
21
33
|
async getProfileBySlug(slug) {
|
|
22
34
|
const response = await fetchImpl(`${baseUrl}/profiles/${slug}`, {
|
|
23
35
|
headers: authHeaders,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"registry-client.js","sourceRoot":"","sources":["../../../src/core/agent-profiles/registry-client.ts"],"names":[],"mappings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WAAW,CAAC,QAAQ,EAAE,yBAAyB,CAAC,CAAC;YACvD,OAAO,QAAQ,CAAC,IAAI,EAAE,CAAC;QACzB,CAAC;QAED,KAAK,CAAC,oBAAoB,CAAC,IAAI;YAC7B,MAAM,QAAQ,GAAG,MAAM,SAAS,CAAC,GAAG,OAAO,aAAa,IAAI,UAAU,EAAE;gBACtE,OAAO,EAAE,WAAW;aACrB,CAAC,CAAC;YACH,MAAM,WAAW,CAAC,QAAQ,EAAE,yBAAyB,CAAC,CAAC;YACvD,OAAO,CAAC,MAAM,QAAQ,CAAC,IAAI,EAAE,CAA8B,CAAC;QAC9D,CAAC;QAED,KAAK,CAAC,qBAAqB,CAAC,KAAK;YAC/B,MAAM,QAAQ,GAAG,MAAM,SAAS,CAAC,GAAG,OAAO,2BAA2B,EAAE;gBACtE,MAAM,EAAE,MAAM;gBACd,OAAO,EAAE,WAAW;gBACpB,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC;oBACnB,QAAQ,EAAE,KAAK,CAAC,OAAO;oBACvB,IAAI,EAAE,KAAK,CAAC,IAAI;oBAChB,KAAK,EAAE,KAAK,CAAC,KAAK;oBAClB,OAAO,EAAE,KAAK,CAAC,OAAO,IAAI,EAAE;oBAC5B,QAAQ,EAAE,KAAK,CAAC,OAAO,IAAI,MAAM;oBACjC,YAAY,EAAE,KAAK,CAAC,WAAW,IAAI,cAAc;oBACjD,aAAa,EAAE,KAAK,CAAC,YAAY;iBAClC,CAAC;aACH,CAAC,CAAC;YACH,MAAM,WAAW,CAAC,QAAQ,EAAE,yBAAyB,CAAC,CAAC;YACvD,OAAO,QAAQ,CAAC,IAAI,EAAE,CAAC;QACzB,CAAC;KACF,CAAC;AACJ,CAAC"}
|
|
@@ -9,7 +9,7 @@ import { mkdtemp, readFile, rm, writeFile } from "node:fs/promises";
|
|
|
9
9
|
import { tmpdir } from "node:os";
|
|
10
10
|
import path from "node:path";
|
|
11
11
|
import { createRegistryClient } from "./registry-client.js";
|
|
12
|
-
import { getProfile } from "./store.js";
|
|
12
|
+
import { getProfile, writeProfileRegistryLink, } from "./store.js";
|
|
13
13
|
import { exportProfile, importProfile } from "./transfer.js";
|
|
14
14
|
export async function publishProfileToRegistry(input, options = {}) {
|
|
15
15
|
const version = input.version ?? "1.0.0";
|
|
@@ -60,6 +60,13 @@ export async function publishProfileToRegistry(input, options = {}) {
|
|
|
60
60
|
profileId: registryProfile.id,
|
|
61
61
|
versionId: registryVersion.id,
|
|
62
62
|
});
|
|
63
|
+
await writeProfileRegistryLink(input.name, {
|
|
64
|
+
origin: "published",
|
|
65
|
+
slug: input.slug,
|
|
66
|
+
version,
|
|
67
|
+
profileId: registryProfile.id,
|
|
68
|
+
versionId: registryVersion.id,
|
|
69
|
+
}, options);
|
|
63
70
|
return {
|
|
64
71
|
slug: input.slug,
|
|
65
72
|
profileId: registryProfile.id,
|
|
@@ -98,6 +105,11 @@ export async function installProfileFromRegistry(input, options = {}) {
|
|
|
98
105
|
as: input.as,
|
|
99
106
|
credentials: input.credentials,
|
|
100
107
|
}, options);
|
|
108
|
+
await writeProfileRegistryLink(result.name, {
|
|
109
|
+
origin: "installed",
|
|
110
|
+
slug,
|
|
111
|
+
version: descriptor.version,
|
|
112
|
+
}, options);
|
|
101
113
|
return { ...result, version: descriptor.version, sourceKind: descriptor.source_kind };
|
|
102
114
|
}
|
|
103
115
|
finally {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"registry-transfer.js","sourceRoot":"","sources":["../../../src/core/agent-profiles/registry-transfer.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACpE,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AACjC,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,oBAAoB,EAAuB,MAAM,sBAAsB,CAAC;AACjF,OAAO,
|
|
1
|
+
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CAChC;YACE,WAAW;YACX,KAAK,EAAE,KAAK,CAAC,KAAK;YAClB,EAAE,EAAE,KAAK,CAAC,EAAE;YACZ,WAAW,EAAE,KAAK,CAAC,WAAW;SAC/B,EACD,OAAO,CACR,CAAC;QACF,MAAM,wBAAwB,CAC5B,MAAM,CAAC,IAAI,EACX;YACE,MAAM,EAAE,WAAW;YACnB,IAAI;YACJ,OAAO,EAAE,UAAU,CAAC,OAAO;SAC5B,EACD,OAAO,CACR,CAAC;QACF,OAAO,EAAE,GAAG,MAAM,EAAE,OAAO,EAAE,UAAU,CAAC,OAAO,EAAE,UAAU,EAAE,UAAU,CAAC,WAAW,EAAE,CAAC;IACxF,CAAC;YAAS,CAAC;QACT,MAAM,EAAE,CAAC,GAAG,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,GAAG,EAAE,GAAE,CAAC,CAAC,CAAC;IAClE,CAAC;AACH,CAAC;AAED;;;;;;;;GAQG;AACH,SAAS,kBAAkB,CAAC,WAAmB,EAAE,UAAkB;IACjE,IAAI,0BAA0B,CAAC,IAAI,CAAC,WAAW,CAAC;QAAE,OAAO,WAAW,CAAC;IACrE,OAAO,GAAG,UAAU,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,IAAI,WAAW,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,EAAE,CAAC;AAC9E,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { type AgentMcpEntry, type AgentName, type RemoteMcpEntry } from "../agent-env/index.js";
|
|
2
2
|
import { type Profile, type ProfileMcp, type ProfileSummary } from "./types.js";
|
|
3
|
+
import { type ProfileRegistryDiff, type ProfileRegistryLink } from "./publication.js";
|
|
3
4
|
export interface ProfileStoreOptions {
|
|
4
5
|
/** Injectable for tmpdir tests, like the agent-env readers. */
|
|
5
6
|
homeDir?: string;
|
|
@@ -18,6 +19,13 @@ export declare function createProfile(input: {
|
|
|
18
19
|
export declare function updateProfile(name: string, patch: Partial<Pick<Profile, "description" | "mcps" | "skills" | "plugins">>, options?: ProfileStoreOptions): Promise<Profile>;
|
|
19
20
|
export declare function deleteProfile(name: string, options?: ProfileStoreOptions): Promise<void>;
|
|
20
21
|
export declare function writeProfile(profile: Profile, options?: ProfileStoreOptions): Promise<void>;
|
|
22
|
+
export declare function readProfileRegistryLink(name: string, options?: ProfileStoreOptions): Promise<ProfileRegistryLink | null>;
|
|
23
|
+
export declare function writeProfileRegistryLink(name: string, input: Omit<ProfileRegistryLink, "schemaVersion" | "linkedAt" | "baseline">, options?: ProfileStoreOptions): Promise<ProfileRegistryLink>;
|
|
24
|
+
export declare function clearProfileRegistryLink(name: string, options?: ProfileStoreOptions): Promise<void>;
|
|
25
|
+
export declare function getProfileRegistryDiff(name: string, options?: ProfileStoreOptions): Promise<{
|
|
26
|
+
link: ProfileRegistryLink;
|
|
27
|
+
diff: ProfileRegistryDiff;
|
|
28
|
+
} | null>;
|
|
21
29
|
/**
|
|
22
30
|
* Capture an agent's live config (MCPs + local skills) into a new profile.
|
|
23
31
|
* Raw credential values are kept — the profile lives in the user's own config
|
|
@@ -39,6 +47,13 @@ export declare function refreshProfileFromAgent(input: {
|
|
|
39
47
|
name: string;
|
|
40
48
|
cwd: string;
|
|
41
49
|
}, options?: ProfileStoreOptions): Promise<Profile>;
|
|
50
|
+
/**
|
|
51
|
+
* Copy portable profile content as real files and directories. Agent skill
|
|
52
|
+
* directories are often links into a shared skill checkout; preserving those
|
|
53
|
+
* links would make the profile machine-specific and produce archives that the
|
|
54
|
+
* importer correctly refuses to extract.
|
|
55
|
+
*/
|
|
56
|
+
export declare function copyProfileAssetTree(source: string, target: string): Promise<void>;
|
|
42
57
|
export declare function toLocalProfileMcp(entry: AgentMcpEntry): ProfileMcp;
|
|
43
58
|
export declare function toRemoteProfileMcp(entry: RemoteMcpEntry): ProfileMcp;
|
|
44
59
|
/** Copy one bundled skill dir between profiles (no-op if the source has no files). */
|