Optimize _lp_sl/sr/sb
This commit is contained in:
parent
7e01b1648c
commit
81bc91d4dc
13
liquidprompt
13
liquidprompt
@ -1325,26 +1325,19 @@ _lp_smart_mark()
|
||||
# insert a space on the right
|
||||
_lp_sr()
|
||||
{
|
||||
if [[ ! -z "$1" ]] ; then
|
||||
echo -n "$1 "
|
||||
fi
|
||||
[[ -n "$1" ]] && echo -n "$1 "
|
||||
}
|
||||
|
||||
# insert a space on the left
|
||||
_lp_sl()
|
||||
{
|
||||
if [[ ! -z "$1" ]] ; then
|
||||
echo -n " $1"
|
||||
fi
|
||||
[[ -n "$1" ]] && echo -n " $1"
|
||||
}
|
||||
|
||||
# insert two space, before and after
|
||||
_lp_sb()
|
||||
{
|
||||
if [[ ! -z "$1" ]] ; then
|
||||
echo -n " $1 "
|
||||
fi
|
||||
|
||||
[[ -n "$1" ]] && echo -n " $1 "
|
||||
}
|
||||
|
||||
###################
|
||||
|
Loading…
x
Reference in New Issue
Block a user