feat: add zsh plugins and update configuration files

This commit is contained in:
2025-05-28 20:51:05 +02:00
parent a3d9a4f34c
commit cc839e05c2
9 changed files with 50 additions and 10 deletions

View File

@ -1 +0,0 @@
/home/csimonis/.dotfiles/.alias.d

5
.gitignore vendored
View File

@ -1,7 +1,7 @@
/* /*
!setup !setup
!zsh/
!.gitignore !.gitignore
!.alias.d/ !.alias.d/
!.config/ !.config/
@ -10,4 +10,5 @@
!.p10k.zsh !.p10k.zsh
!.zshrc !.zshrc
!.zshenv.template !.zshenv.template
!.profile !.profile
!install

9
.gitmodules vendored Normal file
View File

@ -0,0 +1,9 @@
[submodule "zsh/plugins/zsh-autosuggestions"]
path = zsh/plugins/zsh-autosuggestions
url = https://github.com/zsh-users/zsh-autosuggestions
[submodule "zsh/plugins/zsh-syntax-highlighting"]
path = zsh/plugins/zsh-syntax-highlighting
url = https://github.com/zsh-users/zsh-syntax-highlighting
[submodule "zsh/themes/powerlevel10k"]
path = zsh/themes/powerlevel10k
url = https://github.com/romkatv/powerlevel10k

17
.zshrc
View File

@ -5,6 +5,16 @@ if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi fi
# Set custom Zsh plugin path
export ZSH_CUSTOM="$HOME/dotfiles/zsh"
# Load plugins
source $ZSH_CUSTOM/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh
source $ZSH_CUSTOM/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
# Powerlevel10k theme
source $ZSH_CUSTOM/themes/powerlevel10k/powerlevel10k.zsh-theme
# If you come from bash you might have to change your $PATH. # If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH # export PATH=$HOME/bin:/usr/local/bin:$PATH
@ -108,9 +118,6 @@ source $ZSH/oh-my-zsh.sh
# alias zshconfig="mate ~/.zshrc" # alias zshconfig="mate ~/.zshrc"
# alias ohmyzsh="mate ~/.oh-my-zsh" # alias ohmyzsh="mate ~/.oh-my-zsh"
#source <(curl -s https://cdn.simonis.lol/all.sh)
#source <(curl -s https://cdn.simonis.lol/composer.sh)
#source <(curl -s https://cdn.simonis.lol/git.sh)
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh. # To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh [[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh
@ -122,13 +129,11 @@ source $HOME/.zshenv
eval "$(direnv hook zsh)" eval "$(direnv hook zsh)"
source /home/csimonis/.zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
# Load Angular CLI autocompletion. # Load Angular CLI autocompletion.
source <(ng completion script) source <(ng completion script)
# bun completions # bun completions
[ -s "/home/csimonis/.bun/_bun" ] && source "/home/csimonis/.bun/_bun" [ -s "$HOME/.bun/_bun" ] && source "$HOME/.bun/_bun"
# bun # bun
export BUN_INSTALL="$HOME/.bun" export BUN_INSTALL="$HOME/.bun"

16
install Normal file
View File

@ -0,0 +1,16 @@
#!/usr/bin/env bash
apt update
apt upgrade -yqq
apt install -yqq \
git \
zsh \
curl \
bat \
ripgrep
curl https://sh.rustup.rs -sSf | sh
curl -sfL https://direnv.net/install.sh | bash
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
cargo install exa

9
setup
View File

@ -1,5 +1,11 @@
#!/usr/bin/env bash #!/usr/bin/env bash
sed -i -e 's/\r$//' ~/.dotfiles/* #sed -i -e 's/\r$//' ~/dotfiles/*
set -e
echo "[+] Cloning submodules..."
git submodule update --init --recursive
echo "[+] Creating Gitconfigs..."
( (
for config in $PWD/.gitconfig.d/*.gitconfig; do for config in $PWD/.gitconfig.d/*.gitconfig; do
@ -8,6 +14,7 @@ sed -i -e 's/\r$//' ~/.dotfiles/*
done; done;
) > "$HOME/.gitconfig" ) > "$HOME/.gitconfig"
echo "[+] Creating symlinks..."
ln -sf "$PWD/.zshrc" "$HOME/.zshrc" ln -sf "$PWD/.zshrc" "$HOME/.zshrc"
ln -sf "$PWD/.p10k.zsh" "$HOME/.p10k.zsh" ln -sf "$PWD/.p10k.zsh" "$HOME/.p10k.zsh"