A git status prompt for zsh written in Rust
src | 2 years ago | ||
.gitignore | 2 years ago | ||
Cargo.lock | 2 years ago | ||
Cargo.toml | 2 years ago | ||
README.md | 2 years ago |
A bare-bones Git prompt for zsh implemented in Rust for speed (and as a learning exercise).
Configuration is rudimentary because I figured “how often am I going to change the appearance of my Git prompt?”
cargo build --release
mv target/release/zsh-rust-git-prompt <bindir>
where <bindir>
is in PATH
..zshrc
:RPROMPT='$(git status --porcelain=v2 --branch --show-stash -z 2>/dev/null | zsh-rust-git-prompt)'`(Or
PROMPT
if you prefer, but it’s really designed more for RPROMPT
.)cargo build --release
) and reinstall.main.rs
.main.rs
.*_style()
functions.