Skip to content

Commit 49745f6

Browse files
JonZeollaclaude
andcommitted
fix: add zenable install dir to PATH after install
The installer updates PATH for future shells (via GITHUB_PATH in CI or shell profile locally) but not the current Python process. After a successful install, prepend ~/.zenable/bin to the process PATH so _find_zenable_binary() can locate the binary immediately. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent d3c4b21 commit 49745f6

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

hooks/post_gen_project.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -258,6 +258,13 @@ def opportunistically_install_zenable_tools() -> None:
258258
LOG.warning("Zenable CLI could not be installed.")
259259
return
260260

261+
# The installer updates PATH for future shells/steps (e.g. via
262+
# GITHUB_PATH or the user's shell profile) but not the current
263+
# process. Add the default install directory so we can find the
264+
# binary immediately.
265+
zenable_bin_dir = str(Path.home() / ".zenable" / "bin")
266+
os.environ["PATH"] = zenable_bin_dir + os.pathsep + os.environ.get("PATH", "")
267+
261268
zenable_bin = _find_zenable_binary()
262269
if not zenable_bin:
263270
LOG.warning("Zenable CLI was installed but could not be found in PATH or default location.")

0 commit comments

Comments
 (0)