@arvoretech/hub 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/dist/index.js +44 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
// src/index.ts
|
|
4
|
-
import { Command as
|
|
4
|
+
import { Command as Command19 } from "commander";
|
|
5
5
|
|
|
6
6
|
// src/commands/init.ts
|
|
7
7
|
import { Command } from "commander";
|
|
@@ -2672,6 +2672,16 @@ Installing hooks from ${source}
|
|
|
2672
2672
|
}
|
|
2673
2673
|
console.log();
|
|
2674
2674
|
})
|
|
2675
|
+
).addCommand(
|
|
2676
|
+
new Command10("find").description("Browse curated hooks in the Repo Hub directory").argument("[query]", "Search term").action(async (query) => {
|
|
2677
|
+
const base = "https://rhm-website.vercel.app/directory?type=hook";
|
|
2678
|
+
const url = query ? `${base}&q=${encodeURIComponent(query)}` : base;
|
|
2679
|
+
console.log(chalk10.blue("\n Browse curated hooks at:\n"));
|
|
2680
|
+
console.log(chalk10.cyan(` ${url}
|
|
2681
|
+
`));
|
|
2682
|
+
console.log(chalk10.dim(" Install with: hub hooks add <owner>/<repo>"));
|
|
2683
|
+
console.log(chalk10.dim(" Example: hub hooks add obra/superpowers\n"));
|
|
2684
|
+
})
|
|
2675
2685
|
).addCommand(
|
|
2676
2686
|
new Command10("remove").description("Remove a hook").argument("<name>", "Hook name to remove").action(async (name) => {
|
|
2677
2687
|
const hubDir = process.cwd();
|
|
@@ -2856,6 +2866,16 @@ Installing commands from ${source}
|
|
|
2856
2866
|
}
|
|
2857
2867
|
console.log();
|
|
2858
2868
|
})
|
|
2869
|
+
).addCommand(
|
|
2870
|
+
new Command11("find").description("Browse curated commands in the Repo Hub directory").argument("[query]", "Search term").action(async (query) => {
|
|
2871
|
+
const base = "https://rhm-website.vercel.app/directory?type=command";
|
|
2872
|
+
const url = query ? `${base}&q=${encodeURIComponent(query)}` : base;
|
|
2873
|
+
console.log(chalk11.blue("\n Browse curated commands at:\n"));
|
|
2874
|
+
console.log(chalk11.cyan(` ${url}
|
|
2875
|
+
`));
|
|
2876
|
+
console.log(chalk11.dim(" Install with: hub commands add <owner>/<repo>"));
|
|
2877
|
+
console.log(chalk11.dim(" Example: hub commands add obra/superpowers\n"));
|
|
2878
|
+
})
|
|
2859
2879
|
).addCommand(
|
|
2860
2880
|
new Command11("remove").description("Remove a command").argument("<name>", "Command name to remove").action(async (name) => {
|
|
2861
2881
|
const hubDir = process.cwd();
|
|
@@ -3783,11 +3803,31 @@ var updateCommand = new Command17("update").description("Update hub CLI to the l
|
|
|
3783
3803
|
}
|
|
3784
3804
|
});
|
|
3785
3805
|
|
|
3806
|
+
// src/commands/directory.ts
|
|
3807
|
+
import { Command as Command18 } from "commander";
|
|
3808
|
+
import chalk18 from "chalk";
|
|
3809
|
+
var BASE_URL = "https://rhm-website.vercel.app/directory";
|
|
3810
|
+
var directoryCommand = new Command18("directory").alias("dir").description("Browse the Repo Hub directory of skills, agents, hooks, and commands").argument("[query]", "Search term").option("-t, --type <type>", "Filter by type (skill, agent, hook, command)").action(async (query, opts) => {
|
|
3811
|
+
const params = new URLSearchParams();
|
|
3812
|
+
if (opts?.type) params.set("type", opts.type);
|
|
3813
|
+
if (query) params.set("q", query);
|
|
3814
|
+
const qs = params.toString();
|
|
3815
|
+
const url = qs ? `${BASE_URL}?${qs}` : BASE_URL;
|
|
3816
|
+
console.log(chalk18.blue("\n Repo Hub Directory\n"));
|
|
3817
|
+
console.log(chalk18.cyan(` ${url}
|
|
3818
|
+
`));
|
|
3819
|
+
console.log(chalk18.dim(" Install examples:"));
|
|
3820
|
+
console.log(chalk18.dim(" hub skills add <owner>/<repo>/<skill>"));
|
|
3821
|
+
console.log(chalk18.dim(" hub agents add <owner>/<repo>"));
|
|
3822
|
+
console.log(chalk18.dim(" hub hooks add <owner>/<repo>"));
|
|
3823
|
+
console.log(chalk18.dim(" hub commands add <owner>/<repo>\n"));
|
|
3824
|
+
});
|
|
3825
|
+
|
|
3786
3826
|
// src/index.ts
|
|
3787
|
-
var program = new
|
|
3827
|
+
var program = new Command19();
|
|
3788
3828
|
program.name("hub").description(
|
|
3789
3829
|
"Give your AI coding assistant the full picture. Multi-repo context, agent orchestration, and end-to-end workflows."
|
|
3790
|
-
).version("0.
|
|
3830
|
+
).version("0.5.0").enablePositionalOptions();
|
|
3791
3831
|
program.addCommand(initCommand);
|
|
3792
3832
|
program.addCommand(addRepoCommand);
|
|
3793
3833
|
program.addCommand(setupCommand);
|
|
@@ -3807,4 +3847,5 @@ program.addCommand(doctorCommand);
|
|
|
3807
3847
|
program.addCommand(toolsCommand);
|
|
3808
3848
|
program.addCommand(memoryCommand);
|
|
3809
3849
|
program.addCommand(updateCommand);
|
|
3850
|
+
program.addCommand(directoryCommand);
|
|
3810
3851
|
program.parse();
|