refactor: follow arch linux zsh docs
This commit is contained in:
1 parent
d9d955be70
commit
fd46ba319e
5 files changed
+22
-18
No files matched your search
@@ -0,0 +1,2 @@
|
||||
export XDG_CONFIG_HOME="${HOME}/.config"
|
||||
export ZDOTDIR="${XDG_CONFIG_HOME}/zsh"
|
||||
+17
-10
@@ -3,25 +3,32 @@
|
||||
# workaround for vscode terminal
|
||||
[[ -z "${XDG_CONFIG_HOME}" ]] && export XDG_CONFIG_HOME="${HOME}/.config"
|
||||
[[ -z "${ZDOTDIR}" ]] && export ZDOTDIR="${XDG_CONFIG_HOME}/zsh"
|
||||
HISTFILE="$HOME"/.zsh_history
|
||||
|
||||
|
||||
# some useful options (man zshoptions)
|
||||
setopt autocd extendedglob nomatch menucomplete
|
||||
setopt interactive_comments
|
||||
setopt AUTO_CD EXTENDED_GLOB NOMATCH MENU_COMPLETE
|
||||
setopt INTERACTIVE_COMMENTS
|
||||
stty stop undef # Disable ctrl-s to freeze terminal.
|
||||
zle_highlight=('paste:none')
|
||||
|
||||
# history
|
||||
setopt appendhistory
|
||||
setopt incappendhistory # Immediately append commands to history file.
|
||||
setopt histignoredups # Never add duplicate entries.
|
||||
setopt histignorespace # Ignore commands that start with a space.
|
||||
setopt histreduceblanks # Remove unnecessary blank lines.
|
||||
setopt APPEND_HISTORY
|
||||
setopt INC_APPEND_HISTORY
|
||||
setopt HIST_EXPIRE_DUPS_FIRST
|
||||
setopt HIST_IGNORE_DUPS
|
||||
setopt HIST_IGNORE_ALL_DUPS
|
||||
setopt HIST_IGNORE_SPACE
|
||||
setopt HIST_FIND_NO_DUPS
|
||||
setopt HIST_SAVE_NO_DUPS
|
||||
|
||||
unsetopt EXTENDED_HISTORY
|
||||
|
||||
# beeping is annoying
|
||||
unsetopt beep
|
||||
unsetopt BEEP
|
||||
|
||||
# remove % symbol on prompt
|
||||
unsetopt promptsp
|
||||
unsetopt PROMPT_SP
|
||||
|
||||
# completions
|
||||
|
||||
@@ -52,7 +59,7 @@ source "$ZDOTDIR/zsh-functions"
|
||||
# Normal files to source
|
||||
zsh_add_file "zsh-exports"
|
||||
zsh_add_file "zsh-aliases"
|
||||
zsh_add_file "zsh-prompt"
|
||||
zsh_add_file "zsh-eval"
|
||||
|
||||
# Plugins
|
||||
repos=(
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
# Set PATH, MANPATH, etc., for Homebrew.
|
||||
#!/usr/bin/env bash
|
||||
|
||||
[ -f /opt/homebrew/bin/brew ] && eval "$(/opt/homebrew/bin/brew shellenv)"
|
||||
command -v fnm > /dev/null 2>&1 && eval "$(fnm env --use-on-cd)"
|
||||
command -v zoxide > /dev/null 2>&1 && eval "$(zoxide init zsh)"
|
||||
command -v starship > /dev/null 2>&1 && eval "$(starship init zsh)"
|
||||
@@ -1,10 +1,10 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
HISTSIZE=1000000
|
||||
SAVEHIST=1000000
|
||||
|
||||
export PATH="$HOME/.local/bin":$PATH
|
||||
export MANWIDTH=999
|
||||
export HISTFILE="$ZDOTDIR"/.zsh_history
|
||||
export PATH="$HOME/.local/bin":$PATH
|
||||
|
||||
export EDITOR="micro"
|
||||
export PAGE="bat"
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
command -v starship > /dev/null 2>&1 && eval "$(starship init zsh)"
|
||||
Reference in new issue
Block a user