mirror of
https://github.com/github/spec-kit.git
synced 2026-03-19 11:53:08 +00:00
Applying review recommendations
This commit is contained in:
@@ -739,7 +739,10 @@ class CommandRegistrar:
|
||||
return self._registrar.render_frontmatter(frontmatter) + "\n" + context_note + body
|
||||
|
||||
def _render_toml_command(self, frontmatter, body, ext_id):
|
||||
return self._registrar.render_toml_command(frontmatter, body, ext_id)
|
||||
# Preserve extension-specific context comments for backward compatibility
|
||||
base = self._registrar.render_toml_command(frontmatter, body, ext_id)
|
||||
context_lines = f"# Extension: {ext_id}\n# Config: .specify/extensions/{ext_id}/\n"
|
||||
return base.rstrip("\n") + "\n" + context_lines
|
||||
|
||||
def register_commands_for_agent(
|
||||
self,
|
||||
|
||||
@@ -1351,11 +1351,11 @@ class PresetCatalog:
|
||||
raise PresetError(f"Failed to save preset ZIP: {e}")
|
||||
|
||||
def clear_cache(self):
|
||||
"""Clear the catalog cache."""
|
||||
if self.cache_file.exists():
|
||||
self.cache_file.unlink()
|
||||
if self.cache_metadata_file.exists():
|
||||
self.cache_metadata_file.unlink()
|
||||
"""Clear all catalog cache files, including per-URL hashed caches."""
|
||||
if self.cache_dir.exists():
|
||||
for f in self.cache_dir.iterdir():
|
||||
if f.is_file() and f.name.startswith("catalog"):
|
||||
f.unlink(missing_ok=True)
|
||||
|
||||
|
||||
class PresetResolver:
|
||||
|
||||
Reference in New Issue
Block a user