Skip to content

Commit a05a4f5

Browse files
fix(detect): prune .vibe/ from scans (#2537)
Vibe's project-scope install dir (.vibe/) holds graphify's own skill, agent, and hook artifacts — scanning it wastes semantic extraction on config files instead of real code. Add .vibe to _SKIP_DIRS so it is pruned by default, matching how .graphify and graphify-out are handled.
1 parent 384bca4 commit a05a4f5

3 files changed

Lines changed: 38 additions & 1 deletion

File tree

‎graphify/detect.py‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -952,6 +952,7 @@ def _is_regular_file(path: Path) -> bool:
952952
".graphify", # graphify's own extraction cache — never index self-generated data
953953
".obsidian", ".smart-env", # Obsidian vault metadata and plugin caches (#2493)
954954
".worktrees", # git worktree convention (#947) — sibling checkouts, always redundant
955+
".vibe", # Mistral Vibe project-scope skill/agent/hook install dir (#2537)
955956
}
956957

957958
# Large generated files that are never useful to extract

‎tests/test_detect.py‎

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3270,6 +3270,27 @@ def test_detect_prunes_venv_names_without_markers(tmp_path):
32703270
assert not any(f"{os.sep}{name}{os.sep}" in f for f in all_files), f"{name} must stay pruned"
32713271

32723272

3273+
def test_detect_prunes_vibe_install_dir(tmp_path):
3274+
"""#2537: .vibe/ holds graphify's own skill/agent/hook artifacts when
3275+
installed in project scope — scanning it wastes extraction on config files
3276+
instead of real code, so it must be pruned by default."""
3277+
vibe = tmp_path / ".vibe"
3278+
(vibe / "skills" / "graphify").mkdir(parents=True)
3279+
(vibe / "skills" / "graphify" / "SKILL.md").write_text("# skill\n")
3280+
(vibe / "agents").mkdir()
3281+
(vibe / "agents" / "graphify-extract.toml").write_text("display_name = 'x'\n")
3282+
(vibe / "hooks.toml").write_text('[[hooks]]\nname = "x"\n')
3283+
(tmp_path / "main.py").write_text("def main():\n return 1\n")
3284+
3285+
result = detect(tmp_path)
3286+
all_files = [f for files in result["files"].values() for f in files]
3287+
assert any("main.py" in f for f in all_files), "real source must still be scanned"
3288+
assert not any(".vibe" in f for f in all_files), ".vibe/ must be pruned (#2537)"
3289+
assert any(f"{os.sep}.vibe{os.sep}" in d for d in result["pruned_noise_dirs"]), (
3290+
"pruned .vibe must be traceable in pruned_noise_dirs (#2537)"
3291+
)
3292+
3293+
32733294
@pytest.mark.parametrize(
32743295
("configured_out", "absolute", "symlink_target"),
32753296
[

‎uv.lock‎

Lines changed: 16 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)