Compare commits

..

9 Commits

Author SHA1 Message Date
Shaun Reed 7f0ca310aa Update command aliases 2022-11-20 13:49:18 -05:00
Shaun Reed c76f7a7b9f Fix repo name in tmux bar 2022-08-28 19:34:18 -04:00
Shaun Reed be0dd678dc Add docker image 2022-08-28 18:00:09 -04:00
Shaun Reed 8ec0ec3cef Set configs for different envrionments
+ Check if we're in docker or running xorg
+ Adjust tmux / vim settings
2022-08-28 17:25:44 -04:00
Shaun Reed e0ff2faeba Update vim configs
+ Conditionally use custom font
+ Fix ranger devicons
+ Add konsole profile
+ Conditionally eable default konsole profile
2022-08-26 22:02:57 -04:00
Shaun Reed 629ef32a26 Remove unused submodule 2022-08-06 23:55:40 -04:00
Shaun Reed 0fb52c2472 Update tmux configs
+ Add gitmux config
+ Use find to locate libclang in .bash_aliases
2022-08-06 23:39:41 -04:00
Shaun Reed c2e4e04a18 Update bash aliases and settings
+ Fix gitmux
2022-07-29 20:13:51 -04:00
Shaun Reed 903e81aad4 Update tmux configs
+ Plugins for tmux
+ Ranger plugins
2022-07-16 10:28:31 -04:00
22 changed files with 460 additions and 65 deletions

View File

@ -1,10 +1,23 @@
# Aliases to use the correct python version
# + Because python doesn't know how to update.. :')
alias python3='python3.9'
alias pip3='python3.9 -m pip'
# For Rust stuff, uncomment this line
#. "$HOME/.cargo/env"
alias kapp-git='git config --global user.name "Shaun Reed" && git config --global user.email "shaunrd0@gmail.com"'
alias kapp-update='sudo apt update -y && sudo apt upgrade -y && sudo apt upgrade --fix-broken --fix-missing --auto-remove'
alias ,git='git config --global user.name "Shaun Reed" && git config --global user.email "shaunrd0@gmail.com"'
if [ -f /.dockerenv ]; then
export DOT_PACKAGES='git stow vim tmux ranger clang wget curl'
alias ,update='apt update -y && apt upgrade -y && apt upgrade --fix-broken --fix-missing --auto-remove'
alias ,init='apt update -y && apt install $DOT_PACKAGES -y'
alias ,swap='swapoff -a && swapon -a'
else
export DOT_PACKAGES='git stow vim xsel xclip tmux ranger clang yakuake wget curl'
alias ,update='sudo apt update -y && sudo apt upgrade -y && sudo apt upgrade --fix-broken --fix-missing --auto-remove'
alias ,init='sudo apt update -y && sudo apt install $DOT_PACKAGES'
# Clear kscreen cached settings
alias ,kscreen='rm -rf ~/.local/share/kscreen/*'
# Restart plasmashell
alias ,plasmashell='sudo pkill plasmashell && plasmashell --replace &> /dev/null &'
alias ,swap='sudo swapoff -a && sudo swapon -a'
alias ,vbox="ps aux www |grep 'VBoxClient --draganddrop' | awk '{print $2}' | xargs kill"
fi
# Alias / export customizations
@ -22,15 +35,71 @@ alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo
export EDITOR="vim"
export VISUAL="vim"
export LS_COLORS="di=1;34:ln=31;47:so=32:pi=33:ex=1;32:bd=34;46:cd=34;43:su=30;41:sg=30;46:tw=30;42:ow=30;43"
export PATH=$PATH:/opt/:/home/kapper/.local/bin/
export PATH=$PATH:/opt/:$HOME/.local/bin/:$HOME/.dotnet:$HOME/go/bin/
export DOTNET_ROOT=$HOME/.dotnet
# Example path for autocompletion using libclang-9-dev package, obtained by the following command
# find /usr/ -name libclang.so.1 2>/dev/null
export LIBCLANG="/usr/lib/llvm-10/lib/libclang.so.1"
export LIBCLANG="$(command -v clang &>/dev/null && ldconfig -p | sort | grep libclang-[0-9]. | awk -F "> " '{print$2}' | tail -n 1)"
# Source a top-secret alias file
if [ -f ~/.bash_secrets ]; then
if [ -e ~/.bash_secrets ]; then
. ~/.bash_secrets
fi
if command -v tmux &> /dev/null && [ -n "$PS1" ] && [[ ! "$TERM" =~ screen ]] && [[ ! "$TERM" =~ tmux ]] && [ -z "$TMUX" ]; then
exec tmux
fi
# Set the default terminal to use konsole, with kapper profile
# + Execute tmux on start
if [ -e ~/.local/share/konsole/kapper.profile ]; then
if command -v tmux &>/dev/null; then
export TERMINAL='konsole --profile kapper -e tmux'
else
export TERMINAL='konsole --profile kapper'
fi
fi
# Conditionally enables font glyphs in .vimrc if available
if [ -e ~/.local/share/fonts/sauce-code-pro.otf ]; then
export SAUCE=1
fi
# Less colors for man pages
export PAGER=less
default=$(tput sgr0)
red=$(tput setaf 1)
green=$(tput setaf 2)
purple=$(tput setaf 5)
orange=$(tput setaf 9)
# Begin blinking
export LESS_TERMCAP_mb=$red
# Begin bold
export LESS_TERMCAP_md=$orange
# End mode
export LESS_TERMCAP_me=$default
# End standout-mode
export LESS_TERMCAP_se=$default
# Begin standout-mode - info box
export LESS_TERMCAP_so=$purple
# End underline
export LESS_TERMCAP_ue=$default
# Begin underline
export LESS_TERMCAP_us=$green
# Allow mouse wheel movement for less output (manpages, diffs)
export LESS='--mouse --wheel-lines 2'
# Set additional flags for less
# + -R for raw control characters
# + -w to highlight first unread line when jumping N>1 lines down
# + -#2 to shift 2 columns horizontally when right / left arrow is pressed
export LESS="$LESS -R -w -#2"
if ! [ command -v conda &>/dev/null ] && [ -e ~/Code/Clones/mambaforge/bin/conda ] && ! grep -e conda ~/.bashrc &>/dev/null; then
if ! (~/Code/Clones/mambaforge/bin/conda init | awk -F "==>" '{print $1}'); then
echo "[dot] ERROR: Failed to initialize Conda."
fi
echo "[dot] WARN: Ran \`conda init\`; Conda was installed but not initialized"
source ~/.bashrc
fi

View File

@ -115,4 +115,3 @@ if ! shopt -oq posix; then
. /etc/bash_completion
fi
fi
. "$HOME/.cargo/env"

View File

@ -0,0 +1 @@
Subproject commit 1fa1d0f29047979b9ffd541eb330756ac4b348ab

View File

@ -764,3 +764,6 @@ tmap <delete> eval -q fm.ui.taskview.task_remove()
tmap <C-l> redraw_window
tmap <ESC> taskview_close
copytmap <ESC> q Q w <C-c>
default_linemode devicons

2
.gitignore vendored
View File

@ -1,3 +1,5 @@
.bash_secrets
.idea/
.config/Code/Backups/*
.config/Code/*Cache*/*
.config/Code/Coo*

12
.gitmodules vendored
View File

@ -23,3 +23,15 @@
[submodule ".vim/bundle/ale"]
path = .vim/bundle/ale
url = https://github.com/dense-analysis/ale
[submodule ".tmux/plugins/tpm"]
path = .tmux/plugins/tpm
url = https://github.com/tmux-plugins/tpm.git
[submodule ".tmux/plugins/tmux-yank"]
path = .tmux/plugins/tmux-yank
url = https://github.com/tmux-plugins/tmux-yank
[submodule ".tmux/plugins/tmux-better-mouse-mode"]
path = .tmux/plugins/tmux-better-mouse-mode
url = https://github.com/NHDaly/tmux-better-mouse-mode
[submodule ".config/ranger/plugins/ranger_devicons"]
path = .config/ranger/plugins/ranger_devicons
url = https://github.com/alexanderjeurissen/ranger_devicons

28
.gitmux.conf Normal file
View File

@ -0,0 +1,28 @@
tmux:
symbols:
branch: ""
hashprefix: ':'
ahead: ↑·
behind: ↓·
staged: '● '
conflict: '✖ '
modified: '✚ '
untracked: '… '
stashed: '⚑ '
clean: ✓
styles:
clear: '#[fg=default]'
state: '#[fg=red,bold]'
branch: '#[fg=white,bold]'
remote: '#[fg=cyan]'
staged: '#[fg=green,bold]'
conflict: '#[fg=red,bold]'
modified: '#[fg=red,bold]'
untracked: '#[fg=magenta,bold]'
stashed: '#[fg=cyan,bold]'
clean: '#[fg=green,bold]'
divergence: '#[fg=default]'
layout: ["#[bold]⎇ ", branch, ' ⥂ ', remote-branch, divergence, ' - ', flags]
options:
branch_max_len: 30
branch_trim: right

28
.gitmux.conf.docker Normal file
View File

@ -0,0 +1,28 @@
tmux:
symbols:
branch: "B:"
hashprefix: ':'
ahead: '->'
behind: '<-'
staged: ''
conflict: 'X'
modified: '+'
untracked: '...'
stashed: '[]'
clean: '$'
styles:
clear: '#[fg=default]'
state: '#[fg=red,bold]'
branch: '#[fg=white,bold]'
remote: '#[fg=cyan]'
staged: '#[fg=green,bold]'
conflict: '#[fg=red,bold]'
modified: '#[fg=red,bold]'
untracked: '#[fg=magenta,bold]'
stashed: '#[fg=cyan,bold]'
clean: '#[fg=green,bold]'
divergence: '#[fg=default]'
layout: ["#[bold]", branch, remote-branch, divergence, ' - ', flags]
options:
branch_max_len: 30
branch_trim: right

Binary file not shown.

View File

@ -0,0 +1,7 @@
[Appearance]
ColorScheme=Breeze
Font=SauceCodePro Nerd Font Mono,10,-1,5,50,0,0,0,0,0
[General]
Name=kapper
Parent=FALLBACK/

121
.tmux.conf Normal file
View File

@ -0,0 +1,121 @@
###############################################################################
## Author: Shaun Reed | Contact: shaunrd0@gmail.com | URL: www.shaunreed.com ##
## ##
## A custom tmux multiplexer config / layout created for Manjaro i3 ##
##+ Inspired by vim-powerline: https://github.com/Lokaltog/powerline ##
## ##
## This config created and tested with Powerline Consolas ##
##+ https://github.com/Lokaltog/powerline-fonts ##
##+ Some symbols may require Font Awesome 5 Free Solid ##
## ##
###############################################################################
# .tmux.conf
#
# If symbols or powerline layout fail to appear...
#+ Check your terminal emulator font settings include these fonts
#+ Check that required fonts are installed
#
# Note: The use of 256colours in this file allows for portable color definitions between platforms and applications
#+ Changing to a different color interpretation may result in some apps displaying colors differently than others
#+ Vim plugin 'Colorizer' does not reflect the actual 256colour values
#+ See https://jonasjacek.github.io/colors/ for a full list of 256colours
# Settings for terminal text selection / copy options
# + Source: https://www.seanh.cc/2020/12/27/copy-and-paste-in-tmux/
# + Depends: https://github.com/tmux-plugins/tmux-yank#linux
set -g mouse on
# These bindings are for X Windows only. If you're using a different
# window system you have to replace the `xsel` commands with something
# else. See https://github.com/tmux/tmux/wiki/Clipboard#available-tools
bind -T copy-mode DoubleClick1Pane select-pane \; send -X select-word \; send -X copy-pipe-no-clear "xsel -i"
bind -T copy-mode-vi DoubleClick1Pane select-pane \; send -X select-word \; send -X copy-pipe-no-clear "xsel -i"
bind -n DoubleClick1Pane select-pane \; copy-mode -M \; send -X select-word \; send -X copy-pipe-no-clear "xsel -i"
bind -T copy-mode TripleClick1Pane select-pane \; send -X select-line \; send -X copy-pipe-no-clear "xsel -i"
bind -T copy-mode-vi TripleClick1Pane select-pane \; send -X select-line \; send -X copy-pipe-no-clear "xsel -i"
bind -n TripleClick1Pane select-pane \; copy-mode -M \; send -X select-line \; send -X copy-pipe-no-clear "xsel -i"
bind -n MouseDown2Pane run "tmux set-buffer -b primary_selection \"$(xsel -o)\"; tmux paste-buffer -b primary_selection; tmux delete-buffer -b primary_selection"
#set -g @plugin 'tmux-plugins/tpm'
#set -g @plugin 'tmux-plugins/tmux-yank'
#set -g @yank_action 'copy-pipe-no-clear'
#bind -T copy-mode C-c send -X copy-pipe-no-clear "xsel -i --clipboard"
#bind -T copy-mode-vi C-c send -X copy-pipe-no-clear "xsel -i --clipboard"
set-option -s set-clipboard external
bind-key -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel "xclip -selection clipboard -i"
# Remap shortcut prefix from 'C-b' to 'C-z'
#unbind C-b
#set-option -g prefix C-z
#bind-key C-z send-prefix
set-option -g prefix C-b
bind-key C-b send-prefix
# Reload tmux.conf in this session
bind r source-file ~/.tmux.conf
bind h split-window -h
bind v split-window -v
# switch panes using Alt-arrow without prefix
bind -n M-Left select-pane -L
bind -n M-Right select-pane -R
bind -n M-Up select-pane -U
bind -n M-Down select-pane -D
set-option -g status-position top
# Status update interval
set -g status-interval 1
# Basic status bar colors
set -g status-style fg=colour240,bg=colour233
# Left side of status bar
set -g status-left-style bg=colour233,fg=colour243
set -g status-left-length 40
# Note: Powerline font requires alternate of bold on right side
# + Corrects gap on right of character that reveals BG color
# Note: No bold required, no BG reveal produced by symbol gaps on left side
# + Font: Sauce Code Pro (NERD patch)
# Right side of status bar
set -g status-right-style bg=colour233,fg=colour243
set -g status-right-length 100
# Set gitmux to appear in center of tmux status bar
run 'bash -c "if command -v $HOME/go/bin/gitmux &>/dev/null; then test -f $HOME/.gitmux.conf || $HOME/go/bin/gitmux -printcfg > $HOME/.gitmux.conf; fi"'
set -g window-status-current-format "#($HOME/go/bin/gitmux -cfg $HOME/.gitmux.conf \"#{pane_current_path}\")"
# Or if you don't want gitmux
#set -g window-status-current-format "#[fg=colour255,bg=colour233]#[fg=colour100,nobold] #(whoami)@#H #[fg=colour255,bg=colour233,nobold]"
run-shell "bash ~/.tmux/tmux-conf.sh"
# Check if we are running xorg
#set -g status-left "#[fg=colour233,bg=colour100,bold] #S #[fg=colour100,bg=colour240,nobold]#[fg=colour233,bg=colour240] #(whoami) #[fg=colour240,bg=colour235]#[fg=colour240,bg=colour235] #(hostname) #[fg=colour235,bg=colour233]#[fg=colour240,bg=colour233]"
#set -g status-right "#[fg=colour235,bg=colour233,bold]#[fg=colour240,bg=colour235,nobold] %H:%M:%S #[fg=colour240,bg=colour235,bold]#[fg=colour233,bg=colour240,nobold] %d-%b-%y #[fg=colour100,bg=colour240,bold]#[fg=colour233,bg=colour100,bold] #(cd #{pane_current_path}; basename `git rev-parse --show-toplevel`) "
# Current window status
set -g window-status-current-style bg=colour233,fg=colour100
# Window with activity status
set -g window-status-activity-style bg=colour233,fg=colour245
# Window separator
set -g window-status-separator ""
# Window status alignment
set -g status-justify centre
# Pane border
set -g pane-border-style bg=default,fg=colour238
# Active pane border
set -g pane-active-border-style bg=default,fg=colour100
# Pane number indicator
set -g display-panes-colour colour233
set -g display-panes-active-colour colour245
# Clock mode
set -g clock-mode-colour colour100
set -g clock-mode-style 24
# Message
set -g message-style bg=colour100,fg=black
# Command message
set -g message-command-style bg=colour233,fg=black
set -g default-terminal "screen-256color"
# Mode
set -g mode-style bg=colour100,fg=colour235

35
.tmux/.tmux-gui.conf Normal file
View File

@ -0,0 +1,35 @@
set -g status-left "#[fg=colour233,bg=colour100,bold] #S #[fg=colour100,bg=colour240,nobold]#[fg=colour233,bg=colour240] #(whoami) #[fg=colour240,bg=colour235]#[fg=colour240,bg=colour235] #(hostname) #[fg=colour235,bg=colour233]#[fg=colour240,bg=colour233]"
set -g status-right "#[fg=colour235,bg=colour233,bold]#[fg=colour240,bg=colour235,nobold] %H:%M:%S #[fg=colour240,bg=colour235,bold]#[fg=colour233,bg=colour240,nobold] %d-%b-%y #[fg=colour100,bg=colour240,bold]#[fg=colour233,bg=colour100,bold] #(git -C #{pane_current_path} remote get-url origin | sed 's/.*[/]//' | sed 's/\.git//') "
# Settings for terminal text selection / copy options
# + Source: https://www.seanh.cc/2020/12/27/copy-and-paste-in-tmux/
# + Depends: https://github.com/tmux-plugins/tmux-yank#linux
set -g mouse on
# These bindings are for X Windows only. If you're using a different
# window system you have to replace the `xsel` commands with something
# else. See https://github.com/tmux/tmux/wiki/Clipboard#available-tools
bind -T copy-mode DoubleClick1Pane select-pane \; send -X select-word \; send -X copy-pipe-no-clear "xsel -i"
bind -T copy-mode-vi DoubleClick1Pane select-pane \; send -X select-word \; send -X copy-pipe-no-clear "xsel -i"
bind -n DoubleClick1Pane select-pane \; copy-mode -M \; send -X select-word \; send -X copy-pipe-no-clear "xsel -i"
bind -T copy-mode TripleClick1Pane select-pane \; send -X select-line \; send -X copy-pipe-no-clear "xsel -i"
bind -T copy-mode-vi TripleClick1Pane select-pane \; send -X select-line \; send -X copy-pipe-no-clear "xsel -i"
bind -n TripleClick1Pane select-pane \; copy-mode -M \; send -X select-line \; send -X copy-pipe-no-clear "xsel -i"
bind -n MouseDown2Pane run "tmux set-buffer -b primary_selection \"$(xsel -o)\"; tmux paste-buffer -b primary_selection; tmux delete-buffer -b primary_selection"
# List of plugins and their settings
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'nhdaly/tmux-better-mouse-mode'
set -g @scroll-speed-num-lines-per-scroll 2
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-yank'
set -g @yank_action 'copy-pipe-no-clear'
bind -T copy-mode C-c send -X copy-pipe-no-clear "xsel -i --clipboard"
bind -T copy-mode-vi C-c send -X copy-pipe-no-clear "xsel -i --clipboard"
# Other examples:
# set -g @plugin 'github_username/plugin_name'
# set -g @plugin 'git@github.com/user/plugin'
# set -g @plugin 'git@bitbucket.com/user/plugin'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run -b '~/.tmux/plugins/tpm/tpm'

16
.tmux/.tmux-tty.conf Normal file
View File

@ -0,0 +1,16 @@
set -g status-left "#[fg=colour233,bg=colour100,bold] #S #[fg=colour100,bg=colour240,nobold]#[fg=colour233,bg=colour240] #(whoami) #[fg=colour240,bg=colour235]#[fg=colour240,bg=colour235] #(hostname) #[fg=colour235,bg=colour233]#[fg=colour240,bg=colour233]"
set -g status-right "#[fg=colour235,bg=colour233,bold]#[fg=colour240,bg=colour235,nobold] %H:%M:%S #[fg=colour240,bg=colour235,bold]#[fg=colour233,bg=colour240,nobold] %d-%b-%y #[fg=colour100,bg=colour240,bold]#[fg=colour233,bg=colour100,bold] #(git -C #{pane_current_path} remote get-url origin | sed 's/.*[/]//' | sed 's/\.git//') "
# List of plugins and their settings
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'nhdaly/tmux-better-mouse-mode'
set -g @scroll-speed-num-lines-per-scroll 2
set -g @plugin 'tmux-plugins/tpm'
# Other examples:
# set -g @plugin 'github_username/plugin_name'
# set -g @plugin 'git@github.com/user/plugin'
# set -g @plugin 'git@bitbucket.com/user/plugin'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run -b '~/.tmux/plugins/tpm/tpm'

@ -0,0 +1 @@
Subproject commit aa59077c635ab21b251bd8cb4dc24c415e64a58e

@ -0,0 +1 @@
Subproject commit 1b1a436e19f095ae8f825243dbe29800a8acd25c

1
.tmux/plugins/tpm Submodule

@ -0,0 +1 @@
Subproject commit 26d9ace1b47f4591b2afdf333442a498311b6ace

7
.tmux/tmux-conf.sh Executable file
View File

@ -0,0 +1,7 @@
#!/bin/bash
if [ -z ${DISPLAY+notset} ]; then
tmux source-file ~/.tmux/.tmux-tty.conf
else
tmux source-file ~/.tmux/.tmux-gui.conf
fi

80
.vimrc
View File

@ -2,6 +2,9 @@
" Double-quotes are commented out code and can be removed or added
" General Vim Settings
let is_docker = filereadable(expand('/.dockerenv'))
let has_sauce = filereadable(expand('~/.local/share/fonts/sauce-code-pro.otf'))
let is_xorg = exists("$DISPLAY")
" Highlight the column cursor is on
" May slow screen redraw time, so off by default
@ -18,18 +21,20 @@ set undofile
" Combine vim clipboard with global clipboard buffer
" Allows using y and p to copy into CTRL-C buffer, vice versa
" :help 'clipboard'
set clipboard+=unnamed
set clipboard=unnamed
set clipboard+=unnamedplus
" Allows true colors in vim (> 8 bit colors)
" :help termguicolors
set termguicolors
"set termguicolors
" Custom formatting based on filetype
" :help autocmd
"" autocmd FileType yaml set tabstop=2 shiftwidth=2
" Highlight column 80 in c and cpp files
autocmd FileType cpp,c set colorcolumn=80
" Highlight characters past column N in source files based on file type
autocmd FileType cpp,c match ErrorMsg '\%>80v.\+'
autocmd FileType cs match ErrorMsg '\%>120v.\+'
" Define function in vim to remove whitespace
fun! TrimWhitespace()
@ -38,8 +43,9 @@ fun! TrimWhitespace()
call winrestview(l:save)
endfun
"Call this on every attempt to save a file of types defined below..
autocmd BufWritePre *.cpp,*.h,*.c,*.php :call TrimWhitespace()
autocmd BufWritePre *.cpp,*.h,*.c,*.php,*.cs,*.yml,*.txt,*.md :call TrimWhitespace()
""autocmd BufWritePre *.cpp,*.h,*.c,*.php :%s/\s\+$//ge
" Set terminal title when opening file
"" autocmd BufEnter * let &titlestring = ' ' . expand("%:t")
"" set title
@ -86,8 +92,8 @@ nnoremap <C-e> <C-w>
" Build and run keybinds
"" nnoremap <C-b> :!make -C build/
nnoremap <C-b> :!cmake -S . -B ./build/ && cmake --build ./build
nnoremap <C-d> :!./build/scrap
"nnoremap <C-b> :!cmake -S . -B ./build/ && cmake --build ./build
"nnoremap <C-d> :!./build/scrap
" Vim Plugin Settings
@ -135,39 +141,65 @@ nnoremap <C-c> :ColorToggle<CR>
set termencoding=utf-8
set encoding=utf-8
" air-line
let g:airline_powerline_fonts = 1
if !exists('g:airline_symbols')
let g:airline_symbols = {}
endif
" Set glyphs based on font availability and environment (xorg / docker)
if and(and(has_sauce, is_xorg), !is_docker)
let g:airline_left_sep = ''
let g:airline_left_alt_sep = ''
let g:airline_right_sep = ''
let g:airline_right_alt_sep = ''
let g:airline_symbols.branch = ''
let g:airline_symbols.readonly = ''
let g:airline_symbols.linenr = ''
elseif is_xorg
" unicode symbols
let g:airline_left_sep = '»'
let g:airline_left_sep = '▶'
let g:airline_right_sep = '«'
let g:airline_right_sep = '◀'
let g:airline_symbols.linenr = '␊'
let g:airline_symbols.linenr = '␤'
let g:airline_symbols.colnr = ' ㏇:'
let g:airline_symbols.colnr = ' ℅:'
let g:airline_symbols.crypt = '🔒'
let g:airline_symbols.linenr = '☰'
let g:airline_symbols.linenr = ' ␊:'
let g:airline_symbols.linenr = ' ␤:'
let g:airline_symbols.linenr = '¶'
let g:airline_symbols.maxlinenr = ''
let g:airline_symbols.maxlinenr = '㏑'
let g:airline_symbols.branch = '⎇'
let g:airline_symbols.paste = 'ρ'
let g:airline_symbols.paste = 'Þ'
let g:airline_symbols.paste = '∥'
let g:airline_symbols.spell = 'Ꞩ'
let g:airline_symbols.notexists = 'Ɇ'
let g:airline_symbols.whitespace = 'Ξ'
" TODO: Add condition to toggle unicode / airline symbols
" By default use unicode for compatability on all systems
" airline symbols
""let g:airline_left_sep = ''
""let g:airline_left_alt_sep = ''
""let g:airline_right_sep = ''
""let g:airline_right_alt_sep = ''
""let g:airline_symbols.branch = ''
""let g:airline_symbols.readonly = ''
""let g:airline_symbols.linenr = ''
else
" unicode symbols
let g:airline_left_sep = ''
let g:airline_left_sep = ''
let g:airline_right_sep = ''
let g:airline_right_sep = ''
let g:airline_symbols.colnr = ''
let g:airline_symbols.colnr = ''
let g:airline_symbols.crypt = ''
let g:airline_symbols.linenr = ''
let g:airline_symbols.linenr = ''
let g:airline_symbols.linenr = ''
let g:airline_symbols.linenr = ''
let g:airline_symbols.maxlinenr = ''
let g:airline_symbols.maxlinenr = ''
let g:airline_symbols.branch = ''
let g:airline_symbols.paste = ''
let g:airline_symbols.paste = ''
let g:airline_symbols.paste = ''
let g:airline_symbols.spell = ''
let g:airline_symbols.notexists = ''
let g:airline_symbols.whitespace = ''
endif
" Clang completeion settings

13
Dockerfile Normal file
View File

@ -0,0 +1,13 @@
ARG REPO='https://git.shaunreed.com/shaunrd0/dot'
FROM ubuntu:latest
COPY . /dot
ENV TERM=xterm-256color
# Install additional packages we need
RUN apt update -y && apt upgrade -y
RUN apt install -y git stow vim tmux ranger clang wget curl golang-go
RUN go install github.com/arl/gitmux@latest
# Update submodules for plugins
RUN cd /dot && git submodule update --init && cp .gitmux.conf.docker .gitmux.conf
RUN rm ~/.bashrc && rm -rf /dot/.tmux/plugins/tmux-yank
RUN cd /dot && stow -t /root .

View File

@ -1,6 +1,4 @@
# Headless
Dotfiles configurations for headless Ubuntu 20.04 linux environments. Be sure to clone recursively if you want to grab updated plugins / submodules included. For example, using Pathogen with Vim to manage plugins requires that the plugin to be installed are cloned to the `~/.vim/bundle/` directory. Cloning recursively allows git to clone these same nested repositories/submodules within this directory so Pathogen can handle running the Vim plugins.
Dotfiles configurations for headless Ubuntu 22.04 linux environments. Be sure to clone recursively if you want to grab updated plugins / submodules included. For example, using Pathogen with Vim to manage plugins requires that the plugin to be installed are cloned to the `~/.vim/bundle/` directory. Cloning recursively allows git to clone these same nested repositories/submodules within this directory so Pathogen can handle running the Vim plugins.
Once installed, editing source code in vim supports features displayed in the screenshot below
@ -11,6 +9,7 @@ Once installed, editing source code in vim supports features displayed in the sc
Easiest installation is to clone repository into home directory -
```bash
sudo apt install git stow vim xsel xclip tmux ranger clang yakuake wget curl
git clone --recursive https://github.com/shaunrd0/dot ~/dot
cd ~/dot/
stow --adopt .
@ -24,7 +23,9 @@ cd /path/to/dot/
stow --adopt -t ~ .
```
**Warning:** `--adopt` is used to link conflicting files, but doing so could result in the loss of some configs within your local copy of the repository. After running `stow --adopt .`, be sure to check `git status` is clean. If a file has been modified, discard the local changes to be up-to-date with `origin/master` and it will be restored on your system as well, since the files are now linked.
**Warning:** `--adopt` is used to link conflicting files, but doing so could result in the loss of some configs within your local copy of the repository and on your local system.
After running `stow --adopt .`, be sure to check `git status` is clean.
If a file has been modified, discard the local changes to be up-to-date with `origin/master` and it will be restored on your system as well, since the files are now linked. **Your conflicting local system configurations will be lost** unless you back them up manually.
We could run the following commands to restore changed files
```bash
@ -49,6 +50,24 @@ Submodule path '.vim/bundle/vim-signify': checked out '16eee41d2b267523b84bd4ac1
```
### Docker
You can run these dotfiles in a docker container -
```bash
git clone git@github.com:shaunrd0/dot.git
cd dot
docker build -t dot .
docker run -it dot bash
```
This container has the following packages installed and uses `ubuntu:latest` as a base.
```
git stow vim tmux ranger clang wget curl golang-go
```
### Install Clang Completion
**These configurations require the installation of clang for clang completion**
@ -57,13 +76,18 @@ If you don't want clang completion, just remove the plugin directory from `~/.vi
If you don't remove clang completion and skip the following steps, vim will show errors when opening source code files. This is because these configurations use clang completion for source code auto completion and drop-down menus within vim.
Note that the `printf` command may take some time to finish, since it is searching your system for a needed file.
```bash
sudo apt install clang
printf "export LIBCLANG=\""$(find /usr/ -name libclang.so.1 2>/dev/null)"\"\n\n" >> .bash_aliases
echo "let g:clang_library_path=\$LIBCLANG" >> ~/.vimrc
source ~/.bashrc
```
### Gitmux
To enable the gitmux status bar in tmux sessions
```bash
sudo apt install golang-go
go install github.com/arl/gitmux@latest
```

View File

@ -1,5 +0,0 @@
# A fix for a common issue found in virtual box
# https://forums.linuxmint.com/viewtopic.php?t=247850
# https://askubuntu.com/questions/1014172/virtualbox-unresponsive-area-on-desktop
#################################################################################
ps aux www |grep 'VBoxClient --draganddrop' | awk '{print $2}' | xargs kill