MCPcopy Create free account
hub / github.com/ScriptedAlchemy/tracedecay / which_tracedecay

Function which_tracedecay

src/agents/mod.rs:738–747  ·  view source on GitHub ↗

Finds the tracedecay binary path. On Windows the returned path uses forward slashes so it can be safely embedded in JSON hook commands without backslash-escaping issues.

()

Source from the content-addressed store, hash-verified

736/// On Windows the returned path uses forward slashes so it can be safely
737/// embedded in JSON hook commands without backslash-escaping issues.
738pub fn which_tracedecay() -> Option<String> {
739 let current_exe = std::env::current_exe().ok();
740 let path_var = std::env::var_os("PATH");
741 let cargo_target_dir = std::env::var_os("CARGO_TARGET_DIR").map(PathBuf::from);
742 which_tracedecay_from(
743 current_exe.as_deref(),
744 path_var.as_deref(),
745 cargo_target_dir.as_deref(),
746 )
747}
748
749fn which_tracedecay_from(
750 current_exe: Option<&Path>,

Callers 6

dispatch_commandFunction · 0.85
tracedecay_bin_on_pathFunction · 0.85
reinstall_tracked_agentsFunction · 0.85
handle_install_commandFunction · 0.85
handle_reinstall_commandFunction · 0.85

Calls 1

which_tracedecay_fromFunction · 0.85