Crate gitcc_git

Source
Expand description

Git functionalities

Under the hood, this crate uses the git2 crate. It wraps it to provide a higher-level API.

Structs§

Commit
A commit
Error
Tag
A git tag

Constants§

USER_EMAIL
Config key for the user email
USER_NAME
Config key for the user name

Functions§

add_all
Runs git add --all
commit_log
Returns the complete commit history
commit_to_head
Performs a commit to the head
discover_repo
Discovers the repo at or above the provided path
get_config
Returns the repo config
get_origin_url
Retrieves the repo origin url
get_tag_refs
Retrieves all the repo tag references
list_tags
Retrieves all the repo tags (lightweight and annotated)
push_to_remote
Performs a push
repo_status
Checks if the repo is clean, ie has no uncommited and untracked files
set_annotated_tag
Sets an annotated tag to the HEAD

Type Aliases§

GitConfig
A more user-friendly config object
GitRepository
A simple alias for git2::Repository
Status
Status of a file
StatusShow
Status show option