jorgebucaran / hydro

Ultra-pure, lag-free prompt with async Git status—just for Fish
MIT License
637 stars 53 forks source link

Ignore git for certaint directories #30

Closed lgehr closed 2 years ago

lgehr commented 2 years ago

I added a new configuration variable $hydro_ignored_git_paths where you can put paths you do not want hydro to display git information in the prompt.

My use-case is that I have my $HOME in a git repo to manage my dotfiles etc.

If you like this feature I would make another commit adding the information in the README.

jorgebucaran commented 2 years ago

I think this could be a useful feature.

lgehr commented 2 years ago

Changed the commit accordingly. Also now it ignores the whole repo and not only the git toplevel directory.

Updated the README, too

jorgebucaran commented 2 years ago

Also now it ignores the whole repo and not only the git toplevel directory.

Before it would only ignore the top-level directory, but not subdirectories, correct?

lgehr commented 2 years ago

Also now it ignores the whole repo and not only the git toplevel directory.

Before it would only ignore the top-level directory, but not subdirectories, correct?

correct!

jorgebucaran commented 2 years ago

Sorry for the long delay, @lgehr. Just merged your changes. 💯

I also tweaked the implementation (just a bit) to check for ignored paths if $PWD or $hydro_ignored_git_paths change.