mirror of
https://github.com/MadsLorentzen/ai-job-search.git
synced 2026-09-17 00:26:26 +00:00
chore: untrack tracker CSV, scope scraper Bash permission, fix portal SKILL.md paths (#71)
- Untrack job_search_tracker.csv: it was both tracked and listed in .gitignore (same inconsistency class as the settings.local.json fix in #27). Users' personal rows risked merge conflicts on every pull; commands already create the file with the standard header when it is missing. - Scope job-scraper's allowed-tools Bash entry (from #52) to 'bun --version' and the portal-CLI invocation pattern, adopting the tighter form proposed in #65. - Fix all five portal SKILL.mds documenting 'bun run skills/...' paths that do not resolve from the repo root ('.agents/skills/...' is correct) - now load-bearing since #52 wired /scrape to read these docs for CLI invocations. Surfaced in #66. - Teach tools/lint_skills.py to glob-expand allowed-tools bun run targets so scoped wildcard permissions lint correctly. Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Fable 5
parent
3c7a1cfdf5
commit
a5ffcc39ff
+13
-5
@@ -55,11 +55,19 @@ def check_skill(path: Path) -> None:
|
||||
|
||||
allowed = data.get("allowed-tools", "")
|
||||
if isinstance(allowed, str):
|
||||
for match in re.finditer(r"bun run ([^\s*)]+)", allowed):
|
||||
target = match.group(1)
|
||||
candidates = [ROOT / target, ROOT / ".agents" / target]
|
||||
if not any(c.is_file() for c in candidates):
|
||||
errors.append(f"{rel(path)}: allowed-tools references a missing file: {target}")
|
||||
for match in re.finditer(r"bun run ([^\s)]+)", allowed):
|
||||
target = match.group(1).rstrip("*")
|
||||
if not target or target.endswith("/"):
|
||||
continue
|
||||
# Targets may contain globs (e.g. .agents/skills/*/cli/src/cli.ts);
|
||||
# require at least one existing file to match.
|
||||
if "*" in target:
|
||||
if not list(ROOT.glob(target)) and not list((ROOT / ".agents").glob(target)):
|
||||
errors.append(f"{rel(path)}: allowed-tools glob matches no files: {target}")
|
||||
else:
|
||||
candidates = [ROOT / target, ROOT / ".agents" / target]
|
||||
if not any(c.is_file() for c in candidates):
|
||||
errors.append(f"{rel(path)}: allowed-tools references a missing file: {target}")
|
||||
|
||||
|
||||
def check_command(path: Path) -> None:
|
||||
|
||||
Reference in New Issue
Block a user