mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-03-27 03:14:56 +01:00
mercurial: removed redundant checks
This commit is contained in:
parent
3d5b3430fd
commit
676266345b
1 changed files with 0 additions and 4 deletions
|
|
@ -26,9 +26,7 @@ function in_hg() {
|
|||
}
|
||||
|
||||
function hg_get_branch_name() {
|
||||
if [ $(in_hg) ]; then
|
||||
echo $(hg branch)
|
||||
fi
|
||||
}
|
||||
|
||||
function hg_prompt_info {
|
||||
|
|
@ -41,7 +39,6 @@ $ZSH_THEME_REPO_NAME_COLOR$_DISPLAY$ZSH_PROMPT_BASE_COLOR$ZSH_PROMPT_BASE_COLOR$
|
|||
}
|
||||
|
||||
function hg_dirty_choose {
|
||||
if [ $(in_hg) ]; then
|
||||
hg status 2> /dev/null | command grep -Eq '^\s*[ACDIM!?L]'
|
||||
if [ $pipestatus[-1] -eq 0 ]; then
|
||||
# Grep exits with 0 when "One or more lines were selected", return "dirty".
|
||||
|
|
@ -50,7 +47,6 @@ function hg_dirty_choose {
|
|||
# Otherwise, no lines were found, or an error occurred. Return clean.
|
||||
echo $2
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
function hg_dirty {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue