Created
October 19, 2020 00:36
-
-
Save fouric/511c1656faf059fde76f7d35e3cef7a5 to your computer and use it in GitHub Desktop.
some dotfiles
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# if not running interactively, don't do anything | |
case $- in | |
*i*) ;; | |
*) return;; | |
esac | |
HISTCONTROL=ignoreboth # don't put duplicate lines or lines starting with space in the history. | |
export LESSHISTFILE=/dev/null # disable less's history feature | |
HISTSIZE=-1 # unlimited number of history items | |
HISTFILESIZE=-1 # unlimited history file size | |
shopt -s histappend # append to the history file, don't overwrite it | |
shopt -s autocd # use autocd | |
shopt -s cdspell # automatically correct small errors while cd-ing | |
shopt -s checkhash # check to see if commands are in a hash table?... | |
shopt -s checkwinsize # check the window size after each command and, if necessary, update the values of LINES and COLUMNS. | |
shopt -s globstar # if set, the pattern "**" used in a pathname expansion context will match all files and zero or more directories and subdirectories. | |
# make less more friendly for non-text input files, see lesspipe(1) | |
if [[ -f /usr/bin/lesspipe ]] ; then | |
eval "$(SHELL=/bin/sh lesspipe)" | |
else | |
if [[ -f /usr/bin/lesspipe.sh ]] ; then | |
eval "$(SHELL=/bin/sh lesspipe.sh)" | |
fi | |
fi | |
# enable color support of ls and also add handy aliases | |
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)" | |
# input control | |
alias dv='setxkbmap dvorak' | |
alias qw='setxkbmap us' | |
alias lh='xmodmap -e "pointer = 3 2 1" &> /dev/null' | |
alias rh='xmodmap -e "pointer = 1 2 3" &> /dev/null' | |
# encryption and security | |
# TODO: either remove or fix scripts and then fix aliases to point to new locations | |
alias jup='fish -c "journal up"' | |
alias jdown='fish -c "journal down"' | |
alias passup='fish -c "passup"' | |
alias passcat='fish -c "passcat"' | |
alias passedit='fish -c "passedit"' | |
alias passdown='fish -c "passdown"' | |
alias pankiup='$HOME/code/shell/panki-up.sh' | |
alias pankidown='$HOME/code/shell/panki-down.sh' | |
alias panki='anki -b $HOME/ramdisk/password-anki' | |
# long commands | |
alias update='sudo apt-get update && sudo apt-get dist-upgrade -y && sudo apt-get autoremove' | |
alias i='python3 ~/code/lightning-cd/lightning-cd.py ~/ramdisk/.lightningpath && cd "`cat ~/ramdisk/.lightningpath`"' | |
alias open='xdg-open' | |
# TODO: turn this into a function that detects if the emacs server is running | |
EMACS='emacs -nw --no-splash' | |
# Programming aliases | |
alias ls='ls --color=auto' | |
alias grep='grep --color=auto' | |
alias les='less -r' | |
alias l='ls -AlFi --color=always' | |
alias t='tmux -2' | |
alias v='nvim' | |
alias e='$EMACS' | |
alias cp='cp -r' | |
alias scp='scp -r' | |
alias remap='setxkbmap -option ctrl:nocaps' | |
alias ch='mosh -- ch screen -RD' | |
alias rs='nohup redshift > /dev/null & disown' | |
alias g='grep -v grep | grep -i --color=always' | |
alias c='pushd' | |
alias p='popd' | |
alias mm='make clean && make' | |
alias agdb='arm-none-eabi-gdb -q' | |
alias ngdb='arm-none-eabi-gdb -q main.elf' | |
alias totally='sudo' | |
alias literally='sudo' | |
alias psuedo='sudo' | |
alias checkout='git checkout' | |
alias status='git status' | |
alias add='git add' | |
alias push='git push' | |
alias pull='git pull' | |
alias branch='git branch' | |
alias commit='git commit' | |
alias clone='git clone' | |
alias log='git log' | |
alias bop='git push' | |
alias gitrekt='git push --force origin master' | |
alias diff='diffit' | |
function diffit() { | |
if [[ $# -eq 0 ]]; then | |
git diff | |
else | |
diff "$@" | |
fi | |
} | |
# enable programmable completion features | |
if [ -f /usr/share/bash-completion/bash_completion ]; then | |
. /usr/share/bash-completion/bash_completion | |
fi | |
if [ -n "$DISPLAY" -a "$TERM" == "xterm" ]; then | |
export TERM=xterm-256color | |
fi | |
# turn on vi keyboard bindings | |
set -o vi | |
bind '"jk": vi-movement-mode' # thanks http://superuser.com/questions/522634/vim-shortcut-in-terminal/536428#536428 | |
if [[ -f /usr/bin/nvim ]]; then | |
export EDITOR=/usr/bin/nvim | |
export VISUAL=/usr/bin/nvim | |
else | |
export EDITOR=/usr/bin/emacs | |
export VISUAL=/usr/bin/emacs | |
fi | |
# bind up and down C-p and C-n to forward and backward history search | |
bind '"\e[A": history-search-backward' | |
bind '"\e[B": history-search-forward' | |
bind '"\C-p": previous-history' | |
bind '"\C-n": next-history' | |
bind '"\C-P": history-search-backward' | |
bind '"\C-N": history-search-forward' | |
# let C-l invoke "ls" | |
bind -x '"\C-L": ls' | |
function prompt-command() { | |
#local last_retval=$? | |
#echo $last_retval | |
#local last_command="$(fc -ln -1)" | |
if [ "$(id -u)" -ne 0 ]; then | |
echo "$(date "+%Y-%m-%d.%H:%M:%S") $(pwd) $last_command" >> ~/.extended_bash_history; | |
fi | |
#if (( $last_retval != 0 )); then | |
# echo "triggered: $last_command" | |
# if [[ "$last_command" =~ ^https://github.com/.*/.*$ ]]; then | |
# echo "triggered2: $last_command" | |
# git clone "$last_command"; | |
# fi | |
#fi | |
} | |
export PROMPT_COMMAND='prompt-command' | |
if [ -n "$SSH_SESSION" -o -n "$SSH_CLIENT" ]; then | |
HOST_FRAGMENT="$(tput setaf 196) [ \h ]$(tput sgr0)" | |
fi | |
if [ "$(whoami)" != "grantv" -a "$(whoami)" != "fouric" ]; then | |
USER_FRAGMENT="$(tput setaf 8) ( \u )$(tput sgr0)" | |
fi | |
SOLARIZED_PROMPT="\[$(tput sgr0)\]\[$(tput setaf 11)\] \w \[$(tput setaf 226)\]>\[$(tput setaf 214)\]>\[$(tput setaf 202)\]>\[$(tput sgr0)\] " | |
RAINBOW_PROMPT="\[$(tput sgr0)\]$HOST_FRAGMENT$USER_FRAGMENT\[$(tput setaf 99)\] \w \[$(tput setaf 196)\]>\[$(tput setaf 226)\]>\[$(tput setaf 154)\]>\[$(tput sgr0)\] " | |
PS1="$SOLARIZED_PROMPT" | |
# Load autojump | |
if [[ -f /usr/share/autojump/autojump.sh ]] ; then | |
. /usr/share/autojump/autojump.sh | |
fi | |
# Base16 Shell | |
BASE16_SHELL="$HOME/.config/base16-shell/base16-default.dark.sh" | |
[[ -s $BASE16_SHELL ]] && source $BASE16_SHELL | |
man() { | |
env \ | |
LESS_TERMCAP_mb=$(printf "\e[1;31m") \ | |
LESS_TERMCAP_md=$(printf "\e[1;31m") \ | |
LESS_TERMCAP_me=$(printf "\e[0m") \ | |
LESS_TERMCAP_se=$(printf "\e[0m") \ | |
LESS_TERMCAP_so=$(printf "\e[1;44;33m") \ | |
LESS_TERMCAP_ue=$(printf "\e[0m") \ | |
LESS_TERMCAP_us=$(printf "\e[1;32m") \ | |
man "$@" | |
} | |
# ignore C-s to suspend (which requires C-q to resume) | |
stty -ixon | |
function take() { | |
shuf -n $1 /home/fouric/mercurial/soft | |
} | |
bind "set completion-ignore-case on" | |
bind "set show-all-if-ambiguous on" | |
export PATH=/home/fouric/other-code/eagle/:$PATH | |
if [ -f /home/fouric/.config/broot/launcher/bash/br ]; then | |
source /home/fouric/.config/broot/launcher/bash/br | |
fi | |
export XDG_CONFIG_HOME=$HOME/.config | |
export XDG_CACHE_HOME=$HOME/.cache | |
export XDG_DATA_HOME=$HOME/.local/share |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[user] | |
name = fouric | |
email = [email protected] | |
[push] | |
default = simple | |
[alias] | |
s = status | |
c = commit -m | |
a = add | |
o = push | |
out = push | |
i = pull | |
b = branch | |
co = checkout | |
cl = clone | |
lol = log --graph --pretty=oneline --decorate --abbrev-commit | |
lola = log --graph --pretty=oneline --decorate --abbrev-commit --all | |
lg = log --all --graph --pretty=format:'%C(yellow)%h%Creset -%C(auto)%d%Creset %s %Cgreen(%cr) %C(blue)<%an>%Creset' --abbrev-commit | |
exec = "!exec " | |
change-commits = "!f() { VAR=$1; OLD=$2; NEW=$3; shift 3; git filter-branch --env-filter \"if [ \\\"$`echo $VAR`\\\" = '$OLD' ]; then export $VAR='$NEW'; fi\" $@; }; f " | |
rao = remote add origin | |
rro = remote remove origin | |
brdel = branch -d | |
brdelo = push origin --delete | |
puo = push -u origin | |
rekt = push --force | |
[core] | |
editor = vim | |
[filter "lfs"] | |
clean = git-lfs clean -- %f | |
smudge = git-lfs smudge -- %f | |
process = git-lfs filter-process | |
required = true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set -g status-position top | |
#set -g status off | |
set -g default-terminal "screen-256color" | |
set-option -g history-limit 30000 | |
# use C-x as prefix so as to not clash with Vim's C-b page up | |
unbind C-b | |
set -g prefix C-g | |
bind C-g send-prefix | |
# make copy-mode use vi keybindings | |
set-window-option -g mode-keys vi | |
bind -T copy-mode-vi v send-keys -X begin-selection | |
bind -T copy-mode-vi y send-keys -X copy-selection-and-cancel | |
bind -n M-p previous-window | |
bind -n M-n next-window | |
bind -n M-c new-window | |
# use Vim keybindings for switching panes | |
unbind Up | |
unbind Down | |
unbind Left | |
unbind Right | |
unbind j | |
unbind k | |
unbind h | |
unbind l | |
bind-key -r j select-pane -D | |
bind-key -r k select-pane -U | |
bind-key -r h select-pane -L | |
bind-key -r l select-pane -R | |
#### COLOUR (Solarized 256) | |
# https://github.com/tmux/tmux/issues/1689 | |
# default statusbar colors | |
set -g status-style fg=colour136,bg=colour235 # colour136 is yellow, colour235 is base02 | |
# default window title colors | |
#set -g window-style fg=colour244,bg=default # color244 is base0, fg=colour244 causes text to be gray | |
# active window title colors | |
set -g window-status-current-style fg=colour166,bg=default # colour166 is orange | |
# pane border | |
set -g pane-border-style fg=colour235 # colour235 is base02 | |
set -g pane-active-border-style fg=colour240 # colour240 is base01 | |
# message text | |
set -g message-style fg=colour166,bg=colour235 # colour166 is base02, colour235 is orange | |
# pane number display | |
set-option -g display-panes-active-colour colour33 #blue | |
set-option -g display-panes-colour colour166 #orange | |
# clock | |
set-window-option -g clock-mode-colour colour64 #green | |
set -g status-right "%Y-%m-%d %H%M" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" don't create backup files | |
set nobackup | |
set nowritebackup | |
" turn on syntax highlighting | |
syntax enable | |
" turn on search highlighting, incremental searches, smart case sensitivity | |
set ignorecase | |
set smartcase | |
" wildcard based file opening | |
set wildignore=*.o,*.pyc,*.bin,.*.swp,*.d,*.elf,*.fasl | |
" use relative line numbering | |
set number | |
set relativenumber | |
" keep track of your current line and character number | |
set ruler | |
" show which line the cursor is on | |
set cursorline | |
" make the default find-and-replace behavior include g (global) | |
set gdefault | |
" fold by marker (as opposed to, say, function curly braces) | |
set foldmethod=marker | |
" keep a few lines above and below the cursor | |
set scrolloff=5 | |
" Add an easier-to-access alias for escape | |
inoremap jk <esc>1l | |
" move by visual line | |
nnoremap j gj | |
nnoremap k gk | |
" just as D is d$, so should Y be y$ | |
nnoremap Y y$ | |
" mappings for easier tab management on rabidpenguin | |
nnoremap <Home> :tabnew | |
nnoremap <End> :tabclose <cr> | |
nnoremap <PageUp> :tabn <cr> | |
nnoremap <PageDown> :tabp <cr> | |
nnoremap <c-p> :tabp<cr> | |
nnoremap <c-n> :tabn<cr> | |
"execute \"set <M-h>=\eh" | |
"execute \"set <M-l>=\el" | |
nnoremap <M-h> :tabp <CR> | |
nnoremap <M-l> :tabn <CR> | |
if filereadable('/home/fouric/.config/nvim/bundle/Vundle.vim/README.md') | |
filetype off | |
set rtp+=~/.config/nvim/bundle/Vundle.vim | |
call vundle#begin() | |
Plugin 'VundleVim/Vundle.vim' " plugin management | |
"Plugin 'Valloric/YouCompleteMe' " autocomplete | |
"Plugin 'sjl/gundo.vim' " graphical undo | |
"Plugin 'rking/ag.vim' " fast and fuzzy in-file text search | |
"Plugin 'kien/ctrlp.vim' " fast and fuzzy filename search | |
Plugin 'bling/vim-airline' " a light and powerful statusline | |
"Plugin 'SirVer/ultisnips' " code snippet engine | |
"Plugin 'honza/vim-snippets' " snippets for ultisnips | |
"Plugin 'junegunn/goyo.vim' " distraction-free editing | |
"Plugin 'junegunn/limelight.vim' " only highlight surrounding code blocks | |
"Plugin 'tpope/vim-sleuth' " enable indenting for many languages | |
"Plugin 'scrooloose/nerdtree' " tree-style file browsing in a pane | |
"Plugin 'tpope/vim-commentary' " block comment | |
"Plugin 'kien/rainbow_parentheses.vim' " rainbow parenthesis for Lisp | |
Plugin 'chriskempson/base16-vim' | |
Plugin 'chriskempson/vim-tomorrow-theme' | |
call vundle#end() | |
"let base16colorspace=256 " Access colors present in 256 colorspace | |
"set background=dark | |
"colorscheme base16-default | |
endif | |
" enable file type detection, and indentation and plugins | |
filetype plugin indent on | |
" airline symbols | |
if !exists('g:airline_symbols') | |
let g:airline_symbols = {} | |
endif | |
" unicode symbols | |
let g:airline_powerline_fonts = 1 | |
" automatically enable Limelight when Goyo is enabled | |
autocmd User GoyoEnter Limelight | |
autocmd User GoyoLeave Limelight! | |
" map leader to comma | |
let mapleader="," | |
" clear the hlsearch term | |
nnoremap <leader>h :let @/=''<CR> | |
nnoremap <leader>n :tabnew | |
" map semicolon to colon in normal mode | |
nnoremap ; : | |
" tab settings | |
set tabstop=4 | |
set shiftwidth=4 | |
nnoremap <space> 10jzz | |
nnoremap <backspace> 10kzz | |
"" Show tabs and trailing whitespace visually | |
set list listchars=tab:>-,trail:.,extends:> | |
if (&termencoding == "utf-8") | |
set list listchars=tab:û÷,trail:÷,extends:?,nbsp:? | |
else | |
set list | |
set listchars=tab:>-,trail:.,extends:>,nbsp:_ | |
endif | |
"set listchars=tab:🌭\ | |
"set tabstop=2 | |
"set spell | |
"set spelllang=en_us | |
noremap <c-g> <c-c> | |
inoremap <c-g> <c-c> | |
" disable mouse | |
set mouse= | |
colorscheme Tomorrow-Night |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" vi:syntax=vim | |
" base16-vim (https://github.com/chriskempson/base16-vim) | |
" by Chris Kempson (http://chriskempson.com) | |
" Default Dark scheme by Chris Kempson (http://chriskempson.com) | |
" This enables the coresponding base16-shell script to run so that | |
" :colorscheme works in terminals supported by base16-shell scripts | |
" User must set this variable in .vimrc | |
" let g:base16_shell_path=base16-builder/output/shell/ | |
if !has("gui_running") | |
if exists("g:base16_shell_path") | |
execute "silent !/bin/sh ".g:base16_shell_path."/base16-default-dark.sh" | |
endif | |
endif | |
" GUI color definitions | |
let s:gui00 = "181818" | |
let g:base16_gui00 = "181818" | |
let s:gui01 = "282828" | |
let g:base16_gui01 = "282828" | |
let s:gui02 = "383838" | |
let g:base16_gui02 = "383838" | |
let s:gui03 = "585858" | |
let g:base16_gui03 = "585858" | |
let s:gui04 = "b8b8b8" | |
let g:base16_gui04 = "b8b8b8" | |
let s:gui05 = "d8d8d8" | |
let g:base16_gui05 = "d8d8d8" | |
let s:gui06 = "e8e8e8" | |
let g:base16_gui06 = "e8e8e8" | |
let s:gui07 = "f8f8f8" | |
let g:base16_gui07 = "f8f8f8" | |
let s:gui08 = "ab4642" | |
let g:base16_gui08 = "ab4642" | |
let s:gui09 = "dc9656" | |
let g:base16_gui09 = "dc9656" | |
let s:gui0A = "f7ca88" | |
let g:base16_gui0A = "f7ca88" | |
let s:gui0B = "a1b56c" | |
let g:base16_gui0B = "a1b56c" | |
let s:gui0C = "86c1b9" | |
let g:base16_gui0C = "86c1b9" | |
let s:gui0D = "7cafc2" | |
let g:base16_gui0D = "7cafc2" | |
let s:gui0E = "ba8baf" | |
let g:base16_gui0E = "ba8baf" | |
let s:gui0F = "a16946" | |
let g:base16_gui0F = "a16946" | |
" Terminal color definitions | |
let s:cterm00 = "00" | |
let g:base16_cterm00 = "00" | |
let s:cterm03 = "08" | |
let g:base16_cterm03 = "08" | |
let s:cterm05 = "07" | |
let g:base16_cterm05 = "07" | |
let s:cterm07 = "15" | |
let g:base16_cterm07 = "15" | |
let s:cterm08 = "01" | |
let g:base16_cterm08 = "01" | |
let s:cterm0A = "03" | |
let g:base16_cterm0A = "03" | |
let s:cterm0B = "02" | |
let g:base16_cterm0B = "02" | |
let s:cterm0C = "06" | |
let g:base16_cterm0C = "06" | |
let s:cterm0D = "04" | |
let g:base16_cterm0D = "04" | |
let s:cterm0E = "05" | |
let g:base16_cterm0E = "05" | |
if exists("base16colorspace") && base16colorspace == "256" | |
let s:cterm01 = "18" | |
let g:base16_cterm01 = "18" | |
let s:cterm02 = "19" | |
let g:base16_cterm02 = "19" | |
let s:cterm04 = "20" | |
let g:base16_cterm04 = "20" | |
let s:cterm06 = "21" | |
let g:base16_cterm06 = "21" | |
let s:cterm09 = "16" | |
let g:base16_cterm09 = "16" | |
let s:cterm0F = "17" | |
let g:base16_cterm0F = "17" | |
else | |
let s:cterm01 = "10" | |
let g:base16_cterm01 = "10" | |
let s:cterm02 = "11" | |
let g:base16_cterm02 = "11" | |
let s:cterm04 = "12" | |
let g:base16_cterm04 = "12" | |
let s:cterm06 = "13" | |
let g:base16_cterm06 = "13" | |
let s:cterm09 = "09" | |
let g:base16_cterm09 = "09" | |
let s:cterm0F = "14" | |
let g:base16_cterm0F = "14" | |
endif | |
" Neovim terminal colours | |
if has("nvim") | |
let g:terminal_color_0 = "#181818" | |
let g:terminal_color_1 = "#ab4642" | |
let g:terminal_color_2 = "#a1b56c" | |
let g:terminal_color_3 = "#f7ca88" | |
let g:terminal_color_4 = "#7cafc2" | |
let g:terminal_color_5 = "#ba8baf" | |
let g:terminal_color_6 = "#86c1b9" | |
let g:terminal_color_7 = "#d8d8d8" | |
let g:terminal_color_8 = "#585858" | |
let g:terminal_color_9 = "#ab4642" | |
let g:terminal_color_10 = "#a1b56c" | |
let g:terminal_color_11 = "#f7ca88" | |
let g:terminal_color_12 = "#7cafc2" | |
let g:terminal_color_13 = "#ba8baf" | |
let g:terminal_color_14 = "#86c1b9" | |
let g:terminal_color_15 = "#f8f8f8" | |
let g:terminal_color_background = g:terminal_color_0 | |
let g:terminal_color_foreground = g:terminal_color_5 | |
if &background == "light" | |
let g:terminal_color_background = g:terminal_color_7 | |
let g:terminal_color_foreground = g:terminal_color_2 | |
endif | |
elseif has("terminal") | |
let g:terminal_ansi_colors = [ | |
\ "#181818", | |
\ "#ab4642", | |
\ "#a1b56c", | |
\ "#f7ca88", | |
\ "#7cafc2", | |
\ "#ba8baf", | |
\ "#86c1b9", | |
\ "#d8d8d8", | |
\ "#585858", | |
\ "#ab4642", | |
\ "#a1b56c", | |
\ "#f7ca88", | |
\ "#7cafc2", | |
\ "#ba8baf", | |
\ "#86c1b9", | |
\ "#f8f8f8", | |
\ ] | |
endif | |
" Theme setup | |
hi clear | |
syntax reset | |
let g:colors_name = "base16-default-dark" | |
" Highlighting function | |
" Optional variables are attributes and guisp | |
function! g:Base16hi(group, guifg, guibg, ctermfg, ctermbg, ...) | |
let l:attr = get(a:, 1, "") | |
let l:guisp = get(a:, 2, "") | |
if a:guifg != "" | |
exec "hi " . a:group . " guifg=#" . a:guifg | |
endif | |
if a:guibg != "" | |
exec "hi " . a:group . " guibg=#" . a:guibg | |
endif | |
if a:ctermfg != "" | |
exec "hi " . a:group . " ctermfg=" . a:ctermfg | |
endif | |
if a:ctermbg != "" | |
exec "hi " . a:group . " ctermbg=" . a:ctermbg | |
endif | |
if l:attr != "" | |
exec "hi " . a:group . " gui=" . l:attr . " cterm=" . l:attr | |
endif | |
if l:guisp != "" | |
exec "hi " . a:group . " guisp=#" . l:guisp | |
endif | |
endfunction | |
fun <sid>hi(group, guifg, guibg, ctermfg, ctermbg, attr, guisp) | |
call g:Base16hi(a:group, a:guifg, a:guibg, a:ctermfg, a:ctermbg, a:attr, a:guisp) | |
endfun | |
" Vim editor colors | |
call <sid>hi("Normal", s:gui05, s:gui00, s:cterm05, s:cterm00, "", "") | |
call <sid>hi("Bold", "", "", "", "", "bold", "") | |
call <sid>hi("Debug", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("Directory", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("Error", s:gui00, s:gui08, s:cterm00, s:cterm08, "", "") | |
call <sid>hi("ErrorMsg", s:gui08, s:gui00, s:cterm08, s:cterm00, "", "") | |
call <sid>hi("Exception", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("FoldColumn", s:gui0C, s:gui01, s:cterm0C, s:cterm01, "", "") | |
call <sid>hi("Folded", s:gui03, s:gui01, s:cterm03, s:cterm01, "", "") | |
call <sid>hi("IncSearch", s:gui01, s:gui09, s:cterm01, s:cterm09, "none", "") | |
call <sid>hi("Italic", "", "", "", "", "none", "") | |
call <sid>hi("Macro", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("MatchParen", "", s:gui03, "", s:cterm03, "", "") | |
call <sid>hi("ModeMsg", s:gui0B, "", s:cterm0B, "", "", "") | |
call <sid>hi("MoreMsg", s:gui0B, "", s:cterm0B, "", "", "") | |
call <sid>hi("Question", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("Search", s:gui01, s:gui0A, s:cterm01, s:cterm0A, "", "") | |
call <sid>hi("Substitute", s:gui01, s:gui0A, s:cterm01, s:cterm0A, "none", "") | |
call <sid>hi("SpecialKey", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("TooLong", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("Underlined", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("Visual", "", s:gui02, "", s:cterm02, "", "") | |
call <sid>hi("VisualNOS", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("WarningMsg", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("WildMenu", s:gui08, s:gui0A, s:cterm08, "", "", "") | |
call <sid>hi("Title", s:gui0D, "", s:cterm0D, "", "none", "") | |
call <sid>hi("Conceal", s:gui0D, s:gui00, s:cterm0D, s:cterm00, "", "") | |
call <sid>hi("Cursor", s:gui00, s:gui05, s:cterm00, s:cterm05, "", "") | |
call <sid>hi("NonText", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("LineNr", s:gui03, s:gui01, s:cterm03, s:cterm01, "", "") | |
call <sid>hi("SignColumn", s:gui03, s:gui01, s:cterm03, s:cterm01, "", "") | |
call <sid>hi("StatusLine", s:gui04, s:gui02, s:cterm04, s:cterm02, "none", "") | |
call <sid>hi("StatusLineNC", s:gui03, s:gui01, s:cterm03, s:cterm01, "none", "") | |
call <sid>hi("VertSplit", s:gui02, s:gui02, s:cterm02, s:cterm02, "none", "") | |
call <sid>hi("ColorColumn", "", s:gui01, "", s:cterm01, "none", "") | |
call <sid>hi("CursorColumn", "", s:gui01, "", s:cterm01, "none", "") | |
call <sid>hi("CursorLine", "", s:gui01, "", s:cterm01, "none", "") | |
call <sid>hi("CursorLineNr", s:gui04, s:gui01, s:cterm04, s:cterm01, "", "") | |
call <sid>hi("QuickFixLine", "", s:gui01, "", s:cterm01, "none", "") | |
call <sid>hi("PMenu", s:gui05, s:gui01, s:cterm05, s:cterm01, "none", "") | |
call <sid>hi("PMenuSel", s:gui01, s:gui05, s:cterm01, s:cterm05, "", "") | |
call <sid>hi("TabLine", s:gui03, s:gui01, s:cterm03, s:cterm01, "none", "") | |
call <sid>hi("TabLineFill", s:gui03, s:gui01, s:cterm03, s:cterm01, "none", "") | |
call <sid>hi("TabLineSel", s:gui0B, s:gui01, s:cterm0B, s:cterm01, "none", "") | |
" Standard syntax highlighting | |
call <sid>hi("Boolean", s:gui09, "", s:cterm09, "", "", "") | |
call <sid>hi("Character", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("Comment", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("Conditional", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("Constant", s:gui09, "", s:cterm09, "", "", "") | |
call <sid>hi("Define", s:gui0E, "", s:cterm0E, "", "none", "") | |
call <sid>hi("Delimiter", s:gui0F, "", s:cterm0F, "", "", "") | |
call <sid>hi("Float", s:gui09, "", s:cterm09, "", "", "") | |
call <sid>hi("Function", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("Identifier", s:gui08, "", s:cterm08, "", "none", "") | |
call <sid>hi("Include", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("Keyword", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("Label", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("Number", s:gui09, "", s:cterm09, "", "", "") | |
call <sid>hi("Operator", s:gui05, "", s:cterm05, "", "none", "") | |
call <sid>hi("PreProc", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("Repeat", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("Special", s:gui0C, "", s:cterm0C, "", "", "") | |
call <sid>hi("SpecialChar", s:gui0F, "", s:cterm0F, "", "", "") | |
call <sid>hi("Statement", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("StorageClass", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("String", s:gui0B, "", s:cterm0B, "", "", "") | |
call <sid>hi("Structure", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("Tag", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("Todo", s:gui0A, s:gui01, s:cterm0A, s:cterm01, "", "") | |
call <sid>hi("Type", s:gui0A, "", s:cterm0A, "", "none", "") | |
call <sid>hi("Typedef", s:gui0A, "", s:cterm0A, "", "", "") | |
" C highlighting | |
call <sid>hi("cOperator", s:gui0C, "", s:cterm0C, "", "", "") | |
call <sid>hi("cPreCondit", s:gui0E, "", s:cterm0E, "", "", "") | |
" C# highlighting | |
call <sid>hi("csClass", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("csAttribute", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("csModifier", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("csType", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("csUnspecifiedStatement", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("csContextualStatement", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("csNewDecleration", s:gui08, "", s:cterm08, "", "", "") | |
" CSS highlighting | |
call <sid>hi("cssBraces", s:gui05, "", s:cterm05, "", "", "") | |
call <sid>hi("cssClassName", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("cssColor", s:gui0C, "", s:cterm0C, "", "", "") | |
" Diff highlighting | |
call <sid>hi("DiffAdd", s:gui0B, s:gui01, s:cterm0B, s:cterm01, "", "") | |
call <sid>hi("DiffChange", s:gui03, s:gui01, s:cterm03, s:cterm01, "", "") | |
call <sid>hi("DiffDelete", s:gui08, s:gui01, s:cterm08, s:cterm01, "", "") | |
call <sid>hi("DiffText", s:gui0D, s:gui01, s:cterm0D, s:cterm01, "", "") | |
call <sid>hi("DiffAdded", s:gui0B, s:gui00, s:cterm0B, s:cterm00, "", "") | |
call <sid>hi("DiffFile", s:gui08, s:gui00, s:cterm08, s:cterm00, "", "") | |
call <sid>hi("DiffNewFile", s:gui0B, s:gui00, s:cterm0B, s:cterm00, "", "") | |
call <sid>hi("DiffLine", s:gui0D, s:gui00, s:cterm0D, s:cterm00, "", "") | |
call <sid>hi("DiffRemoved", s:gui08, s:gui00, s:cterm08, s:cterm00, "", "") | |
" Git highlighting | |
call <sid>hi("gitcommitOverflow", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("gitcommitSummary", s:gui0B, "", s:cterm0B, "", "", "") | |
call <sid>hi("gitcommitComment", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("gitcommitUntracked", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("gitcommitDiscarded", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("gitcommitSelected", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("gitcommitHeader", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("gitcommitSelectedType", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("gitcommitUnmergedType", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("gitcommitDiscardedType", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("gitcommitBranch", s:gui09, "", s:cterm09, "", "bold", "") | |
call <sid>hi("gitcommitUntrackedFile", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("gitcommitUnmergedFile", s:gui08, "", s:cterm08, "", "bold", "") | |
call <sid>hi("gitcommitDiscardedFile", s:gui08, "", s:cterm08, "", "bold", "") | |
call <sid>hi("gitcommitSelectedFile", s:gui0B, "", s:cterm0B, "", "bold", "") | |
" GitGutter highlighting | |
call <sid>hi("GitGutterAdd", s:gui0B, s:gui01, s:cterm0B, s:cterm01, "", "") | |
call <sid>hi("GitGutterChange", s:gui0D, s:gui01, s:cterm0D, s:cterm01, "", "") | |
call <sid>hi("GitGutterDelete", s:gui08, s:gui01, s:cterm08, s:cterm01, "", "") | |
call <sid>hi("GitGutterChangeDelete", s:gui0E, s:gui01, s:cterm0E, s:cterm01, "", "") | |
" HTML highlighting | |
call <sid>hi("htmlBold", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("htmlItalic", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("htmlEndTag", s:gui05, "", s:cterm05, "", "", "") | |
call <sid>hi("htmlTag", s:gui05, "", s:cterm05, "", "", "") | |
" JavaScript highlighting | |
call <sid>hi("javaScript", s:gui05, "", s:cterm05, "", "", "") | |
call <sid>hi("javaScriptBraces", s:gui05, "", s:cterm05, "", "", "") | |
call <sid>hi("javaScriptNumber", s:gui09, "", s:cterm09, "", "", "") | |
" pangloss/vim-javascript highlighting | |
call <sid>hi("jsOperator", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("jsStatement", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("jsReturn", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("jsThis", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("jsClassDefinition", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("jsFunction", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("jsFuncName", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("jsFuncCall", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("jsClassFuncName", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("jsClassMethodType", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("jsRegexpString", s:gui0C, "", s:cterm0C, "", "", "") | |
call <sid>hi("jsGlobalObjects", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("jsGlobalNodeObjects", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("jsExceptions", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("jsBuiltins", s:gui0A, "", s:cterm0A, "", "", "") | |
" Mail highlighting | |
call <sid>hi("mailQuoted1", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("mailQuoted2", s:gui0B, "", s:cterm0B, "", "", "") | |
call <sid>hi("mailQuoted3", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("mailQuoted4", s:gui0C, "", s:cterm0C, "", "", "") | |
call <sid>hi("mailQuoted5", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("mailQuoted6", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("mailURL", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("mailEmail", s:gui0D, "", s:cterm0D, "", "", "") | |
" Markdown highlighting | |
call <sid>hi("markdownCode", s:gui0B, "", s:cterm0B, "", "", "") | |
call <sid>hi("markdownError", s:gui05, s:gui00, s:cterm05, s:cterm00, "", "") | |
call <sid>hi("markdownCodeBlock", s:gui0B, "", s:cterm0B, "", "", "") | |
call <sid>hi("markdownHeadingDelimiter", s:gui0D, "", s:cterm0D, "", "", "") | |
" NERDTree highlighting | |
call <sid>hi("NERDTreeDirSlash", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("NERDTreeExecFile", s:gui05, "", s:cterm05, "", "", "") | |
" PHP highlighting | |
call <sid>hi("phpMemberSelector", s:gui05, "", s:cterm05, "", "", "") | |
call <sid>hi("phpComparison", s:gui05, "", s:cterm05, "", "", "") | |
call <sid>hi("phpParent", s:gui05, "", s:cterm05, "", "", "") | |
call <sid>hi("phpMethodsVar", s:gui0C, "", s:cterm0C, "", "", "") | |
" Python highlighting | |
call <sid>hi("pythonOperator", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("pythonRepeat", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("pythonInclude", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("pythonStatement", s:gui0E, "", s:cterm0E, "", "", "") | |
" Ruby highlighting | |
call <sid>hi("rubyAttribute", s:gui0D, "", s:cterm0D, "", "", "") | |
call <sid>hi("rubyConstant", s:gui0A, "", s:cterm0A, "", "", "") | |
call <sid>hi("rubyInterpolationDelimiter", s:gui0F, "", s:cterm0F, "", "", "") | |
call <sid>hi("rubyRegexp", s:gui0C, "", s:cterm0C, "", "", "") | |
call <sid>hi("rubySymbol", s:gui0B, "", s:cterm0B, "", "", "") | |
call <sid>hi("rubyStringDelimiter", s:gui0B, "", s:cterm0B, "", "", "") | |
" SASS highlighting | |
call <sid>hi("sassidChar", s:gui08, "", s:cterm08, "", "", "") | |
call <sid>hi("sassClassChar", s:gui09, "", s:cterm09, "", "", "") | |
call <sid>hi("sassInclude", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("sassMixing", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("sassMixinName", s:gui0D, "", s:cterm0D, "", "", "") | |
" Signify highlighting | |
call <sid>hi("SignifySignAdd", s:gui0B, s:gui01, s:cterm0B, s:cterm01, "", "") | |
call <sid>hi("SignifySignChange", s:gui0D, s:gui01, s:cterm0D, s:cterm01, "", "") | |
call <sid>hi("SignifySignDelete", s:gui08, s:gui01, s:cterm08, s:cterm01, "", "") | |
" Spelling highlighting | |
call <sid>hi("SpellBad", "", "", "", "", "undercurl", s:gui08) | |
call <sid>hi("SpellLocal", "", "", "", "", "undercurl", s:gui0C) | |
call <sid>hi("SpellCap", "", "", "", "", "undercurl", s:gui0D) | |
call <sid>hi("SpellRare", "", "", "", "", "undercurl", s:gui0E) | |
" Startify highlighting | |
call <sid>hi("StartifyBracket", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("StartifyFile", s:gui07, "", s:cterm07, "", "", "") | |
call <sid>hi("StartifyFooter", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("StartifyHeader", s:gui0B, "", s:cterm0B, "", "", "") | |
call <sid>hi("StartifyNumber", s:gui09, "", s:cterm09, "", "", "") | |
call <sid>hi("StartifyPath", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("StartifySection", s:gui0E, "", s:cterm0E, "", "", "") | |
call <sid>hi("StartifySelect", s:gui0C, "", s:cterm0C, "", "", "") | |
call <sid>hi("StartifySlash", s:gui03, "", s:cterm03, "", "", "") | |
call <sid>hi("StartifySpecial", s:gui03, "", s:cterm03, "", "", "") | |
" Java highlighting | |
call <sid>hi("javaOperator", s:gui0D, "", s:cterm0D, "", "", "") | |
" Remove functions | |
delf <sid>hi | |
" Remove color variables | |
unlet s:gui00 s:gui01 s:gui02 s:gui03 s:gui04 s:gui05 s:gui06 s:gui07 s:gui08 s:gui09 s:gui0A s:gui0B s:gui0C s:gui0D s:gui0E s:gui0F | |
unlet s:cterm00 s:cterm01 s:cterm02 s:cterm03 s:cterm04 s:cterm05 s:cterm06 s:cterm07 s:cterm08 s:cterm09 s:cterm0A s:cterm0B s:cterm0C s:cterm0D s:cterm0E s:cterm0F |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/fish | |
# fish_default_key_bindings to disable | |
#fish_vi_key_bindings | |
#set TERM xterm-256color | |
function bind_bang | |
switch (commandline -t)[-1] | |
case "!" | |
commandline -t $history[1]; commandline -f repaint | |
case "*" | |
commandline -i ! | |
end | |
end | |
function bind_dollar | |
switch (commandline -t)[-1] | |
case "!" | |
commandline -t "" | |
commandline -f history-token-search-backward | |
case "*" | |
commandline -i '$' | |
end | |
end | |
function rofi-run-history | |
set command (history | rofi -dmenu) | |
echo $command | |
eval $command | |
commandline -f repaint | |
end | |
function fish_user_key_bindings | |
bind -M insert \cf forward-char | |
bind -M insert \cp up-or-search | |
bind -M insert \cn down-or-search | |
bind -M insert \cs ls | |
bind -M insert ! bind_bang | |
bind -M insert '$' bind_dollar | |
end | |
if test -f /usr/share/autojump/autojump.fish | |
source /usr/share/autojump/autojump.fish | |
# redefine so we use pushd instead of cd | |
function j | |
switch "$argv" | |
case '-*' '--*' | |
autojump $argv | |
case '*' | |
set -l output (autojump $argv) | |
if [ $output = "." ] | |
pushd $argv | |
else | |
if test -d "$output" | |
set_color red | |
echo $output | |
set_color normal | |
pushd $output | |
else | |
__aj_err "autojump: directory '"$argv"' not found" | |
__aj_err "\n$output\n" | |
__aj_err "Try `autojump --help` for more information." | |
end | |
end | |
end | |
end | |
end | |
set prompt_selection "rainbow" | |
set prompt_pwd_type "smart" | |
set -gx EDITOR /bin/nano | |
set -gx VISUAL $HOME/bin/eb.fish | |
#set -gx PATH $HOME/bin $PATH | |
set -gx PATH $HOME/.local/bin $PATH | |
set -gx XDG_CONFIG_HOME $HOME/.config | |
set -gx XDG_CACHE_HOME $HOME/.cache | |
set -gx XDG_DATA_HOME $HOME/.local/share |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment