diff --git a/.aliases b/.aliases index 99d13ce..7d9ae4c 100644 --- a/.aliases +++ b/.aliases @@ -3,7 +3,6 @@ alias cassa="mosh vsbugge@cassarossa.samfundet.no" alias cirkus="mosh vsbugge@cirkus.samfundet.no" alias alter="mosh vsbugge@altersex.samfundet.no" alias navi="mosh vsbugge@navi.samfundet.no" -alias cassini="mosh cassini" alias kint="kinit vsbugge@AD.SAMFUNDET.NO" export GPG_TTY=$(tty) diff --git a/.gitconfig b/.gitconfig index 4166a4b..94fccd4 100644 --- a/.gitconfig +++ b/.gitconfig @@ -1,8 +1,8 @@ [init] defaultBranch = main [user] + email = vkbugge@hotmail.com name = Sebastian Bugge - useConfigOnly = true [pull] ff = false rebase = true @@ -15,11 +15,5 @@ autoSetupRemote = true [rerere] enabled = true -[advice] - skippedCherryPicks = false [help] autocorrect = 10 -[include] - path = ~/.gitconfig_local -[includeIf "gitdir:~/code/"] - path = ~/code/.gitconfig diff --git a/.zshenv b/.profile similarity index 52% rename from .zshenv rename to .profile index 37f6898..bc3fee2 100644 --- a/.zshenv +++ b/.profile @@ -1,8 +1,3 @@ -export HISTFILESIZE=1000000000 -export HISTSIZE=1000000000 - -export EDITOR='nvim' - # set PATH so it includes user's private bin if it exists if [ -d "$HOME/bin" ]; then PATH="$HOME/bin:$PATH" @@ -19,21 +14,25 @@ fi if [ -d "$HOME/go" ]; then GOPATH="$HOME/go" - GOBIN="$HOME/go/bin" - PATH="$GOBIN:$PATH" fi -ASDF_TMP=$(mktemp) -if asdf current golang >"$ASDF_TMP" 2>/dev/null; then - ASDF_GO="$HOME/.asdf/installs/golang/$(awk -F' ' '{print $2}' <"$ASDF_TMP")" +export NVM_DIR="$HOME/.nvm" +if [ -s "$NVM_DIR/nvm.sh" ]; then + \. "$NVM_DIR/nvm.sh" # This loads nvm + \. "$NVM_DIR/bash_completion" # nvm bash completions fi -if [ -d "$ASDF_GO" ]; then - ASDF_GOBIN="$ASDF_GO/packages/bin/" - PATH="$ASDF_GOBIN:$PATH" + +if [ -s "$HOME/.local_profile" ]; then + \. "$HOME/.local_profile" fi [ -f "/home/kaholaz/.ghcup/env" ] && source "/home/kaholaz/.ghcup/env" # ghcup-env +if [ -d "$HOME/.asdf" ]; then + \. "$HOME/.asdf/asdf.sh" + \. "$HOME/.asdf/completions/asdf.bash" +fi + if [ -f "$HOME/.local/share/pnpm" ]; then export PNPM_HOME="$HOME/.local/share/pnpm" case ":$PATH:" in @@ -42,8 +41,6 @@ if [ -f "$HOME/.local/share/pnpm" ]; then esac fi -export PATH="$PATH:/home/kaholaz/.cache/scalacli/local-repo/bin/scala-cli" - -# >>> coursier install directory >>> -export PATH="$PATH:/home/kaholaz/.local/share/coursier/bin" -# <<< coursier install directory <<< +if [ -n "$ZSH_VERSION" ] && type "hugo" >/dev/null; then + . <(hugo completion zsh) +fi diff --git a/.tmux.conf b/.tmux.conf index 380c9dd..b661bde 100644 --- a/.tmux.conf +++ b/.tmux.conf @@ -45,6 +45,7 @@ set-option -g allow-rename off ### DESIGN CHANGES ### ###################### +set -g default-terminal "screen-256color" set -g @plugin 'tinted-theming/base16-tmux' set -g @plugin 'thewtex/tmux-mem-cpu-load' set -g @colors-base16 'dracula' @@ -65,7 +66,7 @@ set -g status-position bottom set -g status-justify left set -g status-style 'dim' set -g status-left ' #S | ' -set -g status-right '#[bg=color237] %a %b %d #[fg=color7]%H:%M #[fg=color82,bg=color236,bold] #H ' +set -g status-right '#(curl -s wttr.in/Trondheim\?format\="%%l:+%%c%%t") #[bg=color237] %a %b %d #[fg=color7]%H:%M #[fg=color82,bg=color236,bold] #H ' set -g status-right-length 80 set -g status-left-length 20 diff --git a/.zprofile b/.zprofile deleted file mode 100644 index b706f2a..0000000 --- a/.zprofile +++ /dev/null @@ -1,13 +0,0 @@ -ASDF_TMP=$(mktemp) -if asdf current golang >"$ASDF_TMP" 2>/dev/null; then - ASDF_GO="$HOME/.asdf/installs/golang/$(awk -F' ' '{print $2}' <"$ASDF_TMP")" -fi -if [ -d "$ASDF_GO" ]; then - ASDF_GOBIN="$ASDF_GO/packages/bin/" - PATH="$ASDF_GOBIN:$PATH" -fi - -export NVM_DIR="$HOME/.nvm" -if [ -s "$NVM_DIR/nvm.sh" ]; then - \. "$NVM_DIR/nvm.sh" # This loads nvm -fi diff --git a/.zshrc b/.zshrc index 4c2c864..b90372a 100644 --- a/.zshrc +++ b/.zshrc @@ -1,3 +1,5 @@ +source ~/.profile + export ZSH="$HOME/.oh-my-zsh" ZSH_THEME="afowler" @@ -37,6 +39,13 @@ else HAS_NETWORK=0 fi +# Preferred editor for local and remote sessions +if [[ -n $SSH_CONNECTION ]]; then + export EDITOR='nvim' +else + export EDITOR='nvim' +fi + # Attach to a tmux session on startup if [ -z "$TMUX" ] && [ -n "$SSH_CONNECTION" ]; then tmux attach -t Default || tmux new -s Default @@ -50,10 +59,7 @@ if [ -z "$TMUX" ] && [[ "$HAS_NETWORK" == 1 ]]; then fortune -s fi -if [ -d "$HOME/.asdf" ]; then - \. "$HOME/.asdf/asdf.sh" -fi +export HISTFILESIZE=1000000000 +export HISTSIZE=1000000000 source ~/.aliases -fpath+=~/.zfunc -autoload -U compinit; compinit