allagents 1.4.10 → 1.4.11
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/index.js +41 -7
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -28332,6 +28332,21 @@ async function updateRepositories(changes, workspacePath = process.cwd()) {
|
|
|
28332
28332
|
};
|
|
28333
28333
|
}
|
|
28334
28334
|
}
|
|
28335
|
+
async function setRepositories(repositories, workspacePath = process.cwd()) {
|
|
28336
|
+
const configPath = join11(workspacePath, CONFIG_DIR, WORKSPACE_CONFIG_FILE);
|
|
28337
|
+
try {
|
|
28338
|
+
const content = await readFile7(configPath, "utf-8");
|
|
28339
|
+
const config = load(content);
|
|
28340
|
+
config.repositories = repositories;
|
|
28341
|
+
await writeFile4(configPath, dump(config, { lineWidth: -1 }), "utf-8");
|
|
28342
|
+
return { success: true };
|
|
28343
|
+
} catch (error) {
|
|
28344
|
+
return {
|
|
28345
|
+
success: false,
|
|
28346
|
+
error: error instanceof Error ? error.message : String(error)
|
|
28347
|
+
};
|
|
28348
|
+
}
|
|
28349
|
+
}
|
|
28335
28350
|
var DEFAULT_PROJECT_CLIENTS;
|
|
28336
28351
|
var init_workspace_modify = __esm(() => {
|
|
28337
28352
|
init_js_yaml();
|
|
@@ -28809,6 +28824,7 @@ function reconcileVscodeWorkspaceFolders(workspacePath, codeWorkspaceFolders, la
|
|
|
28809
28824
|
const currentAbsPaths = new Set(currentReposByAbsPath.keys());
|
|
28810
28825
|
const added = [];
|
|
28811
28826
|
const removed = [];
|
|
28827
|
+
const renamed2 = [];
|
|
28812
28828
|
const updatedRepos = [];
|
|
28813
28829
|
for (const [absPath, repo] of currentReposByAbsPath) {
|
|
28814
28830
|
const inLastSync = lastSyncedSet.has(absPath);
|
|
@@ -28816,7 +28832,19 @@ function reconcileVscodeWorkspaceFolders(workspacePath, codeWorkspaceFolders, la
|
|
|
28816
28832
|
if (inLastSync && !inCodeWorkspace) {
|
|
28817
28833
|
removed.push(repo.path);
|
|
28818
28834
|
} else {
|
|
28819
|
-
|
|
28835
|
+
const folderName = codeWorkspaceNames.get(absPath);
|
|
28836
|
+
if (folderName !== repo.name) {
|
|
28837
|
+
const updatedRepo = { ...repo };
|
|
28838
|
+
if (folderName === undefined) {
|
|
28839
|
+
delete updatedRepo.name;
|
|
28840
|
+
} else {
|
|
28841
|
+
updatedRepo.name = folderName;
|
|
28842
|
+
}
|
|
28843
|
+
updatedRepos.push(updatedRepo);
|
|
28844
|
+
renamed2.push(repo.path);
|
|
28845
|
+
} else {
|
|
28846
|
+
updatedRepos.push(repo);
|
|
28847
|
+
}
|
|
28820
28848
|
}
|
|
28821
28849
|
}
|
|
28822
28850
|
for (const absPath of codeWorkspaceAbsPaths) {
|
|
@@ -28832,7 +28860,7 @@ function reconcileVscodeWorkspaceFolders(workspacePath, codeWorkspaceFolders, la
|
|
|
28832
28860
|
updatedRepos.push(newRepo);
|
|
28833
28861
|
}
|
|
28834
28862
|
}
|
|
28835
|
-
return { updatedRepos, added, removed };
|
|
28863
|
+
return { updatedRepos, added, removed, renamed: renamed2 };
|
|
28836
28864
|
}
|
|
28837
28865
|
var DEFAULT_SETTINGS;
|
|
28838
28866
|
var init_vscode_workspace = __esm(() => {
|
|
@@ -30641,8 +30669,11 @@ async function syncVscodeWorkspaceFile(workspacePath, config, configPath, previo
|
|
|
30641
30669
|
const existingWorkspace = JSON.parse(existingContent);
|
|
30642
30670
|
const folders = Array.isArray(existingWorkspace.folders) ? existingWorkspace.folders : [];
|
|
30643
30671
|
const reconciled = reconcileVscodeWorkspaceFolders(workspacePath, folders, previousState.vscodeWorkspaceRepos, config.repositories);
|
|
30644
|
-
if (reconciled.added.length > 0 || reconciled.removed.length > 0) {
|
|
30645
|
-
await updateRepositories({ remove: reconciled.removed, add: reconciled.added.map((p) => ({ path: p })) }, workspacePath);
|
|
30672
|
+
if (reconciled.added.length > 0 || reconciled.removed.length > 0 || reconciled.renamed.length > 0) {
|
|
30673
|
+
const updateResult = reconciled.renamed.length > 0 ? await setRepositories(reconciled.updatedRepos, workspacePath) : await updateRepositories({ remove: reconciled.removed, add: reconciled.added.map((p) => ({ path: p })) }, workspacePath);
|
|
30674
|
+
if (!updateResult.success) {
|
|
30675
|
+
throw new Error(updateResult.error ?? "Failed to update repositories");
|
|
30676
|
+
}
|
|
30646
30677
|
updatedConfig = await parseWorkspaceConfig(configPath);
|
|
30647
30678
|
if (reconciled.removed.length > 0) {
|
|
30648
30679
|
messages.push(`Repositories removed (from .code-workspace): ${reconciled.removed.join(", ")}`);
|
|
@@ -30650,6 +30681,9 @@ async function syncVscodeWorkspaceFile(workspacePath, config, configPath, previo
|
|
|
30650
30681
|
if (reconciled.added.length > 0) {
|
|
30651
30682
|
messages.push(`Repositories added (from .code-workspace): ${reconciled.added.join(", ")}`);
|
|
30652
30683
|
}
|
|
30684
|
+
if (reconciled.renamed.length > 0) {
|
|
30685
|
+
messages.push(`Repository names updated (from .code-workspace): ${reconciled.renamed.join(", ")}`);
|
|
30686
|
+
}
|
|
30653
30687
|
}
|
|
30654
30688
|
} catch {}
|
|
30655
30689
|
}
|
|
@@ -34307,11 +34341,11 @@ var package_default;
|
|
|
34307
34341
|
var init_package = __esm(() => {
|
|
34308
34342
|
package_default = {
|
|
34309
34343
|
name: "allagents",
|
|
34310
|
-
version: "1.4.
|
|
34344
|
+
version: "1.4.11",
|
|
34311
34345
|
description: "CLI tool for managing multi-repo AI agent workspaces with plugin synchronization",
|
|
34312
34346
|
type: "module",
|
|
34313
34347
|
bin: {
|
|
34314
|
-
allagents: "
|
|
34348
|
+
allagents: "dist/index.js"
|
|
34315
34349
|
},
|
|
34316
34350
|
files: [
|
|
34317
34351
|
"dist"
|
|
@@ -34353,7 +34387,7 @@ var init_package = __esm(() => {
|
|
|
34353
34387
|
license: "MIT",
|
|
34354
34388
|
repository: {
|
|
34355
34389
|
type: "git",
|
|
34356
|
-
url: "https://github.com/EntityProcess/allagents.git"
|
|
34390
|
+
url: "git+https://github.com/EntityProcess/allagents.git"
|
|
34357
34391
|
},
|
|
34358
34392
|
homepage: "https://allagents.dev",
|
|
34359
34393
|
dependencies: {
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "allagents",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.11",
|
|
4
4
|
"description": "CLI tool for managing multi-repo AI agent workspaces with plugin synchronization",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
7
|
-
"allagents": "
|
|
7
|
+
"allagents": "dist/index.js"
|
|
8
8
|
},
|
|
9
9
|
"files": [
|
|
10
10
|
"dist"
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"license": "MIT",
|
|
47
47
|
"repository": {
|
|
48
48
|
"type": "git",
|
|
49
|
-
"url": "https://github.com/EntityProcess/allagents.git"
|
|
49
|
+
"url": "git+https://github.com/EntityProcess/allagents.git"
|
|
50
50
|
},
|
|
51
51
|
"homepage": "https://allagents.dev",
|
|
52
52
|
"dependencies": {
|