style: align bash guard with shfmt
This commit is contained in:
parent
97f89e3ee3
commit
6b71292dd1
|
|
@ -74,7 +74,7 @@ mod tests {
|
||||||
) {
|
) {
|
||||||
let opts = Opts { cmd, hook, echo, resolve_symlinks };
|
let opts = Opts { cmd, hook, echo, resolve_symlinks };
|
||||||
let source = Bash(&opts).render().unwrap();
|
let source = Bash(&opts).render().unwrap();
|
||||||
assert!(source.contains("[[ -n \"${__zoxide_result}\" ]] || return"));
|
assert!(source.contains("[[ -n ${__zoxide_result} ]] || return"));
|
||||||
}
|
}
|
||||||
|
|
||||||
#[apply(opts)]
|
#[apply(opts)]
|
||||||
|
|
|
||||||
|
|
@ -179,7 +179,7 @@ if [[ ${BASH_VERSINFO[0]:-0} -eq 4 && ${BASH_VERSINFO[1]:-0} -ge 4 || ${BASH_VER
|
||||||
elif [[ -z ${COMP_WORDS[-1]} ]]; then
|
elif [[ -z ${COMP_WORDS[-1]} ]]; then
|
||||||
# shellcheck disable=SC2312
|
# shellcheck disable=SC2312
|
||||||
__zoxide_result="$(\command zoxide query --exclude "$(__zoxide_pwd)" --interactive -- "{{ "${COMP_WORDS[@]:1:${#COMP_WORDS[@]}-2}" }}")" || return
|
__zoxide_result="$(\command zoxide query --exclude "$(__zoxide_pwd)" --interactive -- "{{ "${COMP_WORDS[@]:1:${#COMP_WORDS[@]}-2}" }}")" || return
|
||||||
[[ -n "${__zoxide_result}" ]] || return
|
[[ -n ${__zoxide_result} ]] || return
|
||||||
|
|
||||||
# In case the terminal does not respond to \e[5n or another
|
# In case the terminal does not respond to \e[5n or another
|
||||||
# mechanism steals the response, it is still worth completing
|
# mechanism steals the response, it is still worth completing
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue