Skip to content

Instantly share code, notes, and snippets.

@adrianvalenz
Last active December 1, 2020 09:04
Show Gist options
  • Save adrianvalenz/1b934ec79baa8a30926f40df1d89cd13 to your computer and use it in GitHub Desktop.
Save adrianvalenz/1b934ec79baa8a30926f40df1d89cd13 to your computer and use it in GitHub Desktop.
so dope...even tmux has the dracula color schemes.
so dope...even tmux has the dracula color schemes.
"set guifont=Dank\ Mono:h12
set macligatures
set guifont=Fira\ Code\ Light:h12
"let g:material_theme_style = 'base16-google'
colorscheme dracula
"let g:material_terminal_italics = 1
"let g:material_theme_style = 'ocean'
"colorscheme material
packadd! dracula
colorscheme dracula
filetype indent on
syntax enable
syntax on
" Airline
let g:airline#extensions#tabline#enabled = 1
let g:airline_powerline_fonts = 1
let g:airline#extensions#ale#enabled = 1
let g:airline_theme='minimalist'
" Ale syntax more settings
function! LinterStatus() abort
let l:counts = ale#statusline#Count(bufnr(''))
let l:all_errors = l:counts.error + l:counts.style_error
let l:all_non_errors = l:counts.total - l:all_errors
return l:counts.total == 0 ? 'OK' : printf(
\ '%dW %dE',
\ all_non_errors,
\ all_errors
\)
endfunction
" This runs linter when you open a file if enabled to 1
"let g:ale_lint_on_enter = 0
let g:ale_lint_on_text_changed = 'never'
let g:ale_lint_on_insert_leave = 0
let g:ale_lint_on_save = 1
let g:ale_list_window_size = 5
let g:ale_sign_error = ''
let g:ale_sign_warning = '.'
let g:ale_fixers = {
\ 'vue': ['prettier', 'eslint']
\}
" Split navigations
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>
" add < > html brackets to pair
au FileType html let b:AutoPairs = AutoPairsDefine({'<!--' : '-->'})
au FileType erb let b:AutoPairs = AutoPairsDefine({'<' : '>'})
au FileType liquid let b:AutoPairs = AutoPairsDefine({'<!--' : '-->'})
au FileType html let b:AutoPairs = AutoPairsDefine({'<' : '>'})
au FileType liquid let b:AutoPairs = AutoPairsDefine({'<' : '>'})
" Python settings
autocmd Filetype python setlocal autoindent fileformat=unix expandtab softtabstop=4 tabstop=4 shiftwidth=4
" Flagging unnecessary whitespace
au BufRead,BufNewFile *.py,*.pyw,*.c,*.h match BadWhitespace /\s\+$/
" General settings
set autoindent
set autowrite
set backspace=indent,eol,start
set clipboard=unnamed
"set cursorline
set encoding=utf-8
set expandtab
set fileformat=unix
" This setting for font will only work with MacVim, user iTerm2 preferences
"set guifont=Hack
set ignorecase
set linebreak
set mouse=a
set number
set nu
set nospell
set softtabstop=2
set shiftwidth=2
set splitbelow
set splitright
set t_Co=256
set tabstop=2
set textwidth=79
set timeoutlen=1000 ttimeoutlen=0
set updatetime=250
set vb t_vb= " no visual bell & flash
set wrap
set wrapmargin=0
" NERDTree settings
"let NERDTreeQuitOnOpen = 1
"map <C-n> :NERDTreeToggle<CR>
let NERDTreeShowHidden=1
"autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif
"let NERDTreeIgnore=['\.pyc$', '\~$'] "ignore files in NERDTree
"let NERDTreeAutoDeleteBuffer = 1
"let NERDTreeMinimalUI = 1
"let NERDTreeDirArrows = 1
" Start Vim without . for directory
"autocmd StdinReadPre * let s:std_in=1
"autocmd VimEnter * if argc() == 0 && !exists("s:std_in") | NERDTree | endif
let &t_SI = "\<Esc>Ptmux;\<Esc>\<Esc>]50;CursorShape=1\x7\<Esc>\\"
let &t_SR = "\<Esc>Ptmux;\<Esc>\<Esc>]50;CursorShape=2\x7\<Esc>\\"
let &t_EI = "\<Esc>Ptmux;\<Esc>\<Esc>]50;CursorShape=0\x7\<Esc>\\"
" CtrlP
let g:ctrlp_user_command = ['.git', 'cd %s && git ls-files -co --exclude-standard']
let g:ctrlp_map = '<c-p>'
let g:ctrlp_cmd = 'CtrlP'
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
# Path to your oh-my-zsh installation.
export ZSH="/Users/adrianvalenzuela/.oh-my-zsh"
# Path to MacVim script to open mvim in terminal
export PATH=/Applications/MacVim.app/Contents/bin/:$PATH
# Use PHP & installed from brew
export PATH=/usr/local/bin/php:$PATH
# Laravel in path
export PATH=~/.composer/vendor/bin:$PATH
# Set name of the theme to load --- if set to "random", it will
# load a random theme each time oh-my-zsh is loaded, in which case,
# to know which specific one was loaded, run: echo $RANDOM_THEME
# See https://github.com/ohmyzsh/ohmyzsh/wiki/Themes
#ZSH_THEME="darkblood"
ZSH_THEME="dracula"
# 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)
source $ZSH/oh-my-zsh.sh
# User configuration
# 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"
# NVM
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
# Ruby
if which rbenv > /dev/null; then eval "$(rbenv init -)"; fi
# Python
if command -v pyenv 1>/dev/null 2>&1; then
eval "$(pyenv init -)"
fi
# Tmux prefix...most people use Control-A
set-option -g prefix C-f
#No delay when hitting escape key
set -sg escape-time 0
#No or little delay in repeat time
set-option -g repeat-time 500
set -g mouse on
# increase scrollback lines
set -g history-limit 10000
#Positon status bar on top of window
#set-option -g status-position top
# Use vim keybindings in copy mode
setw -g mode-keys vi
bind -r C-k resize-pane -U
bind -r C-j resize-pane -D
bind -r C-h resize-pane -L
bind -r C-l resize-pane -R
bind -r k select-pane -U
bind -r j select-pane -D
bind -r h select-pane -L
bind -r l select-pane -R
unbind Up
unbind Down
unbind Left
unbind Right
unbind C-Up
unbind C-Down
unbind C-Left
unbind C-Right
# themes and colors
# improve colors
#------------------------------------
# Layout and Theme
#------------------------------------
# Dracula Colours
# background_color '#282a36'
# current_line_color '#44475a'
# foreground_color '#f8f8f2'
# comment_color '#6272a4'
# cyan '#8be9fd'
# green '#50fa7b'
# orange '#ffb86c'
# pink '#ff79c6'
# purple '#bd93f9'
# red '#ff5555'
# yellow '#f1fa8c'
set -g default-terminal "screen-256color"
# pane border
set -g pane-border-style fg='#bd93f9'
set -g pane-active-border-style fg='#ff79c6'
# message text
set -g message-style bg='#44475a',fg='#8be9fd'
set -g status-style bg='#44475a',fg='#bd93f9'
set -g status-interval 1
# status left
# are we controlling tmux or the content of the panes?
set -g status-left '#[bg=#f8f8f2]#[fg=#282a36]#{?client_prefix,#[bg=#ff79c6],} ☺ '
# are we zoomed into a pane?
set -ga status-left '#[bg=#44475a]#[fg=#ff79c6] #{?window_zoomed_flag, ↕ , }'
# window status
set-window-option -g window-status-style fg='#bd93f9',bg=default
set-window-option -g window-status-current-style fg='#ff79c6',bg='#282a36'
set -g window-status-current-format "#[fg=#44475a]#[bg=#bd93f9]#[fg=#f8f8f2]#[bg=#bd93f9] #I #W #[fg=#bd93f9]#[bg=#44475a]"
set -g window-status-format "#[fg=#f8f8f2]#[bg=#44475a]#I #W #[fg=#44475a] "
# status right
set -g status-right '#[fg=#8be9fd,bg=#44475a]#[fg=#44475a,bg=#8be9fd] #(tmux-mem-cpu-load -g 5 --interval 2) '
set -ga status-right '#[fg=#ff79c6,bg=#8be9fd]#[fg=#44475a,bg=#ff79c6] #(uptime | cut -f 4-5 -d " " | cut -f 1 -d ",") '
set -ga status-right '#[fg=#bd93f9,bg=#ff79c6]#[fg=#f8f8f2,bg=#bd93f9] %a %H:%M:%S #[fg=#6272a4]%Y-%m-%d '
#set -g default-terminal 'screen-256color'
#set -g status-bg black
#set -g status-fg white
#set-window-option -g window-status-current-fg red
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment