@theagilemonkeys/facility 0.4.0 → 0.5.0
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/package.json +1 -1
- package/src/platform-admin.mjs +13 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theagilemonkeys/facility",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.0",
|
|
4
4
|
"description": "Run an AI crew on your GitHub repo: agents that plan before building, build to your standard, verify on a provisioned environment, and never merge their own work.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ai",
|
package/src/platform-admin.mjs
CHANGED
|
@@ -104,7 +104,7 @@ const ADMIN_FLAGS = {
|
|
|
104
104
|
...WRITE_FLAGS,
|
|
105
105
|
],
|
|
106
106
|
conversations: ["agent", "title", ...WRITE_FLAGS],
|
|
107
|
-
github: ["query", "state", "cursor", "agent", "limit", ...WRITE_FLAGS],
|
|
107
|
+
github: ["query", "state", "cursor", "agent", "limit", "repo", ...WRITE_FLAGS],
|
|
108
108
|
providers: ["provider", "name", "secret", "base-url", ...PAGE_FLAGS, ...WRITE_FLAGS],
|
|
109
109
|
budgets: ["id", "scope", "project", "agent", "period", "limit-cents", "mode", "enabled", ...PAGE_FLAGS, ...WRITE_FLAGS],
|
|
110
110
|
registry: [
|
|
@@ -226,9 +226,9 @@ const ADMIN_SUBCOMMAND_FLAGS = {
|
|
|
226
226
|
installations: [],
|
|
227
227
|
repos: ["query"],
|
|
228
228
|
issues: ["state", "query", "cursor", "limit"],
|
|
229
|
-
issue: [],
|
|
229
|
+
issue: ["repo"],
|
|
230
230
|
sync: [...WRITE_FLAGS],
|
|
231
|
-
trigger: ["agent", ...WRITE_FLAGS],
|
|
231
|
+
trigger: ["agent", "repo", ...WRITE_FLAGS],
|
|
232
232
|
},
|
|
233
233
|
providers: {
|
|
234
234
|
__default: [...PAGE_FLAGS],
|
|
@@ -690,7 +690,12 @@ async function github(args, ctx, flags) {
|
|
|
690
690
|
if (sub === "issue") {
|
|
691
691
|
const project = await ctx.resolveProject(args[1]);
|
|
692
692
|
const number = integerArgument(args[2], "issue number");
|
|
693
|
-
return details(
|
|
693
|
+
return details(
|
|
694
|
+
ctx,
|
|
695
|
+
await ctx.api("GET", `/v1/projects/${project.id}/issues/${number}`, {
|
|
696
|
+
query: compact({ repoId: stringFlag(flags.repo) }),
|
|
697
|
+
}),
|
|
698
|
+
);
|
|
694
699
|
}
|
|
695
700
|
if (sub === "sync") {
|
|
696
701
|
const project = await ctx.resolveProject(args[1]);
|
|
@@ -704,7 +709,10 @@ async function github(args, ctx, flags) {
|
|
|
704
709
|
const result = await ctx.api(
|
|
705
710
|
"POST",
|
|
706
711
|
`/v1/projects/${project.id}/issues/${number}/trigger`,
|
|
707
|
-
{
|
|
712
|
+
{
|
|
713
|
+
query: compact({ repoId: stringFlag(flags.repo) }),
|
|
714
|
+
body: { agent },
|
|
715
|
+
},
|
|
708
716
|
);
|
|
709
717
|
return changed(ctx, result, `triggered session ${result.id} from issue #${number}`);
|
|
710
718
|
}
|