Skip to content

Instantly share code, notes, and snippets.

@DoonDoony
Created July 15, 2022 02:57
Show Gist options
  • Save DoonDoony/237161d1e68e51ac1cf41c98fa23ca23 to your computer and use it in GitHub Desktop.
Save DoonDoony/237161d1e68e51ac1cf41c98fa23ca23 to your computer and use it in GitHub Desktop.
zsh settings (lsd, bat, fzf, pyenv, starship)
alias ls='lsd'
alias ll='ls -l'
alias la='ls -la'
alias lla='ls -la'
alias lt='ls --tree'
alias cat='bat --paging=never --theme=Dracula'
[ -f ~/Dotfiles/.fzf.zsh ] && source ~/Dotfiles/.fzf.zsh
# Setup fzf
# ---------
if [[ ! "$PATH" == */opt/homebrew/opt/fzf/bin* ]]; then
export PATH="${PATH:+${PATH}:}/opt/homebrew/opt/fzf/bin"
fi
# Auto-completion
# ---------------
[[ $- == *i* ]] && source "/opt/homebrew/opt/fzf/shell/completion.zsh" 2> /dev/null
# Key bindings
# ------------
source "/opt/homebrew/opt/fzf/shell/key-bindings.zsh"
eval "$(/opt/homebrew/bin/brew shellenv)"
if type brew &>/dev/null
then
FPATH="$(brew --prefix)/share/zsh/site-functions:${FPATH}"
autoload -Uz compinit
compinit
fi
export PYENV_VIRTUALENV_DISABLE_PROMPT=1
export PYENV_ROOT="$HOME/.pyenv"
command -v pyenv >/dev/null || export PATH="$PYENV_ROOT/bin:$PATH"
eval "$(pyenv init -)"
# Load pyenv-virtualenv automatically by adding
eval "$(pyenv virtualenv-init -)"
eval "$(starship init zsh)"
# Part of the whole .zshrc content
# Load Dotfiles
DOTFILES=($HOME/Dotfiles/.*)
for file in $DOTFILES;
do if ! [[ $file =~ "(\.git)|(\.zshrc)|(\.DS_Store)" ]];
then
source $file;
fi
done;
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
# Place this file under ~/.config/lsd/
date: '+%Y-%m-%d %X'
color:
theme: dracula
icons:
separator: " "
# Custom lsd theme (xterm-256-color)
# Place this file under ~/.config/lsd/themes/
user: 230
group: 187
permission:
read: dark_green
write: dark_yellow
exec: dark_red
exec-sticky: 5
no-access: 245
octal: 6
acl: dark_cyan
context: cyan
date:
hour-old: 123
day-old: 123
older: 123
size:
none: 245
small: 228
medium: 215
large: 210
inode:
valid: white
invalid: 245
links:
valid: 13
invalid: 245
tree-edge: 245
# Place this file under ~/.config/
[directory]
format = "[$read_only]($read_only_style)[$path]($style) "
[username]
show_always = true
[battery]
disabled = true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment