diff --git a/bootstrap.sh b/bootstrap.sh index b1fdd51..356d235 100755 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -2,23 +2,25 @@ set -e -if [ $SPIN ]; then - DOTFILES="$HOME/dotfiles" -else - DOTFILES="$(dirname -- "$(readlink -f -- "$0")")" -fi - +DOTFILES="$(dirname -- "$(readlink -f -- "$0")")" echo "🐚 Installing dotfiles from '$DOTFILES'..." +mkdir -p ~/.config/wezterm ln -sf "$DOTFILES/ackrc" ~/.ackrc ln -sf "$DOTFILES/gitconfig" ~/.gitconfig ln -sf "$DOTFILES/inputrc" ~/.inputrc +ln -sf "$DOTFILES/starship.toml" ~/.config/starship.toml ln -sf "$DOTFILES/tmux.conf" ~/.tmux.conf +ln -sf "$DOTFILES/wezterm.lua" ~/.config/wezterm/wezterm.lua ln -sf "$DOTFILES/zshenv" ~/.zshenv ln -sf "$DOTFILES/zshrc" ~/.zshrc -mkdir -p ~/.config -ln -sf "$DOTFILES/starship.toml" ~/.config/starship.toml + +### Vim + +if ! (command -v dpkg-query >/dev/null 2>&1 && dpkg-query --list vim >/dev/null 2>&1); then + sudo apt install vim +fi if [ ! -d ~/.vim ]; then git clone --quiet https://github.com/deuxpi/dotvim.git ~/.vim @@ -29,6 +31,9 @@ fi mkdir -p ~/.config/coc/ vim +'PlugInstall --sync' +qa + +### Oh My Zsh! + if [ ! -d ~/.oh-my-zsh ]; then sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended --keep-zshrc fi @@ -41,9 +46,19 @@ fi mkdir -p ~/.oh-my-zsh/custom/themes ln -sf "$DOTFILES/themes/witchhazelhypercolor.zsh-theme" ~/.oh-my-zsh/custom/themes/witchhazelhypercolor.zsh-theme + +### Starship + if ! [ -x "$(command -v starship)" ]; then sh -c "$(curl -fsSL https://starship.rs/install.sh)" -- -y fi -mkdir -p ~/.config/kitty/ -ln -sf "$DOTFILES/kitty.conf" ~/.config/kitty/kitty.conf + +### Wezterm + +if ! [ -x "$(command -v wezterm)" ]; then + curl -LO https://github.com/wez/wezterm/releases/download/20220101-133340-7edc5b5a/WezTerm-20220101-133340-7edc5b5a-Ubuntu18.04.AppImage + chmod +x WezTerm-20220101-133340-7edc5b5a-Ubuntu18.04.AppImage + mkdir -p ~/.local/bin + mv WezTerm-20220101-133340-7edc5b5a-Ubuntu18.04.AppImage ~/.local/bin/wezterm +fi diff --git a/starship.toml b/starship.toml index 91a3980..6c343b4 100644 --- a/starship.toml +++ b/starship.toml @@ -3,17 +3,26 @@ command_timeout = 10000 [docker_context] disabled = true +[character] +success_symbol = "✨" +error_symbol = "💥" + [gcloud] disabled = true +[git_branch] +symbol = ":" +format = "[on](italic) [$symbol$branch]($style) " + +[git_state] +cherry_pick = "[🍒 PICKING](bold red)" + [git_status] -conflicted = "🏳" -ahead = "🏎💨" -behind = "😰" -diverged = "😵" -untracked = "🤷‍" +format = '([$all_status$ahead_behind]($style) )' +ahead = '[↑$count](green)' +behind = '[↓$count](red)' +diverged = '[↑$ahead_count](green) [↓$behind_count](red)' +untracked = "?" stashed = "📦" -modified = "📝" -staged = '[++\($count\)](green)' -renamed = "👅" -deleted = "🗑" +modified = '[📝\($count\)](yellow) ' +staged = '[+\($count\)](green)' diff --git a/wezterm.lua b/wezterm.lua new file mode 100644 index 0000000..77ad1c9 --- /dev/null +++ b/wezterm.lua @@ -0,0 +1,20 @@ +local wezterm = require 'wezterm'; +return { + colors = { + foreground = "#f8f8f2", + background = "#282634", + cursor_bg = "#f8f8f0", + cursor_border = "#f8f8f0", + cursor_fg = "#060709", + selection_bg = "#8077a8", + selection_fg = "#f6e1ce", + ansi = {"#040303","#f92672","#c2ffdf","#e6c000","#c2ffdf","#ffb8d1","#c5a3ff","#f8f8f0"}, + brights = {"#6090cb","#ff857f","#c2ffdf","#ffea00","#c2ffdf","#ffb8d1","#c5a3ff","#f8f8f0"}, + }, + font = wezterm.font_with_fallback({ + {family="IBM Plex Mono", weight="DemiBold"}, + "FreeMono", + }), + initial_cols = 140, + initial_rows = 50, +} diff --git a/zshrc b/zshrc index ab48ac8..081be23 100644 --- a/zshrc +++ b/zshrc @@ -123,8 +123,8 @@ source $ZSH/oh-my-zsh.sh # alias zshconfig="mate ~/.zshrc" # alias ohmyzsh="mate ~/.oh-my-zsh" -alias ssh="kitty +kitten ssh" -alias icat="kitty icat --align=left" +alias ssh="wezterm ssh" +alias icat="wezterm imgcat" alias isvg="rsvg-convert | icat" alias idot='dot -Tsvg -Gbgcolor="transparent" -Ecolor="#f8f8f2ff" -Efontcolor="#f8f8f2ff" -Efontname="IBM Plex Mono Semibold" -Ncolor="#f8f8f2ff" -Nfontcolor="#f8f8f2ff" -Nfontname="IBM Plex Mono Semibold" | isvg'