Skip to content

Commit 9430815

Browse files
feat(scripts): enhance Goose recipe YAML generation with structured metadata
1 parent 5148bc4 commit 9430815

1 file changed

Lines changed: 17 additions & 6 deletions

File tree

.github/workflows/scripts/create-release-packages.sh

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -119,13 +119,24 @@ generate_commands() {
119119
yaml)
120120
# Generate Goose recipe format YAML
121121
local title instructions
122-
title=$(echo "$name" | sed 's/\b\(.\)/\u/g/g') # Convert to title case
123-
instructions=$(printf '%s\n' "$body" | sed 's/"/\\"/g' | tr '\n' '\\n')
122+
title=$(echo "$name" | sed 's/\b\(.\)/\u\1/g') # Convert to title case
123+
instructions=$(printf '%s\n' "$body" | sed 's/"/\\"/g')
124+
# Indent every line of body for valid YAML block scalar syntax
125+
indented_body=$(printf '%s\n' "$instructions" | sed 's/^/ /')
124126
cat > "$output_dir/speckit.$name.$ext" <<YAML_EOF
125-
version: 1.0.0
126-
title: "$title"
127-
description: "$description"
128-
instructions: "$description"
127+
version: 1.0.0
128+
title: "$title"
129+
description: "$description"
130+
author:
131+
contact: "spec-kit"
132+
extensions:
133+
- type: builtin
134+
name: developer
135+
activities:
136+
- "Spec-Driven Development"
137+
prompt: |
138+
${indented_body}
139+
YAML_EOF
129140
author:
130141
contact: "spec-kit"
131142
extensions:

0 commit comments

Comments
 (0)