Skip to content

Commit 8aac671

Browse files
committed
fix: detect blank project
1 parent 4f0e6ae commit 8aac671

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

src/starship/prompts/example-tests/.gitkeep

Whitespace-only changes.

src/starship/tools/starship-config-gen.ts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -629,6 +629,17 @@ export function registerStarshipConfigGenTool(server: McpServer): void {
629629
"Parses and validates a Starship configuration YAML string against the known schema.",
630630
verifyStarshipConfigInputSchema.shape, // Use the verification schema shape
631631
async (input: VerifyStarshipConfigInput) => {
632+
if (!input.yamlContent) {
633+
return {
634+
content: [
635+
{
636+
type: "text",
637+
text: "Starship has not been initialized yet. Skipping configuration verification.",
638+
},
639+
],
640+
};
641+
}
642+
632643
try {
633644
// 1. Parse the YAML string
634645
// Use load instead of safeLoad as safeLoad is not exposed in type defs

0 commit comments

Comments
 (0)