mirror of
https://codeberg.org/frosty/dotfiles.git
synced 2024-09-19 11:47:09 -04:00
(zsh): convert bash data to zsh + try some plugins
This commit is contained in:
parent
cd9ee5be15
commit
af49443f5d
6
.gitmodules
vendored
Normal file
6
.gitmodules
vendored
Normal file
|
@ -0,0 +1,6 @@
|
|||
[submodule ".local/share/zsh/plugins/zsh-syntax-highlighting"]
|
||||
path = .local/share/zsh/plugins/zsh-syntax-highlighting
|
||||
url = https://github.com/zsh-users/zsh-syntax-highlighting.git
|
||||
[submodule ".local/share/zsh/plugins/zsh-autosuggestions"]
|
||||
path = .local/share/zsh/plugins/zsh-autosuggestions
|
||||
url = https://github.com/zsh-users/zsh-autosuggestions.git
|
1
.local/share/zsh/plugins/zsh-autosuggestions
Submodule
1
.local/share/zsh/plugins/zsh-autosuggestions
Submodule
|
@ -0,0 +1 @@
|
|||
Subproject commit c3d4e576c9c86eac62884bd47c01f6faed043fc5
|
1
.local/share/zsh/plugins/zsh-syntax-highlighting
Submodule
1
.local/share/zsh/plugins/zsh-syntax-highlighting
Submodule
|
@ -0,0 +1 @@
|
|||
Subproject commit e0165eaa730dd0fa321a6a6de74f092fe87630b0
|
41
.zprofile
Normal file
41
.zprofile
Normal file
|
@ -0,0 +1,41 @@
|
|||
# shellcheck disable=SC2155
|
||||
|
||||
[ -f "$HOME/.zshrc" ] && . "$HOME/.zshrc"
|
||||
|
||||
# XDG base directories
|
||||
export XDG_DATA_HOME="${XDG_DATA_HOME:-$HOME/.local/share}"
|
||||
export XDG_CONFIG_HOME="${XDG_CONFIG_HOME:-$HOME/.config}"
|
||||
export XDG_STATE_HOME="${XDG_STATE_HOME:-$HOME/.local/state}"
|
||||
export XDG_CACHE_HOME="${XDG_CACHE_HOME:-$HOME/.cache}"
|
||||
|
||||
# Default programs
|
||||
export TERMINAL="${TERMINAL:-st}"
|
||||
export EDITOR="${EDITOR:-nvim}"
|
||||
export BROWSER="${BROWSER:-firefox}"
|
||||
|
||||
# $HOME cleanup
|
||||
export HISTFILE="$XDG_STATE_HOME/zsh/history"
|
||||
export XAUTHORITY="$XDG_RUNTIME_DIR/Xauthority"
|
||||
export XCURSOR_PATH="/usr/share/icons:$XDG_DATA_HOME/icons"
|
||||
export GNUPGHOME="$XDG_DATA_HOME/gnupg"
|
||||
export GOPATH="$XDG_DATA_HOME/go"
|
||||
export RUSTUP_HOME="$XDG_DATA_HOME/rustup"
|
||||
export CARGO_HOME="$XDG_DATA_HOME/cargo"
|
||||
export NPM_CONFIG_USERCONFIG="$XDG_CONFIG_HOME/npm/npmrc"
|
||||
export NODE_REPL_HISTORY="$XDG_DATA_HOME/node_repl_history"
|
||||
export CUDA_CACHE_PATH="$XDG_CACHE_HOME/nv"
|
||||
|
||||
# Other program settings
|
||||
export SVDIR="$XDG_CONFIG_HOME/service"
|
||||
export PIPX_BIN_DIR="$XDG_DATA_HOME/pipx/bin"
|
||||
export _JAVA_OPTIONS="-Djava.util.prefs.userRoot=$XDG_CONFIG_HOME/java"
|
||||
|
||||
# $PATH additions
|
||||
export PATH="$PATH:$(find "$HOME/.local/bin/" -type d | paste -sd ':' -)"
|
||||
export PATH="$PATH:$GOPATH/bin"
|
||||
export PATH="$PATH:$XDG_DATA_HOME/pipx/bin"
|
||||
export PATH="$PATH:$HOME/.cabal/bin"
|
||||
export PATH="$PATH:$XDG_DATA_HOME/npm/bin"
|
||||
|
||||
# Automatic graphical start on tty1
|
||||
[ "$(tty)" = "/dev/tty1" ] && ! pidof -s Xorg >/dev/null 2>&1 && exec startx
|
53
.zshrc
Normal file
53
.zshrc
Normal file
|
@ -0,0 +1,53 @@
|
|||
case "$-" in
|
||||
*i*) ;;
|
||||
*) return ;;
|
||||
esac
|
||||
|
||||
[ -f "$HOME/.ghcup/env" ] && . "$HOME/.ghcup/env"
|
||||
|
||||
setopt EXTENDED_HISTORY
|
||||
setopt INC_APPEND_HISTORY
|
||||
setopt SHARE_HISTORY
|
||||
setopt HIST_EXPIRE_DUPS_FIRST
|
||||
setopt HIST_SAVE_NO_DUPS
|
||||
setopt HIST_VERIFY
|
||||
setopt APPEND_HISTORY
|
||||
setopt HIST_NO_STORE
|
||||
|
||||
HISTFILESIZE=100000
|
||||
HISTCONTROL="ignoredups"
|
||||
|
||||
alias v='nvim'
|
||||
alias vim='nvim'
|
||||
|
||||
alias ll='ls -lAF'
|
||||
alias la='ls -AF'
|
||||
|
||||
alias cp='cp -iv'
|
||||
alias mv='mv -iv'
|
||||
alias rm='rm -vI'
|
||||
alias mkdir='mkdir -pv'
|
||||
alias ls='ls --color=auto'
|
||||
alias grep='grep --color=auto'
|
||||
alias wget="wget --hsts-file='$XDG_DATA_HOME/wget-hsts'"
|
||||
|
||||
alias ipp='curl https://ipinfo.io/ip && echo'
|
||||
alias ipl='monitors local_ip'
|
||||
|
||||
skli() {
|
||||
[ -f config.h ] && rm config.h
|
||||
make || return
|
||||
doas make install
|
||||
}
|
||||
|
||||
PROMPT=$'%{\e[1;32m%}%n@%M%{\e[1;34m%} %~ %%%{\e[0m%} '
|
||||
|
||||
clear
|
||||
fastfetch
|
||||
|
||||
if [ -d "${XDG_DATA_HOME:-$HOME/.local/share}/zsh/plugins" ]; then
|
||||
for plugin in "${XDG_DATA_HOME:-$HOME/.local/share}"/zsh/plugins/*/*.plugin.zsh; do
|
||||
. "$plugin"
|
||||
done
|
||||
unset plugin
|
||||
fi
|
Loading…
Reference in a new issue