mirror of
https://github.com/dcarrillo/prezto.git
synced 2025-06-14 08:41:43 +00:00
Simplified option variables for greater flexibility.
This commit is contained in:
@ -2,11 +2,11 @@
|
||||
|
||||
source "${0:r:r}.zsh"
|
||||
|
||||
if test "$CASE_SENSITIVE" = true; then
|
||||
if check-bool "$CASE_SENSITIVE"; then
|
||||
unset HISTORY_SUBSTRING_SEARCH_GLOBBING_FLAGS
|
||||
fi
|
||||
|
||||
if test "$DISABLE_COLOR" = true; then
|
||||
if ! check-bool "$COLOR"; then
|
||||
unset HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_FOUND
|
||||
unset HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_NOT_FOUND
|
||||
fi
|
||||
|
@ -11,7 +11,7 @@ alias sn="screen -U -S"
|
||||
alias sr="screen -a -A -U -D -R"
|
||||
|
||||
# Auto
|
||||
if (( $SHLVL == 1 )) && ! check-bool "$DISABLE_AUTO_SCREEN"; then
|
||||
if (( $SHLVL == 1 )) && check-bool "$AUTO_SCREEN"; then
|
||||
(( SHLVL += 1 )) && export SHLVL
|
||||
session="$(screen -list 2> /dev/null | sed '1d;$d' | awk '{print $1}' | head -1)"
|
||||
if [[ -n "$session" ]]; then
|
||||
|
@ -40,7 +40,7 @@ function _ssh-agent-start() {
|
||||
|
||||
# Test if agent-forwarding is enabled.
|
||||
zstyle -b :omz:plugins:ssh-agent agent-forwarding _ssh_agent_forwarding
|
||||
if [[ "${_ssh_agent_forwarding}" == "yes" && -n "$SSH_AUTH_SOCK" ]]; then
|
||||
if check-bool "${_ssh_agent_forwarding}" && [[ -n "$SSH_AUTH_SOCK" ]]; then
|
||||
# Add a nifty symlink for screen/tmux if agent forwarding.
|
||||
[[ -L "$SSH_AUTH_SOCK" ]] || ln -sf "$SSH_AUTH_SOCK" /tmp/ssh-agent-$USER-screen
|
||||
elif [ -f "${_ssh_agent_env}" ]; then
|
||||
|
@ -10,7 +10,7 @@ alias ta="tmux attach-session"
|
||||
alias tl="tmux list-sessions"
|
||||
|
||||
# Auto
|
||||
if (( $SHLVL == 1 )) && ! check-bool "$DISABLE_AUTO_TMUX"; then
|
||||
if (( $SHLVL == 1 )) && check-bool "$AUTO_TMUX"; then
|
||||
(( SHLVL += 1 )) && export SHLVL
|
||||
session="$(tmux list-sessions 2> /dev/null | cut -d':' -f1 | head -1)"
|
||||
if [[ -n "$session" ]]; then
|
||||
|
Reference in New Issue
Block a user