diff --git a/src/git.rs b/src/git.rs index 5008ebfcd3..2dc4aa0d8b 100644 --- a/src/git.rs +++ b/src/git.rs @@ -1,7 +1,8 @@ +#![cfg(not(feature = "starship-prompt"))] + use git2::{Repository, RepositoryOpenFlags}; use std::ffi::OsString; -#[cfg(not(feature = "starship-prompt"))] pub fn current_branch() -> Option { let v: Vec = vec![]; match Repository::open_ext(".", RepositoryOpenFlags::empty(), v) {