Skip to main content

Module git

Module git 

Source

Functionsยง

commit_is_merge
commit_is_pushed
compute_next_minor_tag
Compute the next minor semver tag from latest tag.
create_tag
Create a git lightweight tag.
ensure_commit_exists
ensure_head_exists
find_repo_root
Find the git repository root directory
get_commit_diff
get_latest_tag
Returns the latest tag according to git version sorting.
get_range_diff
get_staged_diff
Get the output of git diff --staged
has_upstream_branch
head_is_merge_commit
Returns true if HEAD has multiple parents
is_head_commit
is_head_pushed
Returns true when HEAD exists on upstream branch
list_staged_files
List staged file paths
rewrite_commit_message
run_commit
Run git commit -m "<message>" [extra_args...]
run_push
Run git push
undo_last_commit_soft
Undo latest commit, keep all changes staged