Last active
May 31, 2021 00:42
-
-
Save ed1d1a8d/54841c2b1862de1bc360c206a8b47a96 to your computer and use it in GitHub Desktop.
Zsh config
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc. | |
# Initialization code that may require console input (password prompts, [y/n] | |
# confirmations, etc.) must go above this block; everything else may go below. | |
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then | |
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" | |
fi | |
# Begin history configuration | |
HISTFILE=~/.zsh_history | |
HISTSIZE=1000000000 # max events to load into memory | |
SAVEHIST=$HISTSIZE # max events to save to HISTFILE | |
setopt EXTENDED_HISTORY # save with timestamps | |
export HISTTIMEFORMAT="[%F %T] " # output with timestamps | |
setopt SHARE_HISTORY # immediately append and share between sessions | |
setopt HIST_FIND_NO_DUPS # no duplicates with ctrl-R | |
# End history configuration | |
# Begin misc options | |
setopt beep # beep on error | |
setopt extendedglob | |
unsetopt autocd | |
bindkey -e # ctrl-a, ctrl-e, etc. | |
export EDITOR="vim" | |
# End misc options | |
# Begin brew shell completion stuff | |
if type brew &>/dev/null; then | |
FPATH=$(brew --prefix)/share/zsh/site-functions:$FPATH | |
autoload -Uz compinit | |
compinit | |
fi | |
# End brew shell completion stuff | |
# Begin powerlevel10k stuff | |
source /usr/local/opt/powerlevel10k/powerlevel10k.zsh-theme | |
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh. | |
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh | |
# End powerlevel10k stuff | |
# Begin aliases | |
alias ls="ls -G" | |
alias radio="mpv https://stream.r-a-d.io/main.mp3" | |
alias hist="history -i 1" | |
# End aliases |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment