Crates.io | git-state |
lib.rs | git-state |
version | 0.1.0 |
source | src |
created_at | 2020-11-02 00:43:21.674307 |
updated_at | 2020-11-02 00:43:21.674307 |
description | Probe git repository state |
homepage | |
repository | https://gitlab.com/timvisee/git-state |
max_upload_size | |
id | 307702 |
size | 8,910 |
A simple binary and Rust library to probe the state of a git repository. Useful for shell prompts.
This reimplements git2::git_repository_state
in pure Rust.
This doesn't have any nasty compile or runtime git2
dependencies.
The git command-line interface doesn't provide this functionality.
Any of the following state is returned:
Clean
Merge
Revert
RevertSequence
CherryPick
CherryPickSequence
Bisect
Rebase
RebaseInteractive
RebaseMerge
ApplyMailbox
ApplyMailboxOrRebase
Command-line usage:
cd my-repository/
git-state
# or
git-state my-repository/
This project is released under the MIT license. Check out the LICENSE file for more information.