Skip to main content

Module git_helpers

Module git_helpers 

Source
Expand description

Git command wrappers for both the main repo and the valet bare repo.

Functions§

get_git_dir
Returns the absolute path of the current repo’s .git directory
get_origin
Returns the origin remote URL of the current repo
get_work_tree
Returns the root of the current git repo
git
Runs a git command in the main repo and checks exit status
git_output
Returns the stdout of a git command as a String
load_config
Loads the valet config from the current repo
path_str
Converts a Path to a UTF-8 string, with a descriptive error on failure.
sgit
Runs a git command against the valet bare repo + work-tree (does not check exit status).