added -p flag to default vim call to start in tab mode

This commit is contained in:
2024-12-22 00:06:59 -05:00
parent c371ac7cf1
commit 939823c7c4
2 changed files with 19 additions and 123 deletions
-113
View File
@@ -1,113 +0,0 @@
" ====================================================================
" Auth: Alex Celani
" File: .vimrc
" Revn: 04-17-2023 2.0
" Func: Define how Vim works, set parameters, define keymaps
"
" TODO: add in Greek keymaps
" make goddamn numpad work on terminal/in vim
" make all comments linewrap/<CR>wrap onto new line
" ====================================================================
" CHANGE LOG
" --------------------------------------------------------------------
" ??-??-2018: init
" 05-2?-2019: new files of certain filetype autoinsert this opening
" comment header block
" 06-01-2019: fixed autocomplete braces not holding indents
" 08-01-2019: added linewrapping
" 03-27-2020: explicitly set syntax coloring
" set column numbers
" 04-16-2020: changed automatic comment header directory to .vim/*
" 08-30-2020: changed comment#.txt to commentN.txt to avoid errors
" 09-05-2020: changed tapstop and shiftwidth from 3 to 4
" 10-02-2020: added .txt to files that open commentN.txt
" 10-11-2020: made line numbers green
" changed line wrap from 80 characters to 70
" 03-02-2022: commented out GoLang channel inoremap ( ,- -> <- )
" 06-20-2022: commented out GoLang instantiate inoremap ( ;= -> := )
"*04-17-2023: added txt and book filetypes to commentN.txt
" added laststatus to always display filename
"
" ====================================================================
" Explicitly set syntax coloring to on
syntax on
" Reset highlight color for comments to lightblue
"hi comment ctermfg=lightblue
" Set line numbering and color of such
set number
hi LineNr ctermfg=Green
" Set column number
set ruler
" Set the amount of spaces in a tab
set tabstop=4
" NFC
set shiftwidth=4
" Replace tab char with spaces
set expandtab
" Copies indent of last line and adds onto <CR>
set autoindent
" Sets character length of line to 70 characters, linewraps
set tw=70
" some way, somehow, this displays the file name at the bottom
set laststatus=2
" Remap {<Enter> with auto close brace and tab in
" THIS COULD BE BETTER, COMBINE WITH AUTOINDENT
inoremap {<CR> {<CR>f<CR>}<Up><End><Backspace><Tab>
" Close that mf paren
" THIS TAKES TIME, IS IT POSSIBLE TO MAKE IT FASTER
" UPDATE -> this only takes time if you wait for it,
" typing immediately expedites the process
inoremap ( ( )<Left><Left>
" Skip over closed parens
inoremap () ()
" Auto infer declare/instantiate operator for GoLang
"inoremap ;= :=
" Auto infer channel operator for GoLang
"inoremap ,- <-
" Auto-insert printf
" TODO:
" Make language specific shit
"inoremap Print<CR> printf();<Left><Left>
" Open new files with comment blocks
" Bash, Julia, Ruby, and Text all use pound signs ( # )
" also book-types like Providence, ANO, etc
autocmd BufNewFile *.sh :r ~/.vim/commentN.txt
autocmd BufNewFile *.jl :r ~/.vim/commentN.txt
autocmd BufNewFile *.rb :r ~/.vim/commentN.txt
autocmd BufNewFile *.txt :r ~/.vim/commentN.txt
autocmd BufNewFile *.prv :r ~/.vim/commentN.txt
" Matlab uses percent signs ( % )
autocmd BufNewFile *.m :r ~/.vim/commentP.txt
" Python uses triple quotes ( """ -> """ )
autocmd BufNewFile *.py :r ~/.vim/commentQ.txt
" C, Go, and Rust use double slashes
autocmd BufNewFile *.c :r ~/.vim/commentS.txt
autocmd BufNewFile *.go :r ~/.vim/commentS.txt
autocmd BufNewFile *.rs :r ~/.vim/commentS.txt
" So this is how you fuck around
" When g is pressed, it sets the comment color to black, goes back to Insert
" mode, and then types g
" inoremap g <Esc>:hi comment ctermfg=black<CR>ig
+18 -9
View File
@@ -1,10 +1,11 @@
# ==============================================================================
# Auth: dodd
# File: .zshrc
# Revn: 04-11-2024 1.0
# Revn: 12-20-2024 1.5
# Func: Define user-made aliases and functions to make using the terminal easier
#
# TODO: make bt functions to check for connection before dc/connecting
# research git command stuff
# ==============================================================================
# CHANGE LOG
# ------------------------------------------------------------------------------
@@ -18,9 +19,17 @@
# 12-28-2023: added blueutil aliases to connect/dc from M50x's
# 01-18-2024: converted btutil aliases into functions
# added power on/off to btfunctions
# 04-11-2024: removed constant ip call, because of ddns (thanks luke)
#*04-11-2024: removed constant ip call, because of ddns (thanks luke)
# added o and p flags to ls alias
# gutted remote ssh calls, replaced with ddns
# 05-11-2024: added git branch recognition of some sort
# 05-16-2024: updated pi static IP's ( fuck speccy )
# fixed accidental yank and place of "-p 23" in sentinel
# 06-07-2024: updated pi public IP's ( fuck speccy again )
# fixed accidental renaming ofrsentinel as rocelot
# 10-22-2024: updated prompt, moving git branch to beginning
# placed branch inside double brackets, [[ ]] ( vcs_git )
# 12-20-2024: added -p flag to vim alias
#
# ==============================================================================
@@ -42,10 +51,10 @@ alias l="ls -AFGhlo"
alias home="cd ~"
### local ssh
alias ocelot="ssh ocelot@192.168.1.120"
alias sentinel="ssh -p 23 pi@192.168.1.169"
alias rocelot="ssh ocelot@kaer-morhen.kozow.com"
alias rocelot="ssh -p 23 pi@kaer-morhen.kozow.com"
alias ocelot="ssh ocelot@192.168.1.152"
alias sentinel="ssh pi@192.168.1.139"
alias rocelot="ssh ocelot@97.70.74.80"
alias rsentinel="ssh -p 23 pi@97.70.74.80"
### mac gcc is an alias for clang
@@ -58,7 +67,7 @@ alias donut="~/bin/donut"
### tdm
alias tdm="~/bin/tdm"
alias vim="vim +\"colo real_def\""
alias vim="vim +\"colo real_def\" -p"
### load changes to .zshrc
alias src="source ~/.zshrc"
@@ -88,13 +97,13 @@ btdc() {
autoload -Uz vcs_info
precmd() { vcs_info }
zstyle ':vcs_info:git:*' formats '%b '
zstyle ':vcs_info:git:*' formats '%F{white}<<%f%F{red}[[%b]]%f'
# zsh.sourceforge.io/Doc/Release/Prompt-Expansion.html
setopt PROMPT_SUBST
# %F{color}...%f colors the encompassed text /color/
# %m - shows the short machine name
# %1d - current working directory
PROMPT='%F{green}%m%f:%F{blue}%1~%f ⇌ '
PROMPT='%F{green}%m%f%B%F{red}${vcs_info_msg_0_}%b%f::%F{blue}%1~%f ⇌ '
#PROMPT='%F{green}%*%f %F{blue}%~%f %F{red}${vcs_info_msg0}%f$ '