refresh macos

This commit is contained in:
Diego Fernando Carrión 2021-08-26 18:42:22 +02:00
parent a2c92011d0
commit 4f61cff440
7 changed files with 195 additions and 89 deletions

28
any/bash/.bash_profile Normal file
View File

@ -0,0 +1,28 @@
# ~/.bash_profile
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ]; then
export PATH="$HOME/bin:$PATH"
fi
[ -d "$HOME/devel/venvs" ] && export WORKON_HOME=~/devel/venvs
[ -d "$HOME/devel/go" ] && export GOPATH=$HOME/devel/go
[ -d /usr/local/go/bin ] && export PATH=/usr/local/go/bin:$PATH
[ -d "$HOME/.local/bin" ] && export PATH=$HOME/.local/bin:$PATH
export LC_ALL=en_US.UTF-8
export LANG=en_US.UTF-8
if command -v go 1>/dev/null 2>&1
then
export PATH=$PATH:$(go env GOPATH)/bin
fi
if [[ "$OSTYPE" == "linux-gnu"* && ! -f /etc/debian_version ]]
then
echo
fi
[ -f ~/.bash_profile.local ] && . "$HOME/.bash_profile.local"
[ -f "$HOME/.bashrc" ] && . "$HOME/.bashrc"

View File

@ -33,6 +33,41 @@ HISTFILESIZE=4096
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
if [ -d "$HOME/.pyenv" ]; then
export PYENV_ROOT="$HOME/.pyenv"
export PATH="$PYENV_ROOT/bin:$PATH"
if command -v pyenv 1>/dev/null 2>&1; then
if ! shopt -q extglob
then
resetextglob=true
shopt -s extglob
fi
if [[ "${OSTYPE%%+([[:digit:].])}" == "darwin" ]]
then
eval "$(pyenv init --path)"
fi
if $resetextglob
then
shopt -u extglob
fi
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"
fi
fi
if [[ -s "$HOME/.gvm/scripts/gvm" ]]; then
source "$HOME/.gvm/scripts/gvm"
fi
if [[ "$OSTYPE" == "linux-gnu"* && -f /etc/debian_version ]]
then
# if [ -d $HOME/.pyenv ]
# then
# pyenv3
# export HI="hi"
# fi
echo
fi
#### Includes ####
##################
@ -42,36 +77,16 @@ shopt -s checkwinsize
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
. "$HOME/.bash_aliases"
fi
if [ -f ~/.bash_functions ]; then
. ~/.bash_functions
. "$HOME/.bash_functions"
fi
# Machine Specific Configs
if [ -f ~/.bashrc.local ]; then
. ~/.bashrc.local
. "$HOME/.bashrc.local"
fi
####
if [[ "$OSTYPE" == "linux-gnu"* && -f /etc/debian_version ]]
then
if [ -d "$HOME/.pyenv" ]; then
export PYENV_ROOT="$HOME/.pyenv"
export PATH="$PYENV_ROOT/bin:$PATH"
if command -v pyenv 1>/dev/null 2>&1; then
touch ~/foo
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"
fi
fi
if [ -d $HOME/.pyenv ]
then
pyenv3
export HI="hi"
fi
fi
[[ -s "/home/crthaze/.gvm/scripts/gvm" ]] && source "/home/crthaze/.gvm/scripts/gvm"

View File

@ -1,51 +0,0 @@
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ]; then
export PATH="$HOME/bin:$PATH"
fi
export GOPATH=$HOME/devel/go
if [ -d /usr/local/go/bin ]
then
export PATH=/usr/local/go/bin:$PATH
fi
if [ -d $HOME/.local/bin ]
then
export PATH=$HOME/.local/bin:$PATH
fi
if which go
then
export PATH=$PATH:$(go env GOPATH)/bin
fi
#PATH="/usr/local/opt/python/libexec/bin:$PATH"
if [ -f ~/.profile.local ]; then
. ~/.profile.local
fi
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f "$HOME/.bashrc" ]; then
. "$HOME/.bashrc"
fi
fi
if [[ "$OSTYPE" == "linux-gnu"* && ! -f /etc/debian_version ]]
then
if [ -d "$HOME/.pyenv" ]; then
export PYENV_ROOT="$HOME/.pyenv"
export PATH="$PYENV_ROOT/bin:$PATH"
if command -v pyenv 1>/dev/null 2>&1; then
touch ~/foo
eval "$(pyenv init -)"
fi
# eval "$(pyenv virtualenv-init -)"
fi
fi

View File

@ -0,0 +1,9 @@
{
"languageserver": {
"golang": {
"command": "gopls",
"rootPatterns": ["go.mod", ".vim/", ".git/", ".hg/"],
"filetypes": ["go"]
}
}
}

View File

@ -0,0 +1,35 @@
Workiva
Carrión
Cloudformation
SRE
SLIs
SLOs
SLAs
SLI
Microservice
Kubernetes
Simons
blog
SRE's
PRs
metadata
nextgen
deployer
repo
Wspend
App
workflow
DaemonSet
CronJob
dev
pentest
eu
APM
infre
Wdata
K8s
wiki
CLI
diego
SLA
SLO

Binary file not shown.

View File

@ -2,11 +2,11 @@ call plug#begin('~/.vim/plugged')
Plug 'fatih/vim-go', { 'do': ':GoUpdateBinaries' } " Amazing combination of features.
"Plug 'godoctor/godoctor.vim' " Some refactoring tools
Plug 'plytophogy/vim-virtualenv'
"Plug 'terryma/vim-multiple-cursors'
Plug 'mg979/vim-visual-multi'
Plug 'airblade/vim-rooter'
Plug 'vim-airline/vim-airline'
Plug 'vim-airline/vim-airline-themes'
Plug 'majutsushi/tagbar' " install exuberant-ctags
" Plug 'majutsushi/tagbar' " install exuberant-ctags
Plug 'tpope/vim-commentary'
Plug 'tpope/vim-fugitive'
Plug 'SirVer/ultisnips'
@ -21,12 +21,13 @@ Plug 'PotatoesMaster/i3-vim-syntax'
"Plug 'tpope/vim-surround'
"Plugin 'jiangmiao/auto-pairs'
"Plug 'elzr/vim-json'
Plug 'honza/vim-snippets'
if !has('nvim')
" Plugins for when you're not using neovim
endif
if has('nvim')
Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' }
Plug 'zchee/deoplete-go', {'build': {'unix': 'make'}}
" Plug 'neoclide/coc.nvim', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc.nvim', {'branch': 'release'}
"Plug 'jodosha/vim-godebug' " Debugger integration via delve
endif
" All of your Plugs must be added before the following line
@ -37,17 +38,78 @@ call plug#end()
"""""""""""""""""
""" deoplete
if has('nvim')
" Enable deoplete on startup
let g:deoplete#enable_at_startup = 1
call deoplete#custom#option('omni_patterns', { 'go': '[^. *\t]\.\w*' })
"call deoplete#custom#option('prev_completion_mode', 'mirror')
" Disable deoplete when in multi cursor mode
"function! Multiple_cursors_before()
" let b:deoplete_disable_auto_complete = 1
"endfunction
"function! Multiple_cursors_after()
" let b:deoplete_disable_auto_complete = 0
"endfunction
" ---------------------------------------------------------------------------
" coc.nvim default settings
" ---------------------------------------------------------------------------
" if hidden is not set, TextEdit might fail.
set hidden
" Better display for messages
set cmdheight=2
" Smaller updatetime for CursorHold & CursorHoldI
set updatetime=300
" don't give |ins-completion-menu| messages.
set shortmess+=c
" always show signcolumns
set signcolumn=yes
" Use tab for trigger completion with characters ahead and navigate.
" Use command ':verbose imap <tab>' to make sure tab is not mapped by other plugin.
inoremap <silent><expr> <TAB>
\ pumvisible() ? "\<C-n>" :
\ <SID>check_back_space() ? "\<TAB>" :
\ coc#refresh()
inoremap <expr><S-TAB> pumvisible() ? "\<C-p>" : "\<C-h>"
function! s:check_back_space() abort
let col = col('.') - 1
return !col || getline('.')[col - 1] =~# '\s'
endfunction
" Use <c-space> to trigger completion.
inoremap <silent><expr> <c-space> coc#refresh()
" Use `[c` and `]c` to navigate diagnostics
nmap <silent> [c <Plug>(coc-diagnostic-prev)
nmap <silent> ]c <Plug>(coc-diagnostic-next)
" Remap keys for gotos
nmap <silent> gd <Plug>(coc-definition)
nmap <silent> gy <Plug>(coc-type-definition)
nmap <silent> gi <Plug>(coc-implementation)
nmap <silent> gr <Plug>(coc-references)
" Use U to show documentation in preview window
nnoremap <silent> U :call <SID>show_documentation()<CR>
" Remap for rename current word
nmap <leader>rn <Plug>(coc-rename)
" Remap for format selected region
vmap <leader>f <Plug>(coc-format-selected)
nmap <leader>f <Plug>(coc-format-selected)
" Show all diagnostics
nnoremap <silent> <space>a :<C-u>CocList diagnostics<cr>
" Manage extensions
nnoremap <silent> <space>e :<C-u>CocList extensions<cr>
" Show commands
nnoremap <silent> <space>c :<C-u>CocList commands<cr>
" Find symbol of current document
nnoremap <silent> <space>o :<C-u>CocList outline<cr>
" Search workspace symbols
nnoremap <silent> <space>s :<C-u>CocList -I symbols<cr>
" Do default action for next item.
nnoremap <silent> <space>j :<C-u>CocNext<CR>
" Do default action for previous item.
nnoremap <silent> <space>k :<C-u>CocPrev<CR>
" Resume latest coc list
nnoremap <silent> <space>p :<C-u>CocListResume<CR>n
" disable vim-go :GoDef short cut (gd)
" this is handled by LanguageClient [LC]
let g:go_def_mapping_enabled = 0
""" Coc Snippets
endif
@ -128,6 +190,7 @@ let g:airline_symbols.linenr = '☰'
let g:airline_symbols.maxlinenr = ''
let g:airline_symbols.dirty='⚡'
"""""""""""""""""""""
" Personal Settings "
"""""""""""""""""""""
@ -163,3 +226,10 @@ autocmd filetype tf setlocal expandtab
"set list lcs=tab:\⇥\ ,trail:▓,space:.
set list lcs=tab:\⇥\ ,trail:▓
""" Help Navigation
autocmd FileType help nnoremap <buffer> <CR> <C-]>
autocmd FileType help nnoremap <buffer> <BS> <C-T>
autocmd FileType help nnoremap <buffer> o /'\l\{2,\}'<CR>
autocmd FileType help nnoremap <buffer> O ?'\l\{2,\}'<CR>
autocmd FileType help nnoremap <buffer> s /\|\zs\S\+\ze\|<CR>
autocmd FileType help nnoremap <buffer> S ?\|\zs\S\+\ze\|<CR>