Strip GIT_* environment variables to prevent the subprocess from discovering or modifying the parent's git repo.
()
| 186 | /// Strip GIT_* environment variables to prevent the subprocess from |
| 187 | /// discovering or modifying the parent's git repo. |
| 188 | pub(crate) fn clean_env() -> Vec<(String, String)> { |
| 189 | std::env::vars() |
| 190 | .filter(|(key, _)| !key.starts_with("GIT_")) |
| 191 | .collect() |
| 192 | } |
| 193 | |
| 194 | /// Check if the claude CLI is available on PATH. |
| 195 | pub fn is_available(&self) -> bool { |