new scripts
authorDaniel Liu <mr.picklepinosaur@gmail.com>
Tue, 15 Jun 2021 02:45:18 +0000 (22:45 -0400)
committerDaniel Liu <mr.picklepinosaur@gmail.com>
Tue, 15 Jun 2021 02:45:18 +0000 (22:45 -0400)
.config/shell/commonrc
.vim/mysnippets/tex.snippets
.vim/templates/skeleton.tex
.vimrc
.xinitrc
Scripts/monitor-attach [new file with mode: 0755]
Scripts/monitor-detach [new file with mode: 0755]
Scripts/setwallpaper [new file with mode: 0755]

index dbea038..e9a7df0 100644 (file)
@@ -13,6 +13,9 @@ alias refreshusb='udevadm control --reload-rules'
 alias vpnup='nmcli connection up pinovpn'
 alias drill-srs='drill-srs 2>/dev/null'
 alias scrkey='screenkey -t 2.5 --mods-mode emacs -s small -p fixed -g $(slop -n -f '%g')'
+alias mdp='export TERM=st; mdp'
+alias R='R --vanilla'
+alias fzf="fzf --color=16 --header=peee --info=inline --preview='echo {}; file -b {}; echo =-=-=-=-=-=-=-=-=-=-=-=-=-=; head -$LINES {}'"
 
 alias v="$EDITOR"
 alias z="$READER"
index 292727a..040304f 100644 (file)
@@ -303,3 +303,32 @@ snippet graph "Graph" w
 \end{axis}
 \end{tikzpicture}
 endsnippet
+
+snippet ffig "Figure" w
+\begin{figure}[H]
+    \centering
+    \includegraphics[scale=1]{$1}
+    \caption{$2}
+\end{figure}
+endsnippet
+
+snippet ftab "Table" w
+\begin{table}[H]
+\centering 
+\caption{$1}
+\begin{tabular}{$2}
+    \hline
+       $3
+    \hline
+    \hline
+\end{tabular}
+\end{table}
+endsnippet
+
+snippet b "bold" w
+\textbf{$1}$0
+endsnippet
+
+snippet i "italics" w
+\emph{$1}$0
+endsnippet
index ed1ec59..45658f6 100644 (file)
@@ -22,6 +22,7 @@
     \import{./resources/}{#2.pdf_tex}
 }
 
+% formatting
 \titleformat{\section}
 {\large\bfseries}{}{0em}{}[\titlerule]
 \titlespacing{\section}
         \thedate
     \end{center}
 }
+
+% commands
+\newcommand{\euler}{e}
+
 \begin{document}
 \parindent=0pt
 
diff --git a/.vimrc b/.vimrc
index 29ceed1..56cc40c 100644 (file)
--- a/.vimrc
+++ b/.vimrc
@@ -10,11 +10,12 @@ syntax on
 set number
 set relativenumber
 set incsearch
-set smartcase
 set encoding=utf-8
 set tabstop=4
 set shiftwidth=4
 set expandtab
+set ignorecase
+set smartcase
 set nrformats+=alpha "inc/dec alpha
 set hidden
 
@@ -110,6 +111,11 @@ set statusline+=\ %r\[%{v:register}\]
 set statusline+=\ %l/%L:%c\ |
 set statusline+=%1*\ |
 
+" Tab line
+hi TabLineSel   cterm=Bold ctermfg=Yellow
+hi TabLine      cterm=None ctermfg=Grey ctermbg=Black
+hi TabLineFill  cterm=None ctermbg=Black
+
 " Templates
 augroup templates
     autocmd BufNewFile *.tex 0r ~/.vim/templates/skeleton.tex
@@ -132,10 +138,10 @@ call plug#begin('~/.vim/plugged')
 Plug 'sirver/ultisnips'
 Plug 'lervag/vimtex'
 Plug 'PietroPate/vim-tex-conceal'
-Plug 'jiangmiao/auto-pairs'
+Plug 'jiangmiao/auto-pairs'
 Plug 'tpope/vim-commentary'
 Plug 'rlue/vim-barbaric'
-Plug 'ap/vim-css-color'
+Plug 'ap/vim-buftabline'
 
 call plug#end()
 
@@ -163,16 +169,13 @@ let g:vimtex_compiler_latexmk = {
     " \   '-shell-escape',
     " \],
 
-" Ctrlp
-" let g:ctrlp_cmd='CtrlPTag'
-
-" Lf
-" let g:lf_replace_netrw = 1 " weird behavior rn
-
 " vim-barbaric
 let g:barbaric_ime = 'ibus'
 set ttimeoutlen=0
 
+" buftabline
+let g:buftabline_show = 1
+
 " Run after plugins
 autocmd FileType * set formatoptions-=o
 
@@ -196,9 +199,6 @@ hi SpellRare      ctermbg=13 ctermbg=0 cterm=underline
 hi SpellLocal     ctermfg=14 ctermbg=0 cterm=underline
 hi PmenuSbar      ctermbg=8
 hi PmenuThumb     ctermbg=0
-hi TabLine        cterm=underline ctermfg=0 ctermbg=7
-hi TabLineSel     cterm=bold
-hi TabLineFill    cterm=reverse
 hi CursorColumn   ctermbg=7
 hi CursorLine     cterm=underline
 hi MatchParen     cterm=NONE ctermfg=0 ctermbg=14
@@ -212,7 +212,7 @@ hi Underlined     cterm=underline ctermfg=5
 hi Ignore         ctermfg=15
 hi Error          ctermfg=15 ctermbg=9
 hi Todo           ctermfg=0 ctermbg=11
-hi Comment        ctermfg=7
+hi Comment        ctermfg=DarkGrey
 hi lineNr         ctermfg=DarkGrey
 hi Folded         ctermfg=0
 
index 593d27d..e6fde30 100644 (file)
--- a/.xinitrc
+++ b/.xinitrc
@@ -26,13 +26,13 @@ if [ -d /etc/X11/xinit/xinitrc.d ] ; then
 fi
 
 # bg
-feh --bg-center "$(ls -d $HOME/Downloads/wallpapers/active/* | sort -R | tail -n1)"
-
+setwallpaper
 # start some daemons
 dwmblocks &
 tiramisu -j | notify &
 acpi_listen &
-redshift -l 55.7:12.6 -t 3000:3000 -g 0.85 -m randr -v &
+redshift -m randr:crtc=0 -O 3000
+# redshift -l 55.7:12.6 -t 3000:3000 -g 1 -m randr -v &
 sxhkd &
 mpd &
 mpd-change &
diff --git a/Scripts/monitor-attach b/Scripts/monitor-attach
new file mode 100755 (executable)
index 0000000..05eac0a
--- /dev/null
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+xrandr --newmode "1920x1080_60.00" 172.80  1920 2040 2248 2576  1080 1081 1084 1118  -HSync +Vsync
+xrandr --addmode VGA1 "1920x1080_60.00"
+xrandr --auto --output VGA1 --mode 1920x1080_60.00 --right-of LVDS1
+
+# redshift
+redshift -x
+redshift -m randr:crtc=0 -O 3000
+redshift -m randr:crtc=1 -O 5000
+
+# need to reset wallpaper too
+setwallpaper
diff --git a/Scripts/monitor-detach b/Scripts/monitor-detach
new file mode 100755 (executable)
index 0000000..661da5c
--- /dev/null
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+xrandr --output VGA1 --off
diff --git a/Scripts/setwallpaper b/Scripts/setwallpaper
new file mode 100755 (executable)
index 0000000..a4ed037
--- /dev/null
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+feh --bg-fill "$(ls -d $HOME/Downloads/wallpapers/active/* | sort -R | tail -n1)"