2018-05-03 20:23:53 +02:00
|
|
|
# Path to your oh-my-zsh installation.
|
2023-02-18 22:29:26 +01:00
|
|
|
export ZSH=/usr/share/oh-my-zsh
|
2018-05-03 20:23:53 +02:00
|
|
|
|
|
|
|
# Uncomment the following line to use case-sensitive completion.
|
|
|
|
CASE_SENSITIVE="true"
|
|
|
|
|
2023-02-18 22:29:26 +01:00
|
|
|
# Disable auto-update
|
|
|
|
zstyle ':omz:update' mode disabled
|
2018-05-03 20:23:53 +02:00
|
|
|
|
|
|
|
# Uncomment the following line to display red dots whilst waiting for completion.
|
|
|
|
COMPLETION_WAITING_DOTS="true"
|
|
|
|
|
|
|
|
# Uncomment the following line if you want to change the command execution time
|
|
|
|
# stamp shown in the history command output.
|
|
|
|
# The optional three formats: "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd"
|
|
|
|
HIST_STAMPS="dd.mm.yyyy"
|
2023-02-20 14:03:38 +01:00
|
|
|
# Global history search
|
|
|
|
HISTFILE=~/.zsh_history
|
|
|
|
HISTSIZE=10000
|
|
|
|
SAVEHIST=10000
|
2018-05-03 20:23:53 +02:00
|
|
|
|
|
|
|
# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*)
|
|
|
|
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/
|
|
|
|
# Example format: plugins=(rails git textmate ruby lighthouse)
|
|
|
|
# Add wisely, as too many plugins slow down shell startup.
|
|
|
|
plugins=(
|
2023-02-18 22:29:26 +01:00
|
|
|
# acs command → print aliases by group
|
|
|
|
aliases
|
2018-05-03 20:23:53 +02:00
|
|
|
colored-man-pages
|
2023-02-18 22:29:26 +01:00
|
|
|
# cat with colors → ccat or cless
|
|
|
|
colorize
|
|
|
|
# commands to copy file content or absolute path to clipboard
|
|
|
|
copyfile
|
|
|
|
copypath
|
|
|
|
# cpv command which uses rsync
|
2018-05-03 20:23:53 +02:00
|
|
|
cp
|
2023-02-18 22:29:26 +01:00
|
|
|
# docker autocomplete
|
2018-05-03 20:23:53 +02:00
|
|
|
docker
|
2023-02-18 22:29:26 +01:00
|
|
|
# unique command for most archives
|
|
|
|
extract
|
2023-12-18 20:00:52 +01:00
|
|
|
# fish-like highlighting as you type
|
|
|
|
fast-syntax-highlighting
|
2023-02-20 14:03:38 +01:00
|
|
|
# fuzzy finder for history, files, docker, process, etc (see fzf)
|
|
|
|
fzf-zsh-plugin
|
2023-02-18 22:29:26 +01:00
|
|
|
# aliases
|
|
|
|
git
|
|
|
|
# password-store autocomplete
|
|
|
|
pass
|
2023-02-20 14:03:38 +01:00
|
|
|
# fish-like completion as you type
|
|
|
|
zsh-autosuggestions
|
2018-05-03 20:23:53 +02:00
|
|
|
)
|
|
|
|
|
2023-02-18 22:29:26 +01:00
|
|
|
# Enable option stacking in autocomplete, i.e. docker run -it <TAB>
|
|
|
|
zstyle ':completion:*:*:docker:*' option-stacking yes
|
|
|
|
zstyle ':completion:*:*:docker-*:*' option-stacking yes
|
2018-05-03 20:23:53 +02:00
|
|
|
|
2023-02-18 22:29:26 +01:00
|
|
|
# Load ZSH
|
|
|
|
source $ZSH/oh-my-zsh.sh
|
2018-05-03 20:23:53 +02:00
|
|
|
|
2023-12-18 20:00:52 +01:00
|
|
|
# Use Quick Term prompt theme made for Oh My Posh, in zsh
|
2024-01-21 22:22:56 +01:00
|
|
|
eval "$(oh-my-posh init zsh --config ~/.config/theme/quick-term.omp.json)"
|
2023-12-18 19:13:52 +01:00
|
|
|
|
2023-12-19 21:32:31 +01:00
|
|
|
# And use Catppuccin Mocha theme for ZSH fast hightlight plugin (LOCAL means searching in /usr/local/share/fsh)
|
2023-12-18 21:58:40 +01:00
|
|
|
fast-theme LOCAL:catppuccin-mocha >/dev/null
|
2023-12-18 20:00:52 +01:00
|
|
|
|
2018-05-03 20:23:53 +02:00
|
|
|
# Preferred editor for local and remote sessions
|
2023-02-18 22:29:26 +01:00
|
|
|
export EDITOR=vim
|
2018-05-03 20:23:53 +02:00
|
|
|
|
|
|
|
# Do not print user@hostname if user is myself
|
2019-01-08 20:01:04 +01:00
|
|
|
DEFAULT_USER=`whoami`
|
2018-05-03 20:23:53 +02:00
|
|
|
|
|
|
|
# To use when .cfg contains a bare git repo.
|
|
|
|
# See this https://developer.atlassian.com/blog/2016/02/best-way-to-store-dotfiles-git-bare-repo/
|
|
|
|
alias config='/usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME'
|
2019-02-05 18:17:30 +01:00
|
|
|
|
2023-12-18 19:13:52 +01:00
|
|
|
# Use GPG key for SSH authentication
|
2023-10-29 21:33:06 +01:00
|
|
|
unset SSH_AGENT_PID
|
|
|
|
if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then
|
|
|
|
export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
|
|
|
|
fi
|
2023-11-01 18:41:46 +01:00
|
|
|
export GPG_TTY="$(tty)"
|
2023-10-29 21:33:06 +01:00
|
|
|
|
2023-12-18 19:13:52 +01:00
|
|
|
# Source aliases
|
2023-03-06 16:36:20 +01:00
|
|
|
if [ -f ~/.aliases ]; then
|
|
|
|
. ~/.aliases
|
|
|
|
fi
|
2023-03-07 15:26:08 +01:00
|
|
|
|
2023-12-18 19:13:52 +01:00
|
|
|
# Source environment variables
|
2023-03-07 15:26:08 +01:00
|
|
|
if [ -f ~/.env ]; then
|
|
|
|
. ~/.env
|
|
|
|
fi
|