@airig/cli 0.0.5 → 0.0.7
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 +14 -7
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -408,6 +408,10 @@ const PROVIDER_REGISTRY = {
|
|
|
408
408
|
{
|
|
409
409
|
source: ".ai/.claude/commands",
|
|
410
410
|
target: ".claude/commands"
|
|
411
|
+
},
|
|
412
|
+
{
|
|
413
|
+
source: ".ai/skills",
|
|
414
|
+
target: ".claude/skills"
|
|
411
415
|
}
|
|
412
416
|
]
|
|
413
417
|
},
|
|
@@ -425,16 +429,16 @@ const PROVIDER_REGISTRY = {
|
|
|
425
429
|
{
|
|
426
430
|
source: ".ai/.codex/commands",
|
|
427
431
|
target: ".codex/prompts"
|
|
432
|
+
},
|
|
433
|
+
{
|
|
434
|
+
source: ".ai/skills",
|
|
435
|
+
target: ".agents/skills"
|
|
428
436
|
}
|
|
429
437
|
]
|
|
430
438
|
}
|
|
431
439
|
};
|
|
432
|
-
const SKILLS_RULE = {
|
|
433
|
-
source: ".ai/skills",
|
|
434
|
-
target: ".agents/skills"
|
|
435
|
-
};
|
|
436
440
|
function rulesFor(providers) {
|
|
437
|
-
return
|
|
441
|
+
return providers.flatMap((p) => PROVIDER_REGISTRY[p].rules);
|
|
438
442
|
}
|
|
439
443
|
function targetPathsForArtifact(artifact, providers = Object.keys(PROVIDER_REGISTRY)) {
|
|
440
444
|
const targets = /* @__PURE__ */ new Set();
|
|
@@ -682,7 +686,10 @@ async function runAddLocal() {
|
|
|
682
686
|
return;
|
|
683
687
|
}
|
|
684
688
|
const currentLinked = aiJson.packages["."].linked;
|
|
685
|
-
const selectable = (await listArtifacts(".ai", providers)).filter((artifact) =>
|
|
689
|
+
const selectable = (await listArtifacts(".ai", providers)).filter((artifact) => {
|
|
690
|
+
if (!currentLinked.includes(artifact)) return true;
|
|
691
|
+
return targetPathsForArtifact(artifact, providers).some((tp) => !existsSync(tp));
|
|
692
|
+
});
|
|
686
693
|
if (selectable.length === 0) {
|
|
687
694
|
console.log("No new local files found.");
|
|
688
695
|
return;
|
|
@@ -1052,7 +1059,7 @@ function formatUpdateMessage(opts) {
|
|
|
1052
1059
|
}
|
|
1053
1060
|
//#endregion
|
|
1054
1061
|
//#region src/index.ts
|
|
1055
|
-
const program = new Command("airig").description("Manage project-scoped AI Setup artifacts").version("0.0.
|
|
1062
|
+
const program = new Command("airig").description("Manage project-scoped AI Setup artifacts").version("0.0.7");
|
|
1056
1063
|
program.addCommand(publishCommand);
|
|
1057
1064
|
program.addCommand(addCommand);
|
|
1058
1065
|
program.addCommand(updateCommand);
|