This repository was archived by the owner on Apr 22, 2026. It is now read-only.
File tree Expand file tree Collapse file tree
fuzzforge-cli/src/fuzzforge_cli/commands Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -132,15 +132,22 @@ def _find_fuzzforge_root() -> Path:
132132 :returns: Path to fuzzforge-oss directory.
133133
134134 """
135- # Try to find from current file location
136- current = Path (__file__ ).resolve ()
135+ # Check environment variable override first
136+ env_root = os .environ .get ("FUZZFORGE_ROOT" )
137+ if env_root :
138+ return Path (env_root ).resolve ()
139+
140+ # Walk up from cwd to find a fuzzforge root (hub-config.json is the marker)
141+ for parent in [Path .cwd (), * Path .cwd ().parents ]:
142+ if (parent / "hub-config.json" ).is_file ():
143+ return parent
137144
138- # Walk up to find fuzzforge-oss root
145+ # Fall back to __file__-based search (dev install inside fuzzforge-oss)
146+ current = Path (__file__ ).resolve ()
139147 for parent in current .parents :
140148 if (parent / "fuzzforge-mcp" ).is_dir ():
141149 return parent
142150
143- # Fall back to cwd
144151 return Path .cwd ()
145152
146153
You can’t perform that action at this time.
0 commit comments