Skip to content

Instantly share code, notes, and snippets.

@krasnobaev
Last active February 8, 2024 15:53
Show Gist options
  • Save krasnobaev/6baeeca6ef09ff6dd816e69eab95e9b6 to your computer and use it in GitHub Desktop.
Save krasnobaev/6baeeca6ef09ff6dd816e69eab95e9b6 to your computer and use it in GitHub Desktop.
Basic server env
[init]
defaultBranch = main
[user]
email = user@mail.org
name = User Name
[alias]
set-upstream = !git branch --set-upstream-to=origin/`git symbolic-ref --short HEAD`
[push]
autoSetupRemote = true
[credential]
helper = store
# helper = cache --timeout=3600000
[core]
excludesFile = ~/.gitignore
# git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm
# CTRL+B SHIFT+I to install plugins
# # type this in terminal if tmux is already running
# $ tmux source ~/.tmux.conf
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-yank'
set -g @plugin 'tmux-plugins/tmux-pain-control'
set -g @plugin 'tmux-plugins/tmux-cpu'
set -g status-right '#{cpu_bg_color} CPU: #{cpu_icon} #{cpu_percentage}, #{cpu_temp}˚C | %a %h-%d %H:%M '
set-option -g mouse on
set -g @plugin 'nhdaly/tmux-better-mouse-mode'
run '~/.tmux/plugins/tpm/tpm'
# hotkeys
bind -n "C-\\" last-window
# other options
set -g base-index 1
setw -g pane-base-index 1
set paste
set mouse=a
# install oh-my-zsh
# sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
# start tmux session on connect or use existing one
if [[ -z $TMUX ]] && [[ -n $SSH_TTY ]]; then
exec tmux new-session -A -s mysession
# exec tmux -S /var/tmux/krasnobaev
fi
export LESS=eFRX
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment