Added fortune to login
This commit is contained in:
74
.zshrc
74
.zshrc
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
# If you come from bash you might have to change your $PATH.
|
# If you come from bash you might have to change your $PATH.
|
||||||
# export PATH=$HOME/bin:/usr/local/bin:$PATH
|
# export PATH=$HOME/bin:/usr/local/bin:$PATH
|
||||||
|
|
||||||
@@ -60,7 +59,6 @@ plugins=(
|
|||||||
zsh-syntax-highlighting
|
zsh-syntax-highlighting
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
# User configuration
|
# User configuration
|
||||||
# ---------------------------------------------------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------------------------------------------------
|
||||||
# ==> Source External Configs
|
# ==> Source External Configs
|
||||||
@@ -93,33 +91,39 @@ setopt share_history
|
|||||||
|
|
||||||
# ---------------------------------------------------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------------------------------------------------
|
||||||
# ==> KEY BINDINGS - from https://dougblack.io/words/zsh-vi-mode.html
|
# ==> KEY BINDINGS - from https://dougblack.io/words/zsh-vi-mode.html
|
||||||
|
# Commented out on 2021-02-09 in favor of learning emacs bindings
|
||||||
#
|
#
|
||||||
bindkey -v
|
#bindkey -v
|
||||||
bindkey '^P' up-history
|
#bindkey '^P' up-history
|
||||||
bindkey '^N' down-history
|
#bindkey '^N' down-history
|
||||||
bindkey '^?' backward-delete-char
|
#bindkey '^?' backward-delete-char
|
||||||
bindkey '^h' backward-delete-char
|
#bindkey '^h' backward-delete-char
|
||||||
bindkey '^w' backward-kill-word
|
#bindkey '^w' backward-kill-word
|
||||||
bindkey '^r' history-incremental-search-backward
|
#bindkey '^r' history-incremental-search-backward
|
||||||
|
#
|
||||||
bindkey "\e[1~" beginning-of-line
|
#bindkey "\e[1~" beginning-of-line
|
||||||
bindkey "\e[4~" end-of-line
|
#bindkey "\e[4~" end-of-line
|
||||||
bindkey "\e[5~" beginning-of-history
|
#bindkey "\e[5~" beginning-of-history
|
||||||
bindkey "\e[6~" end-of-history
|
#bindkey "\e[6~" end-of-history
|
||||||
bindkey "\e[3~" delete-char
|
#bindkey "\e[3~" delete-char
|
||||||
bindkey "\e[2~" quoted-insert
|
#bindkey "\e[2~" quoted-insert
|
||||||
bindkey "\e[5C" forward-word
|
#bindkey "\e[5C" forward-word
|
||||||
bindkey "\eOc" emacs-forward-word
|
#bindkey "\eOc" emacs-forward-word
|
||||||
bindkey "\e[5D" backward-word
|
#bindkey "\e[5D" backward-word
|
||||||
bindkey "\eOd" emacs-backward-word
|
#bindkey "\eOd" emacs-backward-word
|
||||||
bindkey "\ee[C" forward-word
|
#bindkey "\ee[C" forward-word
|
||||||
bindkey "\ee[D" backward-word
|
#bindkey "\ee[D" backward-word
|
||||||
|
#
|
||||||
bindkey "^H" backward-delete-word
|
#bindkey "^H" backward-delete-word
|
||||||
|
|
||||||
|
# ---------------------------------------------------------------------------------------------------------------------
|
||||||
|
# ==> KEY BINDINGS - EMACS bindings because I work on lots of different machines
|
||||||
|
# so I should get used to the defaults
|
||||||
|
#
|
||||||
|
bindkey -e
|
||||||
|
setopt interactivecomments
|
||||||
export KEYTIMEOUT=1
|
export KEYTIMEOUT=1
|
||||||
|
|
||||||
|
|
||||||
# ---------------------------------------------------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------------------------------------------------
|
||||||
# ==> FZF
|
# ==> FZF
|
||||||
#
|
#
|
||||||
@@ -128,12 +132,18 @@ export KEYTIMEOUT=1
|
|||||||
export FZF_DEFAULT_COMMAND='find .'
|
export FZF_DEFAULT_COMMAND='find .'
|
||||||
|
|
||||||
# ---------------------------------------------------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------------------------------------------------
|
||||||
# ==> set PATH so it includes user's private ~/bin if it exists
|
# ==> set PATH so it includes user's private ~/bin if present
|
||||||
PATH="$HOME/.local/bin:$HOME/bin:$PATH"
|
PATH="$PATH:$HOME/.local/bin:$HOME/bin"
|
||||||
|
|
||||||
|
# ---------------------------------------------------------------------------------------------------------------------
|
||||||
|
# ==> set PATH so it includes /usr/games if present
|
||||||
|
PATH="$PATH:/usr/games"
|
||||||
|
|
||||||
|
# ---------------------------------------------------------------------------------------------------------------------
|
||||||
|
# ==> Powerlevel10k https://github.com/romkatv/powerlevel10k
|
||||||
|
#
|
||||||
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
|
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
|
||||||
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh
|
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh
|
||||||
|
|
||||||
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.
|
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.
|
||||||
# Initialization code that may require console input (password prompts, [y/n]
|
# Initialization code that may require console input (password prompts, [y/n]
|
||||||
# confirmations, etc.) must go above this block, everything else may go below.
|
# confirmations, etc.) must go above this block, everything else may go below.
|
||||||
@@ -141,8 +151,14 @@ if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]
|
|||||||
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
|
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Enable rootless control of virsh, if installed
|
# ---------------------------------------------------------------------------------------------------------------------
|
||||||
|
# ==> Enable rootless control of virsh, if installed
|
||||||
|
#
|
||||||
if [[ -f /usr/bin/virsh ]]; then
|
if [[ -f /usr/bin/virsh ]]; then
|
||||||
export LIBVIRT_DEFAULT_URI=qemu:///system
|
export LIBVIRT_DEFAULT_URI=qemu:///system
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# ---------------------------------------------------------------------------------------------------------------------
|
||||||
|
# ==> Show me a fortune tux when I log in!
|
||||||
|
#
|
||||||
|
fortune -a | cowsay -f tux
|
||||||
|
|||||||
Reference in New Issue
Block a user