Adding new stuff
This commit is contained in:
parent
39ee792ad4
commit
a410da0e04
722 changed files with 331 additions and 189 deletions
|
|
@ -31,6 +31,7 @@ alias omg="sudo service NetworkManager restart"
|
||||||
alias zsh_fix="mv ~/.zsh_history ~/.zsh_history_bad; strings ~/.zsh_history_bad > ~/.zsh_history;fc -R ~/.zsh_history; rm ~/.zsh_history_bad"
|
alias zsh_fix="mv ~/.zsh_history ~/.zsh_history_bad; strings ~/.zsh_history_bad > ~/.zsh_history;fc -R ~/.zsh_history; rm ~/.zsh_history_bad"
|
||||||
alias whatismyip="curl ifconfig.co"
|
alias whatismyip="curl ifconfig.co"
|
||||||
alias rmswp="find ~/.vim/tmp/ -iname \"*swp\" -delete"
|
alias rmswp="find ~/.vim/tmp/ -iname \"*swp\" -delete"
|
||||||
|
alias root="sudo su"
|
||||||
|
|
||||||
function download_github_folder() {
|
function download_github_folder() {
|
||||||
svn checkout $(echo $1 | sed "s/\/tree\/[a-zA-Z]\+/\/trunk/")
|
svn checkout $(echo $1 | sed "s/\/tree\/[a-zA-Z]\+/\/trunk/")
|
||||||
|
|
@ -70,3 +71,40 @@ function secureme(){
|
||||||
cd /home/viktor/;
|
cd /home/viktor/;
|
||||||
sudo openvpn --config viktor.ovpn &
|
sudo openvpn --config viktor.ovpn &
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function in(){
|
||||||
|
if [ $# -ne 1 ] && [ $# -ne 2 ];
|
||||||
|
then
|
||||||
|
echo "Usage:"
|
||||||
|
echo "To start existing container:"
|
||||||
|
echo "in <os you want>"
|
||||||
|
echo
|
||||||
|
echo "To start new container:"
|
||||||
|
echo "in new <os you want>"
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ $# -eq 1 ]
|
||||||
|
then
|
||||||
|
container_name="${1/:/_}"
|
||||||
|
else
|
||||||
|
container_name="${2/:/_}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$1" = "new" ] && [ $# -eq 2 ]
|
||||||
|
then
|
||||||
|
image_name=$2
|
||||||
|
if [[ $(docker container ls -a | grep "$container_name") ]]
|
||||||
|
then
|
||||||
|
if [[ $(docker ps | grep $container_name) ]]
|
||||||
|
then
|
||||||
|
docker stop $container_name >> /dev/null
|
||||||
|
fi
|
||||||
|
docker rm $container_name >> /dev/null
|
||||||
|
fi
|
||||||
|
docker run -it --name $container_name $image_name /bin/bash
|
||||||
|
else
|
||||||
|
docker start $container_name >> /dev/null
|
||||||
|
docker exec -it $container_name /bin/bash
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
|
||||||
334
.tmux.conf
334
.tmux.conf
|
|
@ -1,26 +1,22 @@
|
||||||
# cat << EOF > /dev/null
|
# cat << EOF > /dev/null
|
||||||
# https://github.com/gpakosz/.tmux
|
# https://github.com/gpakosz/.tmux
|
||||||
# (‑●‑●)> released under the WTFPL v2 license, by Gregory Pakosz (@gpakosz)
|
# (‑●‑●)> dual licensed under the WTFPL v2 license and the MIT license,
|
||||||
|
# without any warranty.
|
||||||
|
# Copyright 2012— Gregory Pakosz (@gpakosz).
|
||||||
# /!\ do not edit this file
|
# /!\ do not edit this file
|
||||||
# instead, override settings in ~/.tmux.conf.local
|
# instead, override settings in ~/.tmux.conf.local, see README.md
|
||||||
|
|
||||||
|
|
||||||
# -- general -------------------------------------------------------------------
|
# -- general -------------------------------------------------------------------
|
||||||
|
|
||||||
set -g default-terminal "screen-256color" # colors!
|
set -g default-terminal "screen-256color" # colors!
|
||||||
set -g xterm-keys on
|
setw -g xterm-keys on
|
||||||
set -s escape-time 10 # faster command sequences
|
set -s escape-time 10 # faster command sequences
|
||||||
set -sg repeat-time 600 # increase repeat timeout
|
set -sg repeat-time 600 # increase repeat timeout
|
||||||
set -s focus-events on
|
set -s focus-events on
|
||||||
|
|
||||||
|
set -g prefix2 C-a # GNU-Screen compatible prefix
|
||||||
# set -g prefix2 C-a # GNU-Screen compatible prefix
|
bind C-a send-prefix -2
|
||||||
# bind C-a send-prefix -2
|
|
||||||
|
|
||||||
unbind C-x
|
|
||||||
unbind M-x
|
|
||||||
set prefix M-x
|
|
||||||
bind-key M-x send-prefix
|
|
||||||
|
|
||||||
set -q -g status-utf8 on # expect UTF-8 (tmux < 2.2)
|
set -q -g status-utf8 on # expect UTF-8 (tmux < 2.2)
|
||||||
setw -q -g utf8 on
|
setw -q -g utf8 on
|
||||||
|
|
@ -51,7 +47,7 @@ set -g display-time 1000 # slightly longer status messages display time
|
||||||
set -g status-interval 10 # redraw status line every 10 seconds
|
set -g status-interval 10 # redraw status line every 10 seconds
|
||||||
|
|
||||||
# clear both screen and history
|
# clear both screen and history
|
||||||
bind -n C-l send-keys C-l \; run 'sleep 0.05 && tmux clear-history'
|
bind -n C-l send-keys C-l \; run 'sleep 0.1' \; clear-history
|
||||||
|
|
||||||
# activity
|
# activity
|
||||||
set -g monitor-activity on
|
set -g monitor-activity on
|
||||||
|
|
@ -60,9 +56,17 @@ set -g visual-activity off
|
||||||
|
|
||||||
# -- navigation ----------------------------------------------------------------
|
# -- navigation ----------------------------------------------------------------
|
||||||
|
|
||||||
|
# create session
|
||||||
|
bind C-c new-session
|
||||||
|
|
||||||
# find session
|
# find session
|
||||||
bind C-f command-prompt -p find-session 'switch-client -t %%'
|
bind C-f command-prompt -p find-session 'switch-client -t %%'
|
||||||
|
|
||||||
|
# split current window horizontally
|
||||||
|
bind - split-window -v
|
||||||
|
# split current window vertically
|
||||||
|
bind _ split-window -h
|
||||||
|
|
||||||
# pane navigation
|
# pane navigation
|
||||||
bind -r h select-pane -L # move left
|
bind -r h select-pane -L # move left
|
||||||
bind -r j select-pane -D # move down
|
bind -r j select-pane -D # move down
|
||||||
|
|
@ -71,6 +75,9 @@ bind -r l select-pane -R # move right
|
||||||
bind > swap-pane -D # swap current pane with the next one
|
bind > swap-pane -D # swap current pane with the next one
|
||||||
bind < swap-pane -U # swap current pane with the previous one
|
bind < swap-pane -U # swap current pane with the previous one
|
||||||
|
|
||||||
|
# maximize current pane
|
||||||
|
bind + run 'cut -c3- ~/.tmux.conf | sh -s _maximize_pane #{session_name} #D'
|
||||||
|
|
||||||
# pane resizing
|
# pane resizing
|
||||||
bind -r H resize-pane -L 2
|
bind -r H resize-pane -L 2
|
||||||
bind -r J resize-pane -D 2
|
bind -r J resize-pane -D 2
|
||||||
|
|
@ -122,16 +129,13 @@ run -b 'tmux bind -ct vi-edit Escape cancel 2> /dev/null || true'
|
||||||
# -- copy mode -----------------------------------------------------------------
|
# -- copy mode -----------------------------------------------------------------
|
||||||
|
|
||||||
bind Enter copy-mode # enter copy mode
|
bind Enter copy-mode # enter copy mode
|
||||||
bind b list-buffers # list paster buffers
|
|
||||||
bind p paste-buffer # paste from the top pate buffer
|
|
||||||
bind P choose-buffer # choose which buffer to paste from
|
|
||||||
|
|
||||||
run -b 'tmux bind -t vi-copy v begin-selection 2> /dev/null || true'
|
run -b 'tmux bind -t vi-copy v begin-selection 2> /dev/null || true'
|
||||||
run -b 'tmux bind -T copy-mode-vi v send -X begin-selection 2> /dev/null || true'
|
run -b 'tmux bind -T copy-mode-vi v send -X begin-selection 2> /dev/null || true'
|
||||||
run -b 'tmux bind -t vi-copy C-v rectangle-toggle 2> /dev/null || true'
|
run -b 'tmux bind -t vi-copy C-v rectangle-toggle 2> /dev/null || true'
|
||||||
run -b 'tmux bind -T copy-mode-vi C-v send -X rectangle-toggle 2> /dev/null || true'
|
run -b 'tmux bind -T copy-mode-vi C-v send -X rectangle-toggle 2> /dev/null || true'
|
||||||
run -b 'tmux bind -t vi-copy y copy-selection 2> /dev/null || true'
|
run -b 'tmux bind -t vi-copy y copy-selection 2> /dev/null || true'
|
||||||
run -b 'tmux bind -T copy-mode-vi y send -X copy-selection 2> /dev/null || true'
|
run -b 'tmux bind -T copy-mode-vi y send -X copy-selection-and-cancel 2> /dev/null || true'
|
||||||
run -b 'tmux bind -t vi-copy Escape cancel 2> /dev/null || true'
|
run -b 'tmux bind -t vi-copy Escape cancel 2> /dev/null || true'
|
||||||
run -b 'tmux bind -T copy-mode-vi Escape send -X cancel 2> /dev/null || true'
|
run -b 'tmux bind -T copy-mode-vi Escape send -X cancel 2> /dev/null || true'
|
||||||
run -b 'tmux bind -t vi-copy H start-of-line 2> /dev/null || true'
|
run -b 'tmux bind -t vi-copy H start-of-line 2> /dev/null || true'
|
||||||
|
|
@ -147,6 +151,13 @@ if -b 'command -v clip.exe > /dev/null 2>&1' 'bind y run -b "tmux save-buffer -
|
||||||
if -b '[ -c /dev/clipboard ]' 'bind y run -b "tmux save-buffer - > /dev/clipboard"'
|
if -b '[ -c /dev/clipboard ]' 'bind y run -b "tmux save-buffer - > /dev/clipboard"'
|
||||||
|
|
||||||
|
|
||||||
|
# -- buffers -------------------------------------------------------------------
|
||||||
|
|
||||||
|
bind b list-buffers # list paste buffers
|
||||||
|
bind p paste-buffer # paste from the top paste buffer
|
||||||
|
bind P choose-buffer # choose which buffer to paste from
|
||||||
|
|
||||||
|
|
||||||
# -- user defined overrides ----------------------------------------------------
|
# -- user defined overrides ----------------------------------------------------
|
||||||
|
|
||||||
if '[ -f ~/.tmux.conf.local ]' 'source ~/.tmux.conf.local'
|
if '[ -f ~/.tmux.conf.local ]' 'source ~/.tmux.conf.local'
|
||||||
|
|
@ -154,7 +165,7 @@ if '[ -f ~/.tmux.conf.local ]' 'source ~/.tmux.conf.local'
|
||||||
|
|
||||||
# -- 8< ------------------------------------------------------------------------
|
# -- 8< ------------------------------------------------------------------------
|
||||||
|
|
||||||
# run 'cut -c3- ~/.tmux.conf | sh -s _apply_configuration'
|
run 'cut -c3- ~/.tmux.conf | sh -s _apply_configuration'
|
||||||
|
|
||||||
|
|
||||||
# EOF
|
# EOF
|
||||||
|
|
@ -209,80 +220,91 @@ if '[ -f ~/.tmux.conf.local ]' 'source ~/.tmux.conf.local'
|
||||||
# }
|
# }
|
||||||
#
|
#
|
||||||
# _toggle_mouse() {
|
# _toggle_mouse() {
|
||||||
# if tmux show -g -w | grep -q mode-mouse; then
|
# old=$(tmux show -gv mouse)
|
||||||
# old=$(tmux show -g -w | grep mode-mouse | cut -d' ' -f2)
|
# new=""
|
||||||
# new=""
|
|
||||||
#
|
#
|
||||||
# if [ "$old" = "on" ]; then
|
# if [ "$old" = "on" ]; then
|
||||||
# new="off"
|
# new="off"
|
||||||
# else
|
|
||||||
# new="on"
|
|
||||||
# fi
|
|
||||||
#
|
|
||||||
# tmux set -g mode-mouse $new \;\
|
|
||||||
# set -g mouse-resize-pane $new \;\
|
|
||||||
# set -g mouse-select-pane $new \;\
|
|
||||||
# set -g mouse-select-window $new \;\
|
|
||||||
# display "mouse: $new"
|
|
||||||
# else
|
# else
|
||||||
# old=$(tmux show -g | grep mouse | head -n 1 | cut -d' ' -f2)
|
# new="on"
|
||||||
# new=""
|
|
||||||
#
|
|
||||||
# if [ "$old" = "on" ]; then
|
|
||||||
# new="off"
|
|
||||||
# else
|
|
||||||
# new="on"
|
|
||||||
# fi
|
|
||||||
#
|
|
||||||
# tmux set -g mouse $new \;\
|
|
||||||
# display "mouse: $new"
|
|
||||||
# fi
|
# fi
|
||||||
|
#
|
||||||
|
# tmux set -g mouse $new \;\
|
||||||
|
# display "mouse: $new"
|
||||||
# }
|
# }
|
||||||
#
|
#
|
||||||
# _battery() {
|
# _battery() {
|
||||||
|
# charge=0
|
||||||
# uname_s=$(uname -s)
|
# uname_s=$(uname -s)
|
||||||
# case "$uname_s" in
|
# case "$uname_s" in
|
||||||
# *Darwin*)
|
# *Darwin*)
|
||||||
# batt=$(pmset -g batt)
|
# while IFS= read -r line; do
|
||||||
# percentage=$(echo "$batt" |egrep -o [0-9]+%) || return
|
# if [ x"$discharging" != x"true" ]; then
|
||||||
# discharging=$(echo "$batt" | grep -qi "discharging" && echo "true" || echo "false")
|
# discharging=$(printf '%s' "$line" | grep -qi "discharging" && echo "true" || echo "false")
|
||||||
# charge="${percentage%%%} / 100"
|
# fi
|
||||||
|
# percentage=$(printf '%s' "$line" | grep -E -o '[0-9]+%')
|
||||||
|
# charge=$(awk -v charge="$charge" -v percentage="${percentage%%%}" 'BEGIN { print charge + percentage / 100 }')
|
||||||
|
# count=$((count + 1))
|
||||||
|
# done << EOF
|
||||||
|
# $(pmset -g batt | grep 'InternalBattery')
|
||||||
|
# EOF
|
||||||
# ;;
|
# ;;
|
||||||
# *Linux*)
|
# *Linux*)
|
||||||
# batpath=/sys/class/power_supply/BAT0
|
# while IFS= read -r batpath; do
|
||||||
# if [ ! -d $batpath ]; then
|
# if [ x"$discharging" != x"true" ]; then
|
||||||
# batpath=/sys/class/power_supply/BAT1
|
# discharging=$(grep -qi "discharging" "$batpath/status" && echo "true" || echo "false")
|
||||||
# fi
|
|
||||||
# discharging=$(grep -qi "discharging" $batpath/status && echo "true" || echo "false")
|
|
||||||
# bat_capacity=$batpath/capacity
|
|
||||||
# bat_energy_full=$batpath/energy_full
|
|
||||||
# bat_energy_now=$batpath/energy_now
|
|
||||||
# if [ -r "$bat_capacity" ]; then
|
|
||||||
# charge="$(cat $bat_capacity) / 100"
|
|
||||||
# else
|
|
||||||
# if [ ! -r "$bat_energy_full" ] || [ ! -r "$bat_energy_now" ]; then
|
|
||||||
# return
|
|
||||||
# fi
|
# fi
|
||||||
# charge="$(cat $bat_energy_now) / $(cat $bat_energy_full)" || return
|
# bat_capacity="$batpath/capacity"
|
||||||
# fi
|
# if [ -r "$bat_capacity" ]; then
|
||||||
|
# charge=$(awk -v charge="$charge" -v capacity="$(cat "$bat_capacity")" 'BEGIN { print charge + capacity / 100 }')
|
||||||
|
# else
|
||||||
|
# bat_energy_full="$batpath/energy_full"
|
||||||
|
# bat_energy_now="$batpath/energy_now"
|
||||||
|
# if [ -r "$bat_energy_full" ] && [ -r "$bat_energy_now" ]; then
|
||||||
|
# charge=$(awk -v charge="$charge" -v energy_now="$(cat "$bat_energy_now")" -v energy_full="$(cat "$bat_energy_full")" 'BEGIN { print charge + energy_now / energy_full }')
|
||||||
|
# fi
|
||||||
|
# fi
|
||||||
|
# count=$((count + 1))
|
||||||
|
# done << EOF
|
||||||
|
# $(find /sys/class/power_supply -maxdepth 1 -iname '*bat*')
|
||||||
|
# EOF
|
||||||
# ;;
|
# ;;
|
||||||
# *CYGWIN*)
|
# *CYGWIN*|*MSYS*|*MINGW*)
|
||||||
# wmic path Win32_Battery 2>&1 | grep -q 'No Instance' && return
|
# while IFS= read -r line; do
|
||||||
# discharging=$(wmic path Win32_Battery Get BatteryStatus 2>/dev/null | grep -q 1 && echo "true" || echo "false")
|
# [ -z "$line" ] && continue
|
||||||
# percentage=$(wmic path Win32_Battery Get EstimatedChargeRemaining /format:list 2>/dev/null | grep '[^[:blank:]]' | cut -d= -f2)
|
# if [ x"$discharging" != x"true" ]; then
|
||||||
# charge="${percentage} / 100"
|
# discharging=$(printf '%s' "$line" | awk '{ s = ($1 == 1) ? "true" : "false"; print s }')
|
||||||
|
# fi
|
||||||
|
# charge=$(printf '%s' "$line" | awk -v charge="$charge" '{ print charge + $2 / 100 }')
|
||||||
|
# count=$((count + 1))
|
||||||
|
# done << EOF
|
||||||
|
# $(wmic path Win32_Battery get BatteryStatus, EstimatedChargeRemaining | tr -d '\r' | tail -n +2)
|
||||||
|
# EOF
|
||||||
# ;;
|
# ;;
|
||||||
# *OpenBSD*)
|
# *OpenBSD*)
|
||||||
# discharging=$(sysctl -n hw.sensors.acpibat0.raw0 | grep -q 1 && echo "true" || echo "false")
|
# for batid in 0 1 2; do
|
||||||
# if sysctl -n hw.sensors.acpibat0 | grep -q amphour; then
|
# sysctl -n "hw.sensors.acpibat$batid.raw0" 2>&1 | grep -q 'not found' && continue
|
||||||
# charge="$(sysctl -n hw.sensors.acpibat0.amphour3 | cut -d' ' -f1) / $(sysctl -n hw.sensors.acpibat0.amphour0 | cut -d' ' -f1)"
|
# if [ x"$discharging" != x"true" ]; then
|
||||||
# else
|
# discharging=$(sysctl -n "hw.sensors.acpibat$batid.raw0" | grep -q 1 && echo "true" || echo "false")
|
||||||
# charge="$(sysctl -n hw.sensors.acpibat0.watthour3 | cut -d' ' -f1) / $(sysctl -n hw.sensors.acpibat0.watthour0 | cut -d' ' -f1)"
|
# fi
|
||||||
# fi
|
# if sysctl -n "hw.sensors.acpibat$batid" | grep -q amphour; then
|
||||||
|
# charge=$(awk -v charge="$charge" -v remaining="$(sysctl -n hw.sensors.acpibat$batid.amphour3 | cut -d' ' -f1)" -v full="$(sysctl -n hw.sensors.acpibat$batid.amphour0 | cut -d' ' -f1)" 'BEGIN { print charge + remaining / full }')
|
||||||
|
# else
|
||||||
|
# charge=$(awk -v charge="$charge" -v remaining="$(sysctl -n hw.sensors.acpibat$batid.watthour3 | cut -d' ' -f1)" -v full="$(sysctl -n hw.sensors.acpibat$batid.watthour0 | cut -d' ' -f1)" 'BEGIN { print charge + remaining / full }')
|
||||||
|
# fi
|
||||||
|
# count=$((count + 1))
|
||||||
|
# done
|
||||||
# ;;
|
# ;;
|
||||||
# *)
|
|
||||||
# return
|
|
||||||
# esac
|
# esac
|
||||||
|
# charge=$(awk -v charge="$charge" -v count="$count" 'BEGIN { print charge / count }')
|
||||||
|
# if [ "$charge" -eq 0 ]; then
|
||||||
|
# tmux set -ug '@battery_status' \;\
|
||||||
|
# set -ug '@battery_bar' \;\
|
||||||
|
# set -ug '@battery_hbar' \;\
|
||||||
|
# set -ug '@battery_vbar' \;\
|
||||||
|
# set -ug '@battery_percentage'
|
||||||
|
# return
|
||||||
|
# fi
|
||||||
#
|
#
|
||||||
# variables=$(tmux show -gqv '@battery_bar_symbol_full' \;\
|
# variables=$(tmux show -gqv '@battery_bar_symbol_full' \;\
|
||||||
# show -gqv '@battery_bar_symbol_empty' \;\
|
# show -gqv '@battery_bar_symbol_empty' \;\
|
||||||
|
|
@ -431,7 +453,7 @@ if '[ -f ~/.tmux.conf.local ]' 'source ~/.tmux.conf.local'
|
||||||
# ssh_only=$2
|
# ssh_only=$2
|
||||||
# # shellcheck disable=SC2039
|
# # shellcheck disable=SC2039
|
||||||
# if [ x"$OSTYPE" = x"cygwin" ]; then
|
# if [ x"$OSTYPE" = x"cygwin" ]; then
|
||||||
# pid=$(ps -a | awk -v tty="${tty##/dev/}" '$5 == tty && /ssh/ && && !/vagrant ssh/ && !/autossh/ && !/-W/ { print $1 }')
|
# pid=$(ps -a | awk -v tty="${tty##/dev/}" '$5 == tty && /ssh/ && !/vagrant ssh/ && !/autossh/ && !/-W/ { print $1 }')
|
||||||
# [ -n "$pid" ] && ssh_parameters=$(tr '\0' ' ' < "/proc/$pid/cmdline" | sed 's/^ssh //')
|
# [ -n "$pid" ] && ssh_parameters=$(tr '\0' ' ' < "/proc/$pid/cmdline" | sed 's/^ssh //')
|
||||||
# else
|
# else
|
||||||
# ssh_parameters=$(ps -t "$tty" -o command= | awk '/ssh/ && !/vagrant ssh/ && !/autossh/ && !/-W/ { $1=""; print $0; exit }')
|
# ssh_parameters=$(ps -t "$tty" -o command= | awk '/ssh/ && !/vagrant ssh/ && !/autossh/ && !/-W/ { $1=""; print $0; exit }')
|
||||||
|
|
@ -514,7 +536,7 @@ if '[ -f ~/.tmux.conf.local ]' 'source ~/.tmux.conf.local'
|
||||||
# boot=$(sysctl -q -n kern.boottime | awk -F'[ ,:]+' '{ print $4 }')
|
# boot=$(sysctl -q -n kern.boottime | awk -F'[ ,:]+' '{ print $4 }')
|
||||||
# now=$(date +%s)
|
# now=$(date +%s)
|
||||||
# ;;
|
# ;;
|
||||||
# *Linux*|*CYGWIN*)
|
# *Linux*|*CYGWIN*|*MSYS*|*MINGW*)
|
||||||
# now=$(cut -d' ' -f1 < /proc/uptime)
|
# now=$(cut -d' ' -f1 < /proc/uptime)
|
||||||
# ;;
|
# ;;
|
||||||
# *OpenBSD*)
|
# *OpenBSD*)
|
||||||
|
|
@ -583,81 +605,96 @@ if '[ -f ~/.tmux.conf.local ]' 'source ~/.tmux.conf.local'
|
||||||
# }
|
# }
|
||||||
#
|
#
|
||||||
# _apply_bindings() {
|
# _apply_bindings() {
|
||||||
|
# line=$(tmux list-keys | grep new-window | head -1)
|
||||||
|
# prefix=${line%new-window*}
|
||||||
|
# column=${#prefix}
|
||||||
|
#
|
||||||
# tmux_conf_new_window_retain_current_path=${tmux_conf_new_window_retain_current_path:-false}
|
# tmux_conf_new_window_retain_current_path=${tmux_conf_new_window_retain_current_path:-false}
|
||||||
# if _is_enabled "$tmux_conf_new_window_retain_current_path"; then
|
# while IFS= read -r line; do
|
||||||
# tmux bind c new-window -c '#{pane_current_path}'
|
# [ -z "$line" ] && continue
|
||||||
# else
|
# left=$(printf '%s' "$line" | cut -c-"$column" | sed -E -e 's/[^ \ta-zA-Z0-9,._+@%/-]/\\&/g')
|
||||||
# tmux bind c new-window
|
# if _is_enabled "$tmux_conf_new_window_retain_current_path"; then
|
||||||
# fi
|
# right=$(printf '%s' "$line" | cut -c"$column-" | awk -F'\"' 'BEGIN { OFS = FS } { for (i = 1; i <= NF; i+=2) { gsub(/#{.+}/, "\"&\"", $i) } print }' | sed -E -e 's/new-window$/new-window -c "#{pane_current_path}"/g')
|
||||||
|
# else
|
||||||
|
# right=$(printf '%s' "$line" | cut -c"$column"- | awk -F'\"' 'BEGIN { OFS = FS } { for (i = 1; i <= NF; i+=2) { gsub(/#{.+}/, "\"&\"", $i) } print }' | sed -E -e 's/-c[ \t]+"#\{pane_current_path\}"$//g')
|
||||||
|
# fi
|
||||||
|
# eval "tmux $left $right" 2>/dev/null || true
|
||||||
|
# done << EOF
|
||||||
|
# $(tmux list-keys 2>/dev/null | grep -e 'new-window\(\s\+-c\s\+"#{pane_current_path}\|$\)')
|
||||||
|
# EOF
|
||||||
#
|
#
|
||||||
# tmux_conf_new_pane_retain_current_path=${tmux_conf_new_pane_retain_current_path:-true}
|
# tmux_conf_new_pane_retain_current_path=${tmux_conf_new_pane_retain_current_path:-true}
|
||||||
|
# while IFS= read -r line; do
|
||||||
|
# [ -z "$line" ] && continue
|
||||||
|
# left=$(printf '%s' "$line" | cut -c-"$column" | sed -E -e 's/[^ \ta-zA-Z0-9,._+@%/-]/\\&/g')
|
||||||
|
# if _is_enabled "$tmux_conf_new_pane_retain_current_path"; then
|
||||||
|
# right=$(printf '%s' "$line" | cut -c"$column-" | awk -F'\"' 'BEGIN { OFS = FS } { for (i = 1; i <= NF; i+=2) { gsub(/#{.+}/, "\"&\"", $i) } print }' | sed -E -e 's/split-window([ \t]+-(h|v))?$/& -c "#{pane_current_path}"/g')
|
||||||
|
# else
|
||||||
|
# right=$(printf '%s' "$line" | cut -c"$column"- | awk -F'\"' 'BEGIN { OFS = FS } { for (i = 1; i <= NF; i+=2) { gsub(/#{.+}/, "\"&\"", $i) } print }' | sed -E -e 's/-c[ \t]+"#\{pane_current_path\}"$//g')
|
||||||
|
# fi
|
||||||
|
# eval "tmux $left $right" 2>/dev/null || true
|
||||||
|
# done << EOF
|
||||||
|
# $(tmux list-keys 2>/dev/null | grep -e 'split\(-\|_\)window')
|
||||||
|
# EOF
|
||||||
|
#
|
||||||
# tmux_conf_new_pane_reconnect_ssh=${tmux_conf_new_pane_reconnect_ssh:-false}
|
# tmux_conf_new_pane_reconnect_ssh=${tmux_conf_new_pane_reconnect_ssh:-false}
|
||||||
# if _is_enabled "$tmux_conf_new_pane_reconnect_ssh"; then
|
# while IFS= read -r line; do
|
||||||
# if _is_enabled "$tmux_conf_new_pane_retain_current_path"; then
|
# [ -z "$line" ] && continue
|
||||||
# tmux bind '"' run "cut -c3- ~/.tmux.conf | sh -s _split_window #{pane_tty} -v -c '#{pane_current_path}'" \;\
|
# left=$(printf '%s' "$line" | cut -c-"$column" | sed -E -e 's/[^ \ta-zA-Z0-9,._+@%/-]/\\&/g')
|
||||||
# bind % run "cut -c3- ~/.tmux.conf | sh -s _split_window #{pane_tty} -h -c '#{pane_current_path}'" \;\
|
# if _is_enabled "$tmux_conf_new_pane_reconnect_ssh"; then
|
||||||
# bind - run "cut -c3- ~/.tmux.conf | sh -s _split_window #{pane_tty} -v -c '#{pane_current_path}'" \;\
|
# right=$(printf '%s' "$line" | cut -c"$column"- | awk -F'\"' 'BEGIN { OFS = FS } { for (i = 1; i <= NF; i+=2) { gsub(/#{.+}/, "\"&\"", $i) } print }' | sed -E -e 's/split-window([^;]+)/run-shell "cut -c3- ~\/\.tmux\.conf | sh -s _split_window #{pane_tty}\1"/g')
|
||||||
# bind _ run "cut -c3- ~/.tmux.conf | sh -s _split_window #{pane_tty} -h -c '#{pane_current_path}'"
|
|
||||||
# else
|
# else
|
||||||
# tmux bind '"' run "cut -c3- ~/.tmux.conf | sh -s _split_window #{pane_tty} -v" \;\
|
# right=$(printf '%s' "$line" | cut -c"$column"- | awk -F'\"' 'BEGIN { OFS = FS } { for (i = 1; i <= NF; i+=2) { gsub(/#{.+}/, "\"&\"", $i) } print }' | sed -E -e 's/run-shell "cut -c3- ~\/\.tmux\.conf \| sh -s _split_window #\{pane_tty\}([^;]+)"/split-window\1/g' -e 's/#\{.+\}/\"&\"/g')
|
||||||
# bind % run "cut -c3- ~/.tmux.conf | sh -s _split_window #{pane_tty} -h" \;\
|
|
||||||
# bind - run "cut -c3- ~/.tmux.conf | sh -s _split_window #{pane_tty} -v" \;\
|
|
||||||
# bind _ run "cut -c3- ~/.tmux.conf | sh -s _split_window #{pane_tty} -h"
|
|
||||||
# fi
|
# fi
|
||||||
# else
|
# eval "tmux $left $right" 2>/dev/null || true
|
||||||
# if _is_enabled "$tmux_conf_new_pane_retain_current_path"; then
|
# done << EOF
|
||||||
# tmux bind '"' split-window -v -c '#{pane_current_path}' \;\
|
# $(tmux list-keys 2>/dev/null | grep -e 'split\(-\|_\)window')
|
||||||
# bind % split-window -h -c '#{pane_current_path}' \;\
|
# EOF
|
||||||
# bind - split-window -v -c '#{pane_current_path}' \;\
|
|
||||||
# bind _ split-window -h -c '#{pane_current_path}'
|
|
||||||
# else
|
|
||||||
# tmux bind '"' split-window -v \;\
|
|
||||||
# bind % split-window -h \;\
|
|
||||||
# bind - split-window -v \;\
|
|
||||||
# bind _ split-window -h
|
|
||||||
# fi
|
|
||||||
# fi
|
|
||||||
#
|
#
|
||||||
# tmux_conf_new_session_prompt=${tmux_conf_new_session_prompt:-false}
|
# tmux_conf_new_session_prompt=${tmux_conf_new_session_prompt:-false}
|
||||||
# if _is_enabled "$tmux_conf_new_session_prompt"; then
|
# while IFS= read -r line; do
|
||||||
# tmux bind C-c command-prompt -p new-session 'new-session -s "%%"'
|
# [ -z "$line" ] && continue
|
||||||
# else
|
# left=$(printf '%s' "$line" | cut -c-"$column" | sed -E -e 's/[^ \ta-zA-Z0-9,._+@%/-]/\\&/g')
|
||||||
# tmux bind C-c new-session
|
# if _is_enabled "$tmux_conf_new_session_prompt"; then
|
||||||
# fi
|
# right=$(printf '%s' "$line" | cut -c"$column"- | awk -F'\"' 'BEGIN { OFS = FS } { for (i = 1; i <= NF; i+=2) { gsub(/#{.+}/, "\"&\"", $i) } print }' | sed -E -e 's/new-session$/command-prompt -p new-session \"new-session -s %%\"/g')
|
||||||
#
|
# else
|
||||||
# if tmux -q -L swap-pane-test -f /dev/null new-session -d \; new-window \; new-window \; swap-pane -t :1 \; kill-session; then
|
# right=$(printf '%s' "$line" | cut -c"$column"- | awk -F'\"' 'BEGIN { OFS = FS } { for (i = 1; i <= NF; i+=2) { gsub(/#{.+}/, "\"&\"", $i) } print }'| sed -E -e 's/command-prompt -p new-session[^;]+/new-session/g')
|
||||||
# tmux bind + run 'cut -c3- ~/.tmux.conf | sh -s _maximize_pane #{session_name} #D'
|
# fi
|
||||||
# else
|
# eval "tmux $left $right" 2>/dev/null || true
|
||||||
# tmux bind + display 'your tmux version has a buggy swap-pane command - see ticket #108, fixed in upstream commit 78e783e'
|
# done << EOF
|
||||||
# fi
|
# $(tmux list-keys 2>/dev/null | grep -e 'new-session')
|
||||||
|
# EOF
|
||||||
#
|
#
|
||||||
# tmux_conf_copy_to_os_clipboard=${tmux_conf_copy_to_os_clipboard:-false}
|
# tmux_conf_copy_to_os_clipboard=${tmux_conf_copy_to_os_clipboard:-false}
|
||||||
# if _is_enabled "$tmux_conf_copy_to_os_clipboard"; then
|
# command -v pbcopy > /dev/null 2>&1 && command='pbcopy'
|
||||||
# if command -v pbcopy > /dev/null 2>&1; then
|
# command -v reattach-to-user-namespace > /dev/null 2>&1 && command='reattach-to-user-namespace pbcopy'
|
||||||
# tmux bind -t vi-copy y copy-pipe 'pbcopy' 2> /dev/null || true
|
# command -v xsel > /dev/null 2>&1 && command='xsel -i -b'
|
||||||
# tmux bind -T copy-mode-vi y send -X copy-pipe-and-cancel 'pbcopy' 2> /dev/null || true
|
# ! command -v xsel > /dev/null 2>&1 && command -v xclip > /dev/null 2>&1 && command='xclip -i -selection clipboard > \/dev\/null 2>\&1'
|
||||||
# fi
|
# command -v clip.exe > /dev/null 2>&1 && command='clip\.exe'
|
||||||
# if command -v reattach-to-user-namespace > /dev/null 2>&1; then
|
# [ -c /dev/clipboard ] && command='cat > \/dev\/clipboard'
|
||||||
# tmux bind -t vi-copy y copy-pipe 'reattach-to-user-namespace pbcopy' 2> /dev/null || true
|
#
|
||||||
# tmux bind -T copy-mode-vi y send -X copy-pipe-and-cancel 'reattach-to-user-namespace pbcopy' 2> /dev/null || true
|
# if [ -n "$command" ]; then
|
||||||
# fi
|
# # shellcheck disable=SC2086
|
||||||
# if command -v xsel > /dev/null 2>&1; then
|
# for table in "" "-t emacs-copy" "-t vi-copy"; do
|
||||||
# tmux bind -t vi-copy y copy-pipe 'xsel -i -b' 2> /dev/null || true
|
# line=$(tmux list-keys $table 2>/dev/null | grep -e 'copy-selection\|copy-pipe' | head -1)
|
||||||
# tmux bind -T copy-mode-vi y send -X copy-pipe-and-cancel 'xsel -i -b' 2> /dev/null || true
|
# prefix=${line%copy-*}
|
||||||
# fi
|
# column=${#prefix}
|
||||||
# if ! command -v xsel > /dev/null 2>&1 && command -v xclip > /dev/null 2>&1; then
|
# [ -z "$line" ] && continue
|
||||||
# tmux bind -t vi-copy y copy-pipe 'xclip -i -selection clipboard > /dev/null 2>&1' 2> /dev/null || true
|
#
|
||||||
# tmux bind -T copy-mode-vi y send -X copy-pipe-and-cancel 'xclip -i -selection clipboard > /dev/null 2>&1' 2> /dev/null || true
|
# while IFS= read -r line; do
|
||||||
# fi
|
# [ -z "$line" ] && continue
|
||||||
# if command -v clip.exe > /dev/null 2>&1; then
|
# left=$(printf '%s' "$line" | cut -c-"$column" | sed -E -e 's/[^ \ta-zA-Z0-9,._+@%/-]/\\&/g')
|
||||||
# tmux bind -t vi-copy y copy-pipe 'clip.exe' 2> /dev/null || true
|
# if _is_enabled "$tmux_conf_copy_to_os_clipboard"; then
|
||||||
# tmux bind -T copy-mode-vi y send -X copy-pipe-and-cancel 'clip.exe' 2> /dev/null || true
|
# right=$(printf '%s' "$line" | cut -c"$column"- | awk -F'\"' 'BEGIN { OFS = FS } { for (i = 1; i <= NF; i+=2) { gsub(/#{.+}/, "\"&\"", $i) } print }' | sed -E -e "s/copy-selection(-and-cancel)?$/copy-pipe\1 \"$command\"/g")
|
||||||
# fi
|
# else
|
||||||
# if [ -c /dev/clipboard ] > /dev/null 2>&1; then
|
# right=$(printf '%s' "$line" | cut -c"$column"- | awk -F'\"' 'BEGIN { OFS = FS } { for (i = 1; i <= NF; i+=2) { gsub(/#{.+}/, "\"&\"", $i) } print }' | sed -E -e "s/copy-pipe(-and-cancel)? \"$command\"$/copy-selection\1/g")
|
||||||
# tmux bind -t vi-copy y copy-pipe 'cat > /dev/clipboard' 2> /dev/null || true
|
# fi
|
||||||
# tmux bind -T copy-mode-vi y send -X copy-pipe-and-cancel 'cat > /dev/clipboard' 2> /dev/null || true
|
# eval "tmux $left $right" 2>/dev/null || true
|
||||||
# fi
|
# done << EOF
|
||||||
# fi
|
# $(tmux list-keys $table 2>/dev/null | grep -e 'copy-selection\|copy-pipe')
|
||||||
|
# EOF
|
||||||
|
# done
|
||||||
|
# fi
|
||||||
# }
|
# }
|
||||||
#
|
#
|
||||||
# _apply_theme() {
|
# _apply_theme() {
|
||||||
|
|
@ -867,19 +904,10 @@ if '[ -f ~/.tmux.conf.local ]' 'source ~/.tmux.conf.local'
|
||||||
# $tmux_conf_theme_status_left
|
# $tmux_conf_theme_status_left
|
||||||
# EOF
|
# EOF
|
||||||
# )
|
# )
|
||||||
#
|
|
||||||
# # are we running a tmux in between v1.9 and v2.0?
|
|
||||||
# if [ x"$(tmux -q -L tmux_theme_status_left_test -f /dev/null new-session -d \; show -g -v status-left \; kill-session)" = x"[#S] " ]; then
|
|
||||||
# case "$status_left" in
|
|
||||||
# *\ )
|
|
||||||
# ;;
|
|
||||||
# *)
|
|
||||||
# status_left="$status_left "
|
|
||||||
# ;;
|
|
||||||
# esac
|
|
||||||
# fi
|
|
||||||
# fi
|
# fi
|
||||||
#
|
#
|
||||||
|
# status_left="$status_left "
|
||||||
|
#
|
||||||
# # -- status right style
|
# # -- status right style
|
||||||
#
|
#
|
||||||
# tmux_conf_theme_status_right=${tmux_conf_theme_status_right-'#{pairing}#{prefix} #{battery_status} #{battery_bar} #{battery_percentage} , %R , %d %b | #{username} | #{hostname} '}
|
# tmux_conf_theme_status_right=${tmux_conf_theme_status_right-'#{pairing}#{prefix} #{battery_status} #{battery_bar} #{battery_percentage} , %R , %d %b | #{username} | #{hostname} '}
|
||||||
|
|
@ -1083,5 +1111,3 @@ if '[ -f ~/.tmux.conf.local ]' 'source ~/.tmux.conf.local'
|
||||||
# }
|
# }
|
||||||
#
|
#
|
||||||
# "$@"
|
# "$@"
|
||||||
run-shell /opt/tmux-ressurect/resurrect.tmux
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,7 @@
|
||||||
# https://github.com/gpakosz/.tmux
|
# https://github.com/gpakosz/.tmux
|
||||||
# (‑●‑●)> released under the WTFPL v2 license, by Gregory Pakosz (@gpakosz)
|
# (‑●‑●)> dual licensed under the WTFPL v2 license and the MIT license,
|
||||||
|
# without any warranty.
|
||||||
|
# Copyright 2012— Gregory Pakosz (@gpakosz).
|
||||||
|
|
||||||
|
|
||||||
# -- navigation ----------------------------------------------------------------
|
# -- navigation ----------------------------------------------------------------
|
||||||
|
|
@ -128,10 +130,10 @@ tmux_conf_theme_left_separator_main=''
|
||||||
tmux_conf_theme_left_separator_sub='|'
|
tmux_conf_theme_left_separator_sub='|'
|
||||||
tmux_conf_theme_right_separator_main=''
|
tmux_conf_theme_right_separator_main=''
|
||||||
tmux_conf_theme_right_separator_sub='|'
|
tmux_conf_theme_right_separator_sub='|'
|
||||||
#tmux_conf_theme_left_separator_main='' # /!\ you don't need to install Powerline
|
tmux_conf_theme_left_separator_main='' # /!\ you don't need to install Powerline
|
||||||
#tmux_conf_theme_left_separator_sub='' # you only need fonts patched with
|
tmux_conf_theme_left_separator_sub='' # you only need fonts patched with
|
||||||
#tmux_conf_theme_right_separator_main='' # Powerline symbols or the standalone
|
tmux_conf_theme_right_separator_main='' # Powerline symbols or the standalone
|
||||||
#tmux_conf_theme_right_separator_sub='' # PowerlineSymbols.otf font
|
tmux_conf_theme_right_separator_sub='' # PowerlineSymbols.otf font
|
||||||
|
|
||||||
# status left/right content:
|
# status left/right content:
|
||||||
# - separate main sections with '|'
|
# - separate main sections with '|'
|
||||||
|
|
@ -221,8 +223,9 @@ tmux_conf_battery_vbar_palette='gradient'
|
||||||
# symbols used to indicate whether battery is charging or discharging
|
# symbols used to indicate whether battery is charging or discharging
|
||||||
tmux_conf_battery_status_charging='↑' # U+2191
|
tmux_conf_battery_status_charging='↑' # U+2191
|
||||||
tmux_conf_battery_status_discharging='↓' # U+2193
|
tmux_conf_battery_status_discharging='↓' # U+2193
|
||||||
#tmux_conf_battery_status_charging='⚡' # U+26A1
|
#tmux_conf_battery_status_charging='⚡ ' # U+26A1
|
||||||
#tmux_conf_battery_status_discharging='🔋' # U+1F50B
|
#tmux_conf_battery_status_charging='🔌 ' # U+1F50C
|
||||||
|
#tmux_conf_battery_status_discharging='🔋 ' # U+1F50B
|
||||||
|
|
||||||
# clock style
|
# clock style
|
||||||
tmux_conf_theme_clock_colour='#00afff' # light blue
|
tmux_conf_theme_clock_colour='#00afff' # light blue
|
||||||
|
|
@ -234,6 +237,8 @@ tmux_conf_theme_clock_style='24'
|
||||||
# in copy mode, copying selection also copies to the OS clipboard
|
# in copy mode, copying selection also copies to the OS clipboard
|
||||||
# - true
|
# - true
|
||||||
# - false (default)
|
# - false (default)
|
||||||
|
# on macOS, this requires installing reattach-to-user-namespace, see README.md
|
||||||
|
# on Linux, this requires xsel or xclip
|
||||||
tmux_conf_copy_to_os_clipboard=false
|
tmux_conf_copy_to_os_clipboard=false
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -243,44 +248,42 @@ tmux_conf_copy_to_os_clipboard=false
|
||||||
# increase history size
|
# increase history size
|
||||||
#set -g history-limit 10000
|
#set -g history-limit 10000
|
||||||
|
|
||||||
|
# start with mouse mode enabled
|
||||||
|
#set -g mouse on
|
||||||
|
|
||||||
# force Vi mode
|
# force Vi mode
|
||||||
# really you should export VISUAL or EDITOR environment variable, see manual
|
# really you should export VISUAL or EDITOR environment variable, see manual
|
||||||
#set -g status-keys vi
|
#set -g status-keys vi
|
||||||
#set -g mode-keys vi
|
#set -g mode-keys vi
|
||||||
|
|
||||||
# replace C-b by C-a instead of using both prefixes
|
# replace C-b by Alt-a (M-a) instead of using both prefixes
|
||||||
unbind C-x
|
set -gu prefix2
|
||||||
# unbind C-b
|
unbind C-a
|
||||||
# set -g prefix C-a
|
unbind C-b
|
||||||
# bind C-a send-prefix
|
set -g prefix M-x
|
||||||
|
bind M-x send-prefix
|
||||||
|
|
||||||
# move status line to top
|
# move status line to top
|
||||||
#set -g status-position top
|
#set -g status-position top
|
||||||
|
|
||||||
bind \ split-window -h -c "#{pane_current_path}" # Split panes horizontal
|
bind \ split-window -h -c "#{pane_current_path}" # Split panes horizontal
|
||||||
bind - split-window -v -c "#{pane_current_path}" # Split panes vertically
|
bind - split-window -v -c "#{pane_current_path}" # Split panes vertically
|
||||||
|
|
||||||
# Use Alt-vim keys without prefix key to switch panes
|
# Use Alt-vim keys without prefix key to switch panes
|
||||||
bind -n M-h select-pane -L
|
bind -n M-h select-pane -L
|
||||||
bind -n M-j select-pane -D
|
bind -n M-j select-pane -D
|
||||||
bind -n M-k select-pane -U
|
bind -n M-k select-pane -U
|
||||||
bind -n M-l select-pane -R
|
bind -n M-l select-pane -R
|
||||||
|
|
||||||
# Use Alt-arrow keys without prefix key to switch panes
|
# Use Alt-arrow keys without prefix key to switch panes
|
||||||
bind -n M-Left select-pane -L
|
bind -n M-Left select-pane -L
|
||||||
bind -n M-Right select-pane -R
|
bind -n M-Right select-pane -R
|
||||||
bind -n M-Up select-pane -U
|
bind -n M-Up select-pane -U
|
||||||
bind -n M-Down select-pane -D
|
bind -n M-Down select-pane -D
|
||||||
|
|
||||||
|
|
||||||
#set -g mouse on
|
#set -g mouse on
|
||||||
# to enable mouse scroll, see https://github.com/tmux/tmux/issues/145#issuecomment-150736967
|
# to enable mouse scroll, see https://github.com/tmux/tmux/issues/145#issuecomment-150736967
|
||||||
bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'copy-mode -e'"
|
bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'copy-mode -e'"
|
||||||
|
|
||||||
bind j resize-pane -D 10
|
bind j resize-pane -D 10
|
||||||
bind k resize-pane -U 10
|
bind k resize-pane -U 10
|
||||||
bind l resize-pane -R 10
|
bind l resize-pane -R 10
|
||||||
bind h resize-pane -L 10
|
bind h resize-pane -L 10
|
||||||
|
|
||||||
|
run-shell /home/viktor/.tmux/resurrect/resurrect.tmux
|
||||||
unbind C-x
|
|
||||||
|
|
|
||||||
10
.vimrc
10
.vimrc
|
|
@ -109,8 +109,16 @@ let g:airline#extensions#virtualenv#enabled = 1
|
||||||
let g:airline#extensions#tabline#enabled = 1
|
let g:airline#extensions#tabline#enabled = 1
|
||||||
let g:airline#extensions#tabline#left_sep = ' '
|
let g:airline#extensions#tabline#left_sep = ' '
|
||||||
let g:airline#extensions#tabline#left_alt_sep = '|'
|
let g:airline#extensions#tabline#left_alt_sep = '|'
|
||||||
|
" let g:airline_left_sep='>'
|
||||||
|
" let g:airline_right_sep='<'
|
||||||
|
" let g:airline_detect_modified=1
|
||||||
|
let g:airline_powerline_fonts=1
|
||||||
|
" let g:airline_section_b = '%{strftime("%c")}'
|
||||||
|
" let g:airline_section_y = 'BN: %{bufnr("%")} FT: %y'
|
||||||
|
|
||||||
|
|
||||||
" Enable wildmenu which is an enhanced command completion
|
" Enable wildmenu which is an enhanced command completion
|
||||||
|
"
|
||||||
set wildmenu
|
set wildmenu
|
||||||
" Better copy & paste
|
" Better copy & paste
|
||||||
" When you want to paste large blocks of code into vim, press F2 before you
|
" When you want to paste large blocks of code into vim, press F2 before you
|
||||||
|
|
@ -226,6 +234,8 @@ au InsertLeave * match ExtraWhitespace /\s\+$/
|
||||||
" http://www.vim.org/scripts/download_script.php?src_id=13400
|
" http://www.vim.org/scripts/download_script.php?src_id=13400
|
||||||
set t_Co=256
|
set t_Co=256
|
||||||
color wombat256mod
|
color wombat256mod
|
||||||
|
" color mayansmoke
|
||||||
|
" color github
|
||||||
|
|
||||||
" Spelling
|
" Spelling
|
||||||
" set spell
|
" set spell
|
||||||
|
|
|
||||||
20
.zshrc
20
.zshrc
|
|
@ -9,6 +9,7 @@ export ZSH=~/.oh-my-zsh
|
||||||
# it'll load a random theme each time that oh-my-zsh is loaded.
|
# it'll load a random theme each time that oh-my-zsh is loaded.
|
||||||
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
|
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
|
||||||
ZSH_THEME="bira"
|
ZSH_THEME="bira"
|
||||||
|
# ZSH_THEME="adben"
|
||||||
|
|
||||||
# Uncomment the following line to use case-sensitive completion.
|
# Uncomment the following line to use case-sensitive completion.
|
||||||
# CASE_SENSITIVE="true"
|
# CASE_SENSITIVE="true"
|
||||||
|
|
@ -24,7 +25,7 @@ HISTFILESIZE=9000
|
||||||
HYPHEN_INSENSITIVE="true"
|
HYPHEN_INSENSITIVE="true"
|
||||||
|
|
||||||
# Uncomment the following line to disable bi-weekly auto-update checks.
|
# Uncomment the following line to disable bi-weekly auto-update checks.
|
||||||
# DISABLE_AUTO_UPDATE="true"
|
DISABLE_AUTO_UPDATE="true"
|
||||||
|
|
||||||
# Uncomment the following line to change how often to auto-update (in days).
|
# Uncomment the following line to change how often to auto-update (in days).
|
||||||
# export UPDATE_ZSH_DAYS=13
|
# export UPDATE_ZSH_DAYS=13
|
||||||
|
|
@ -44,7 +45,7 @@ COMPLETION_WAITING_DOTS="true"
|
||||||
# Uncomment the following line if you want to disable marking untracked files
|
# Uncomment the following line if you want to disable marking untracked files
|
||||||
# under VCS as dirty. This makes repository status check for large repositories
|
# under VCS as dirty. This makes repository status check for large repositories
|
||||||
# much, much faster.
|
# much, much faster.
|
||||||
# DISABLE_UNTRACKED_FILES_DIRTY="true"
|
DISABLE_UNTRACKED_FILES_DIRTY="true"
|
||||||
|
|
||||||
# Uncomment the following line if you want to change the command execution time
|
# Uncomment the following line if you want to change the command execution time
|
||||||
# stamp shown in the history command output.
|
# stamp shown in the history command output.
|
||||||
|
|
@ -61,7 +62,7 @@ HIST_STAMPS="dd.mm.yyyy"
|
||||||
plugins=()
|
plugins=()
|
||||||
|
|
||||||
source $ZSH/oh-my-zsh.sh
|
source $ZSH/oh-my-zsh.sh
|
||||||
tmux source-file /home/viktor/.tmux.conf
|
# tmux source-file /home/viktor/.tmux.conf
|
||||||
|
|
||||||
# User configuration
|
# User configuration
|
||||||
|
|
||||||
|
|
@ -104,28 +105,15 @@ j () {
|
||||||
|
|
||||||
# . ~/.bash_completion
|
# . ~/.bash_completion
|
||||||
|
|
||||||
# Slows down shell.
|
|
||||||
# source $ZSH/custom/plugins/zsh-git-prompt/zshrc.sh
|
|
||||||
|
|
||||||
|
|
||||||
# Locale settings for perl
|
# Locale settings for perl
|
||||||
#export LC_CTYPE=en_US.UTF-8
|
#export LC_CTYPE=en_US.UTF-8
|
||||||
|
|
||||||
#export LC_ALL=C
|
#export LC_ALL=C
|
||||||
#export LC_ALL=en_US.UTF-8
|
#export LC_ALL=en_US.UTF-8
|
||||||
#sudo usermod -aG docker viktor
|
|
||||||
#newgrp docker
|
|
||||||
|
|
||||||
# Send ssh key to server
|
|
||||||
send_key() {
|
|
||||||
cat ~/.ssh/id_rsa.pub | ssh $1 "mkdir -p ~/.ssh && cat >> ~/.ssh/authorized_keys"
|
|
||||||
}
|
|
||||||
|
|
||||||
PYENV_ROOT="$HOME/.pyenv"
|
PYENV_ROOT="$HOME/.pyenv"
|
||||||
PATH="$PYENV_ROOT/bin:$PATH"
|
PATH="$PYENV_ROOT/bin:$PATH"
|
||||||
eval "$(pyenv init -)"
|
eval "$(pyenv init -)"
|
||||||
|
|
||||||
|
|
||||||
export VIRTUALENVWRAPPER_PYTHON=python
|
export VIRTUALENVWRAPPER_PYTHON=python
|
||||||
export WORKON_HOME=$HOME/.virtualenvs
|
export WORKON_HOME=$HOME/.virtualenvs
|
||||||
# source /usr/local/bin/virtualenvwrapper.sh
|
# source /usr/local/bin/virtualenvwrapper.sh
|
||||||
|
|
|
||||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue