parent
39fbd61b5d
commit
4a02a80e76
@ -1,6 +0,0 @@
|
|||||||
alias la='ls -lahF'
|
|
||||||
alias xclip='xclip -selection clipboard'
|
|
||||||
alias xpaste='xclip -o -selection clipboard'
|
|
||||||
alias nano='vim'
|
|
||||||
alias more='less'
|
|
||||||
alias ..='cd ..'
|
|
@ -1,118 +0,0 @@
|
|||||||
# ~/.bashrc: executed by bash(1) for non-login shells.
|
|
||||||
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
|
|
||||||
# for examples
|
|
||||||
|
|
||||||
# If not running interactively, don't do anything
|
|
||||||
case $- in
|
|
||||||
*i*) ;;
|
|
||||||
*) return;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
# don't put duplicate lines or lines starting with space in the history.
|
|
||||||
# See bash(1) for more options
|
|
||||||
HISTCONTROL=ignoreboth
|
|
||||||
|
|
||||||
# append to the history file, don't overwrite it
|
|
||||||
shopt -s histappend
|
|
||||||
|
|
||||||
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
|
|
||||||
HISTSIZE=500
|
|
||||||
HISTFILESIZE=1000
|
|
||||||
|
|
||||||
# check the window size after each command and, if necessary,
|
|
||||||
# update the values of LINES and COLUMNS.
|
|
||||||
shopt -s checkwinsize
|
|
||||||
|
|
||||||
# If set, the pattern "**" used in a pathname expansion context will
|
|
||||||
# match all files and zero or more directories and subdirectories.
|
|
||||||
#shopt -s globstar
|
|
||||||
|
|
||||||
# make less more friendly for non-text input files, see lesspipe(1)
|
|
||||||
[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
|
|
||||||
|
|
||||||
# set variable identifying the chroot you work in (used in the prompt below)
|
|
||||||
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
|
|
||||||
debian_chroot=$(cat /etc/debian_chroot)
|
|
||||||
fi
|
|
||||||
|
|
||||||
# set a fancy prompt (non-color, unless we know we "want" color)
|
|
||||||
case "$TERM" in
|
|
||||||
xterm-color|*-256color) color_prompt=yes;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
# uncomment for a colored prompt, if the terminal has the capability; turned
|
|
||||||
# off by default to not distract the user: the focus in a terminal window
|
|
||||||
# should be on the output of commands, not on the prompt
|
|
||||||
#force_color_prompt=yes
|
|
||||||
|
|
||||||
if [ -n "$force_color_prompt" ]; then
|
|
||||||
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
|
|
||||||
# We have color support; assume it's compliant with Ecma-48
|
|
||||||
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
|
|
||||||
# a case would tend to support setf rather than setaf.)
|
|
||||||
color_prompt=yes
|
|
||||||
else
|
|
||||||
color_prompt=
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$color_prompt" = yes ]; then
|
|
||||||
PS1='\n${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\n\$ '
|
|
||||||
else
|
|
||||||
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
|
|
||||||
fi
|
|
||||||
unset color_prompt force_color_prompt
|
|
||||||
|
|
||||||
# If this is an xterm set the title to user@host:dir
|
|
||||||
case "$TERM" in
|
|
||||||
xterm*|rxvt*)
|
|
||||||
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
# enable color support of ls and also add handy aliases
|
|
||||||
if [ -x /usr/bin/dircolors ]; then
|
|
||||||
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
|
|
||||||
alias ls='ls --color=auto'
|
|
||||||
#alias dir='dir --color=auto'
|
|
||||||
#alias vdir='vdir --color=auto'
|
|
||||||
|
|
||||||
alias grep='grep --color=auto'
|
|
||||||
alias fgrep='fgrep --color=auto'
|
|
||||||
alias egrep='egrep --color=auto'
|
|
||||||
fi
|
|
||||||
|
|
||||||
# colored GCC warnings and errors
|
|
||||||
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
|
|
||||||
|
|
||||||
# Add an "alert" alias for long running commands. Use like so:
|
|
||||||
# sleep 10; alert
|
|
||||||
alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'
|
|
||||||
|
|
||||||
# Alias definitions.
|
|
||||||
# You may want to put all your additions into a separate file like
|
|
||||||
# ~/.bash_aliases, instead of adding them here directly.
|
|
||||||
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
|
|
||||||
|
|
||||||
if [ -f ~/.bash_aliases ]; then
|
|
||||||
. ~/.bash_aliases
|
|
||||||
fi
|
|
||||||
|
|
||||||
# enable programmable completion features (you don't need to enable
|
|
||||||
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
|
|
||||||
# sources /etc/bash.bashrc).
|
|
||||||
if ! shopt -oq posix; then
|
|
||||||
if [ -f /usr/share/bash-completion/bash_completion ]; then
|
|
||||||
. /usr/share/bash-completion/bash_completion
|
|
||||||
elif [ -f /etc/bash_completion ]; then
|
|
||||||
. /etc/bash_completion
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -f ~/.todo ]; then
|
|
||||||
echo " === TODO: === "
|
|
||||||
cat ~/.todo
|
|
||||||
echo -e "=======================\n"
|
|
||||||
fi
|
|
@ -0,0 +1,228 @@
|
|||||||
|
|
||||||
|
let mapleader=" "
|
||||||
|
|
||||||
|
set mouse=
|
||||||
|
syntax on
|
||||||
|
|
||||||
|
set noerrorbells
|
||||||
|
set number
|
||||||
|
set relativenumber
|
||||||
|
set incsearch
|
||||||
|
set ignorecase
|
||||||
|
set ruler
|
||||||
|
set noswapfile
|
||||||
|
set splitright
|
||||||
|
set splitbelow
|
||||||
|
set tabstop=4 softtabstop=4
|
||||||
|
set shiftwidth=4
|
||||||
|
set expandtab
|
||||||
|
set smartindent
|
||||||
|
set noswapfile
|
||||||
|
set nobackup
|
||||||
|
set undodir=~/.vim/undodir
|
||||||
|
set undofile
|
||||||
|
set nohlsearch
|
||||||
|
|
||||||
|
|
||||||
|
call plug#begin('~/.config/nvim/autoload/plugged')
|
||||||
|
Plug 'scrooloose/nerdcommenter'
|
||||||
|
Plug 'preservim/nerdtree'
|
||||||
|
|
||||||
|
Plug 'morhetz/gruvbox' " themes
|
||||||
|
Plug 'sonph/onehalf'
|
||||||
|
|
||||||
|
" Plug 'ThePrimeagen/vim-be-good', {'do': './install.sh'} " vim training game
|
||||||
|
|
||||||
|
" Fuzzy file search
|
||||||
|
Plug 'junegunn/fzf', { 'do': { -> fzf#install() } } " fuzzy file finder
|
||||||
|
Plug 'junegunn/fzf.vim'
|
||||||
|
Plug 'airblade/vim-rooter' " addon for fzf, for git projects
|
||||||
|
|
||||||
|
" Plug 'ycm-core/YouCompleteMe' " YEET!
|
||||||
|
Plug 'neoclide/coc.nvim', {'branch': 'release'}
|
||||||
|
|
||||||
|
" Python syntax highlight
|
||||||
|
Plug 'numirias/semshi', {'do': ':UpdateRemotePlugins'}
|
||||||
|
|
||||||
|
" Coc Snippets
|
||||||
|
Plug 'sirver/ultisnips'
|
||||||
|
Plug 'honza/vim-snippets'
|
||||||
|
|
||||||
|
" Show git modifications to file
|
||||||
|
Plug 'vim-scripts/vim-gitgutter'
|
||||||
|
|
||||||
|
Plug 'jremmen/vim-ripgrep' " Rg uses word under cursor
|
||||||
|
|
||||||
|
" run current file
|
||||||
|
Plug 'sbdchd/vim-run'
|
||||||
|
|
||||||
|
" HTTP
|
||||||
|
Plug 'nicwest/vim-http'
|
||||||
|
|
||||||
|
call plug#end()
|
||||||
|
|
||||||
|
" disable spacebar (don't move forward)
|
||||||
|
nnoremap <SPACE> <Nop>
|
||||||
|
|
||||||
|
" quickly move through panes
|
||||||
|
nnoremap <C-J> <C-W><C-J>
|
||||||
|
nnoremap <C-K> <C-W><C-K>
|
||||||
|
nnoremap <C-L> <C-W><C-L>
|
||||||
|
nnoremap <C-H> <C-W><C-H>
|
||||||
|
|
||||||
|
" resize panes
|
||||||
|
nnoremap <silent> <leader>+ :vertical resize +5<CR>
|
||||||
|
nnoremap <silent> <leader>- :vertical resize -5<CR>
|
||||||
|
|
||||||
|
nnoremap <silent> <leader>ff :GFiles<CR>
|
||||||
|
|
||||||
|
vnoremap <leader>p "_dP
|
||||||
|
|
||||||
|
" noremap <leader> gf :GitFiles
|
||||||
|
|
||||||
|
colorscheme gruvbox
|
||||||
|
"colorscheme onehalfdark let g:airline_theme='onehalfdark'
|
||||||
|
set background=dark
|
||||||
|
|
||||||
|
:set inccommand=nosplit " highlight substitude
|
||||||
|
|
||||||
|
|
||||||
|
" run current file plugin
|
||||||
|
let g:run_cmd_python = ['python3']
|
||||||
|
let g:run_split = 'right'
|
||||||
|
|
||||||
|
|
||||||
|
"fun! SetupYCM()
|
||||||
|
"nnoremap <buffer> <silent> <leader>gd :YcmCompleter GoTo<CR>
|
||||||
|
"nnoremap <buffer> <silent> <leader>gr :YcmCompleter GoToReferences<CR>
|
||||||
|
"nnoremap <buffer> <silent> <leader>rr :YcmCompleter RefactorRename<CR>
|
||||||
|
"let g:UltiSnipsExpandTrigger="<c-space>"
|
||||||
|
"endfun
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
" CoC
|
||||||
|
|
||||||
|
function! s:check_back_space() abort
|
||||||
|
let col = col('.') - 1
|
||||||
|
return !col || getline('.')[col - 1] =~# '\s'
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
fun! SetupCoC()
|
||||||
|
inoremap <buffer> <silent><expr> <TAB>
|
||||||
|
\ pumvisible() ? "\<C-n>" :
|
||||||
|
\ <SID>check_back_space() ? "\<TAB>" :
|
||||||
|
\ coc#refresh()
|
||||||
|
inoremap <buffer> <expr><S-TAB> pumvisible() ? "\<C-p>" : "\<C-h>"
|
||||||
|
inoremap <buffer> <silent><expr> <C-space> coc#refresh()
|
||||||
|
|
||||||
|
nmap <buffer> <leader>gd <Plug>(coc-definition)
|
||||||
|
nmap <buffer> <leader>gr <Plug>(coc-references)
|
||||||
|
nmap <buffer> <leader>gy <Plug>(coc-type-definition)
|
||||||
|
nmap <buffer> <leader>gi <Plug>(coc-implementation)
|
||||||
|
nmap <buffer> <leader>rn <Plug>(coc-rename)
|
||||||
|
endfun
|
||||||
|
|
||||||
|
let g:coc_global_extensions = [
|
||||||
|
\ 'coc-snippets',
|
||||||
|
\ 'coc-pairs',
|
||||||
|
\ 'coc-prettier',
|
||||||
|
\ 'coc-json',
|
||||||
|
\ 'coc-python',
|
||||||
|
\ 'coc-html',
|
||||||
|
\ 'coc-css',
|
||||||
|
\ 'coc-xml',
|
||||||
|
\ 'coc-yaml',
|
||||||
|
\ ]
|
||||||
|
|
||||||
|
autocmd BufNewFile,BufRead *.pde set syntax=java
|
||||||
|
autocmd BufNewFile,BufRead *.pde set filetype=java
|
||||||
|
autocmd BufNewFile,BufRead *.ino set syntax=arduino
|
||||||
|
autocmd BufNewFile,BufRead *.ino set filetype=arduino
|
||||||
|
" autocmd FileType java,typescript,go :call SetupYCM()
|
||||||
|
" autocmd FileType cpp,h,c :call SetupCoC()
|
||||||
|
|
||||||
|
" run python script
|
||||||
|
" autocmd BufNewFile,BufRead *.py nnoremap <C-S-R> :vs <CR> :term python % <CR>
|
||||||
|
|
||||||
|
nnoremap <leader>rr :Run <CR>
|
||||||
|
|
||||||
|
call SetupCoC()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
" CoC snippet tab completion
|
||||||
|
inoremap <silent><expr> <TAB>
|
||||||
|
\ pumvisible() ? coc#_select_confirm() :
|
||||||
|
\ coc#expandableOrJumpable() ? "\<C-r>=coc#rpc#request('doKeymap', ['snippets-expand-jump',''])\<CR>" :
|
||||||
|
\ <SID>check_back_space() ? "\<TAB>" :
|
||||||
|
\ coc#refresh()
|
||||||
|
|
||||||
|
function! s:check_back_space() abort
|
||||||
|
let col = col('.') - 1
|
||||||
|
return !col || getline('.')[col - 1] =~# '\s'
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
let g:coc_snippet_next = '<tab>'
|
||||||
|
"let g:UltiSnipsExpandTrigger="<tab>"
|
||||||
|
"let g:UltiSnipsJumpForwardTrigger="<tab>>"
|
||||||
|
"let g:UltiSnipsJumpBackwardTrigger="<s-tab>"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
" Shebang line
|
||||||
|
function! Hashbang(portable, permission, RemExt)
|
||||||
|
let shells = {
|
||||||
|
\ 'awk': "awk",
|
||||||
|
\ 'sh': "bash",
|
||||||
|
\ 'hs': "runhaskell",
|
||||||
|
\ 'jl': "julia",
|
||||||
|
\ 'lua': "lua",
|
||||||
|
\ 'mak': "make",
|
||||||
|
\ 'js': "node",
|
||||||
|
\ 'm': "octave",
|
||||||
|
\ 'pl': "perl",
|
||||||
|
\ 'php': "php",
|
||||||
|
\ 'py': "python",
|
||||||
|
\ 'r': "Rscript",
|
||||||
|
\ 'rb': "ruby",
|
||||||
|
\ 'scala': "scala",
|
||||||
|
\ 'tcl': "tclsh",
|
||||||
|
\ 'tk': "wish"
|
||||||
|
\ }
|
||||||
|
|
||||||
|
let extension = expand("%:e")
|
||||||
|
|
||||||
|
if has_key(shells,extension)
|
||||||
|
let fileshell = shells[extension]
|
||||||
|
|
||||||
|
if a:portable
|
||||||
|
let line = "#! /usr/bin/env " . fileshell
|
||||||
|
else
|
||||||
|
let line = "#! " . system("which " . fileshell)
|
||||||
|
endif
|
||||||
|
|
||||||
|
0put = line
|
||||||
|
|
||||||
|
if a:permission
|
||||||
|
:autocmd BufWritePost * :autocmd VimLeave * :!chmod u+x %
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
if a:RemExt
|
||||||
|
:autocmd BufWritePost * :autocmd VimLeave * :!mv % "%:p:r"
|
||||||
|
endif
|
||||||
|
|
||||||
|
endif
|
||||||
|
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
:autocmd BufNewFile *.* :call Hashbang(1,1,0)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
" HTTP
|
||||||
|
let g:vim_http_split_vertically = 1
|
@ -0,0 +1,37 @@
|
|||||||
|
# color
|
||||||
|
alias ls='ls --color=auto --group-directories-first'
|
||||||
|
alias grep='grep --color=auto'
|
||||||
|
alias ip='ip -color=auto'
|
||||||
|
|
||||||
|
#alias la='ls -lahF'
|
||||||
|
alias xclip='xclip -selection clipboard'
|
||||||
|
alias xpaste='xclip -o -selection clipboard'
|
||||||
|
alias more='less'
|
||||||
|
alias ..='cd ..'
|
||||||
|
alias cp='cp -iv'
|
||||||
|
alias mv='mv -iv'
|
||||||
|
|
||||||
|
#alias ccat="highlight --out-format=ansi"
|
||||||
|
alias p="sudo pacman"
|
||||||
|
alias sc="sudo systemctl"
|
||||||
|
alias psg="ps aux | grep"
|
||||||
|
alias nv='nvim'
|
||||||
|
#alias suod='sudo'
|
||||||
|
|
||||||
|
# git
|
||||||
|
alias g='git'
|
||||||
|
alias gst='git status'
|
||||||
|
alias gdiff='git diff'
|
||||||
|
alias gl='git pull'
|
||||||
|
alias gp='git push'
|
||||||
|
alias gc='git commit -v'
|
||||||
|
alias gca='git commit -v -a'
|
||||||
|
alias gcm='git commit -m'
|
||||||
|
alias gcam='git commit -a -m'
|
||||||
|
alias gco='git checkout'
|
||||||
|
alias gb='git branch'
|
||||||
|
alias ga='git add'
|
||||||
|
|
||||||
|
|
||||||
|
alias batman="MANPAGER=\"sh -c 'col -bx | bat -l man -p'\" man"
|
||||||
|
alias la='exa -laag --group-directories-first'
|
@ -1,9 +1,43 @@
|
|||||||
# Improve colors
|
# Send prefix
|
||||||
set -g default-terminal 'screen-256color'
|
set-option -g prefix C-a
|
||||||
|
unbind-key C-a
|
||||||
|
bind-key C-a send-prefix
|
||||||
|
|
||||||
|
# Use Alt-arrow keys to switch panes
|
||||||
|
bind -n M-h select-pane -L
|
||||||
|
bind -n M-l select-pane -R
|
||||||
|
bind -n M-k select-pane -U
|
||||||
|
bind -n M-j select-pane -D
|
||||||
|
|
||||||
|
# prefix + j/k to switch windows
|
||||||
|
bind-key j previous-window
|
||||||
|
bind-key k next-window
|
||||||
|
|
||||||
|
# Mouse mode
|
||||||
|
setw -g mouse off
|
||||||
|
|
||||||
|
# set vim-like keybidings in buffer mode
|
||||||
|
setw -g mode-keys vi
|
||||||
|
|
||||||
|
# fix escape key delay in vim
|
||||||
|
set -s escape-time 0
|
||||||
|
|
||||||
# Set scrollback buffer to 10000
|
|
||||||
set -g history-limit 10000
|
set -g history-limit 10000
|
||||||
|
set -g default-terminal screen-256color
|
||||||
|
set-option -g default-shell /usr/bin/zsh
|
||||||
|
|
||||||
|
set-option -sa terminal-overrides ',xterm-256color:RGB'
|
||||||
|
|
||||||
|
# Set easier window split keys
|
||||||
|
bind-key h split-window -v
|
||||||
|
bind-key v split-window -h
|
||||||
|
|
||||||
|
# Easy config reload
|
||||||
|
bind-key r source-file ~/.tmux.conf \; display-message "~/.tmux.conf reloaded."
|
||||||
|
|
||||||
|
# yank to clipboard
|
||||||
|
bind -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'xclip -in -selection clipboard'
|
||||||
|
|
||||||
# Customize the status line
|
# Start window and pane indexes from 1 and not 0
|
||||||
set -g status-fg green
|
set -g base-index 1
|
||||||
set -g status-bg black
|
setw -g pane-base-index 1
|
||||||
|
@ -1,100 +0,0 @@
|
|||||||
|
|
||||||
" An example for a vimrc file.
|
|
||||||
"
|
|
||||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
|
||||||
" Last change: 2017 Sep 20
|
|
||||||
"
|
|
||||||
" To use it, copy it to
|
|
||||||
" for Unix and OS/2: ~/.vimrc
|
|
||||||
" for Amiga: s:.vimrc
|
|
||||||
" for MS-DOS and Win32: $VIM\_vimrc
|
|
||||||
" for OpenVMS: sys$login:.vimrc
|
|
||||||
|
|
||||||
" When started as "evim", evim.vim will already have done these settings.
|
|
||||||
if v:progname =~? "evim"
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Get the defaults that most users want.
|
|
||||||
source $VIMRUNTIME/defaults.vim
|
|
||||||
|
|
||||||
if has("vms")
|
|
||||||
set nobackup " do not keep a backup file, use versions instead
|
|
||||||
else
|
|
||||||
set backup " keep a backup file (restore to previous version)
|
|
||||||
if has('persistent_undo')
|
|
||||||
set undofile " keep an undo file (undo changes after closing)
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Only do this part when compiled with support for autocommands.
|
|
||||||
if has("autocmd")
|
|
||||||
|
|
||||||
" Put these in an autocmd group, so that we can delete them easily.
|
|
||||||
augroup vimrcEx
|
|
||||||
au!
|
|
||||||
|
|
||||||
" For all text files set 'textwidth' to 78 characters.
|
|
||||||
autocmd FileType text setlocal textwidth=78
|
|
||||||
|
|
||||||
augroup END
|
|
||||||
|
|
||||||
else
|
|
||||||
|
|
||||||
set autoindent " always set autoindenting on
|
|
||||||
|
|
||||||
endif " has("autocmd")
|
|
||||||
|
|
||||||
" Add optional packages.
|
|
||||||
"
|
|
||||||
" The matchit plugin makes the % command work better, but it is not backwards
|
|
||||||
" compatible.
|
|
||||||
" The ! means the package won't be loaded right away but when plugins are
|
|
||||||
" loaded during initialization.
|
|
||||||
if has('syntax') && has('eval')
|
|
||||||
packadd! matchit
|
|
||||||
endif
|
|
||||||
|
|
||||||
call plug#begin()
|
|
||||||
Plug 'scrooloose/nerdcommenter'
|
|
||||||
"Plug 'preservim/nerdtree'
|
|
||||||
call plug#end()
|
|
||||||
|
|
||||||
let mapleader = ","
|
|
||||||
|
|
||||||
" My custom commands
|
|
||||||
syntax on
|
|
||||||
set number
|
|
||||||
set relativenumber
|
|
||||||
set incsearch
|
|
||||||
set ignorecase
|
|
||||||
set ruler
|
|
||||||
set noswapfile
|
|
||||||
|
|
||||||
nnoremap <C-J> <C-W><C-J>
|
|
||||||
nnoremap <C-K> <C-W><C-K>
|
|
||||||
nnoremap <C-L> <C-W><C-L>
|
|
||||||
nnoremap <C-H> <C-W><C-H>
|
|
||||||
|
|
||||||
|
|
||||||
autocmd StdinReadPre * let s:std_in=1
|
|
||||||
"autocmd VimEnter * if argc() == 1 && isdirectory(argv()[0]) && !exists("s:std_in") | exe 'NERDTree' argv()[0] | wincmd p | ene | exe 'cd '.argv()[0] | endif
|
|
||||||
"autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif
|
|
||||||
|
|
||||||
|
|
||||||
autocmd Filetype c setlocal tabstop=4
|
|
||||||
set shiftwidth=0
|
|
||||||
|
|
||||||
|
|
||||||
" A nerdtree like setup with netrw.
|
|
||||||
let g:netrw_banner = 0
|
|
||||||
let g:netrw_liststyle = 3
|
|
||||||
let g:netrw_browse_split = 4
|
|
||||||
let g:netrw_altv = 1
|
|
||||||
let g:netrw_winsize = 20
|
|
||||||
augroup ProjectDrawer
|
|
||||||
autocmd!
|
|
||||||
autocmd VimEnter * :Vexplore
|
|
||||||
augroup END
|
|
||||||
|
|
||||||
|
|
@ -1,14 +1,123 @@
|
|||||||
# Lines configured by zsh-newuser-install
|
# If you come from bash you might have to change your $PATH.
|
||||||
HISTFILE=~/.zsh_history
|
# export PATH=$HOME/bin:/usr/local/bin:$PATH
|
||||||
HISTSIZE=1000
|
|
||||||
SAVEHIST=250
|
# Path to your oh-my-zsh installation.
|
||||||
setopt appendhistory nomatch
|
export ZSH="/home/david/.oh-my-zsh"
|
||||||
unsetopt beep
|
|
||||||
bindkey -e
|
# Set name of the theme to load --- if set to "random", it will
|
||||||
# End of lines configured by zsh-newuser-install
|
# load a random theme each time oh-my-zsh is loaded, in which case,
|
||||||
# The following lines were added by compinstall
|
# to know which specific one was loaded, run: echo $RANDOM_THEME
|
||||||
zstyle :compinstall filename '/home/david/.zshrc'
|
# See https://github.com/ohmyzsh/ohmyzsh/wiki/Themes
|
||||||
|
ZSH_THEME="intheloop"
|
||||||
autoload -Uz compinit
|
#gentoo - jako bash
|
||||||
compinit
|
#essembeh - jako bash
|
||||||
# End of lines added by compinstall
|
#dpoggi - jako bash, ale barevnejsi
|
||||||
|
#kennethreitz - pwd na prave strane
|
||||||
|
#bira - $ na nove radce pod pwd
|
||||||
|
#rkj - old tech style
|
||||||
|
#intheloop - $ na nove radce, mezera mezi prikazy
|
||||||
|
|
||||||
|
# Set list of themes to pick from when loading at random
|
||||||
|
# Setting this variable when ZSH_THEME=random will cause zsh to load
|
||||||
|
# a theme from this variable instead of looking in $ZSH/themes/
|
||||||
|
# If set to an empty array, this variable will have no effect.
|
||||||
|
# ZSH_THEME_RANDOM_CANDIDATES=( "robbyrussell" "agnoster" )
|
||||||
|
|
||||||
|
# Uncomment the following line to use case-sensitive completion.
|
||||||
|
# CASE_SENSITIVE="true"
|
||||||
|
|
||||||
|
# Uncomment the following line to use hyphen-insensitive completion.
|
||||||
|
# Case-sensitive completion must be off. _ and - will be interchangeable.
|
||||||
|
# HYPHEN_INSENSITIVE="true"
|
||||||
|
|
||||||
|
# Uncomment the following line to disable bi-weekly auto-update checks.
|
||||||
|
# DISABLE_AUTO_UPDATE="true"
|
||||||
|
|
||||||
|
# Uncomment the following line to automatically update without prompting.
|
||||||
|
# DISABLE_UPDATE_PROMPT="true"
|
||||||
|
|
||||||
|
# Uncomment the following line to change how often to auto-update (in days).
|
||||||
|
# export UPDATE_ZSH_DAYS=13
|
||||||
|
|
||||||
|
# Uncomment the following line if pasting URLs and other text is messed up.
|
||||||
|
# DISABLE_MAGIC_FUNCTIONS=true
|
||||||
|
|
||||||
|
# Uncomment the following line to disable colors in ls.
|
||||||
|
# DISABLE_LS_COLORS="true"
|
||||||
|
|
||||||
|
# Uncomment the following line to disable auto-setting terminal title.
|
||||||
|
# DISABLE_AUTO_TITLE="true"
|
||||||
|
|
||||||
|
# Uncomment the following line to enable command auto-correction.
|
||||||
|
# ENABLE_CORRECTION="true"
|
||||||
|
|
||||||
|
# Uncomment the following line to display red dots whilst waiting for completion.
|
||||||
|
# COMPLETION_WAITING_DOTS="true"
|
||||||
|
|
||||||
|
# Uncomment the following line if you want to disable marking untracked files
|
||||||
|
# under VCS as dirty. This makes repository status check for large repositories
|
||||||
|
# much, much faster.
|
||||||
|
# DISABLE_UNTRACKED_FILES_DIRTY="true"
|
||||||
|
|
||||||
|
# Uncomment the following line if you want to change the command execution time
|
||||||
|
# stamp shown in the history command output.
|
||||||
|
# You can set one of the optional three formats:
|
||||||
|
# "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd"
|
||||||
|
# or set a custom format using the strftime function format specifications,
|
||||||
|
# see 'man strftime' for details.
|
||||||
|
# HIST_STAMPS="mm/dd/yyyy"
|
||||||
|
|
||||||
|
# Would you like to use another custom folder than $ZSH/custom?
|
||||||
|
# ZSH_CUSTOM=/path/to/new-custom-folder
|
||||||
|
|
||||||
|
# Which plugins would you like to load?
|
||||||
|
# Standard plugins can be found in $ZSH/plugins/
|
||||||
|
# Custom plugins may be added to $ZSH_CUSTOM/plugins/
|
||||||
|
# Example format: plugins=(rails git textmate ruby lighthouse)
|
||||||
|
# Add wisely, as too many plugins slow down shell startup.
|
||||||
|
plugins=(git zsh-autosuggestions zsh-syntax-highlighting)
|
||||||
|
|
||||||
|
source $ZSH/oh-my-zsh.sh
|
||||||
|
|
||||||
|
# User configuration
|
||||||
|
|
||||||
|
ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=#666666,underline"
|
||||||
|
|
||||||
|
# export MANPATH="/usr/local/man:$MANPATH"
|
||||||
|
|
||||||
|
# You may need to manually set your language environment
|
||||||
|
# export LANG=en_US.UTF-8
|
||||||
|
|
||||||
|
# Preferred editor for local and remote sessions
|
||||||
|
# if [[ -n $SSH_CONNECTION ]]; then
|
||||||
|
# export EDITOR='vim'
|
||||||
|
# else
|
||||||
|
# export EDITOR='mvim'
|
||||||
|
# fi
|
||||||
|
|
||||||
|
# Compilation flags
|
||||||
|
# export ARCHFLAGS="-arch x86_64"
|
||||||
|
|
||||||
|
# Set personal aliases, overriding those provided by oh-my-zsh libs,
|
||||||
|
# plugins, and themes. Aliases can be placed here, though oh-my-zsh
|
||||||
|
# users are encouraged to define aliases within the ZSH_CUSTOM folder.
|
||||||
|
# For a full list of active aliases, run `alias`.
|
||||||
|
#
|
||||||
|
# Example aliases
|
||||||
|
# alias zshconfig="mate ~/.zshrc"
|
||||||
|
# alias ohmyzsh="mate ~/.oh-my-zsh"
|
||||||
|
#
|
||||||
|
|
||||||
|
export EDITOR='nvim'
|
||||||
|
|
||||||
|
if [ -f ~/.config/shell_aliases ]; then
|
||||||
|
source ~/.config/shell_aliases
|
||||||
|
fi
|
||||||
|
|
||||||
|
PATH=$PATH:$HOME/.local/bin
|
||||||
|
|
||||||
|
# setopt GLOBdots # wildcard match files starting with .
|
||||||
|
|
||||||
|
eval $(thefuck --alias)
|
||||||
|
|
||||||
|
bindkey '^ ' autosuggest-accept # accept suggestion with ctrl-space
|
||||||
|
@ -0,0 +1,8 @@
|
|||||||
|
#! /usr/bin/env bash
|
||||||
|
|
||||||
|
cp .zshrc ~/.zshrc
|
||||||
|
cp .tmux.conf ~/.tmux.conf
|
||||||
|
cp .shell_aliases ~/.config/shell_aliases
|
||||||
|
cp .init.nvim ~/.config/nvim/init.vim
|
||||||
|
|
||||||
|
|
Loading…
Reference in new issue