1
0
Fork 0
mirror of https://github.com/notwa/rc synced 2024-04-30 02:53:22 -07:00

Compare commits

...

5 Commits

4 changed files with 30 additions and 12 deletions

View File

@ -161,7 +161,7 @@ alias katagana='perlu -MUnicode::Normalize -pe'"'"'$_=NFKD($_)=~y/ァ-ヶ /ぁ-
alias picky='comm -23 <(pacman -Qetq | sort -u) <(pacman -Qgq base base-devel xorg xorg-drivers xfce4 mingw-w64-x86_64-toolchain 2>/dev/null | sort -u) | tr -d "\t"' ### @-
### list pacman packages that were manually installed and are not in some common package groups.
### this list can be used to assist later reinstalls.
alias unused='comm -23 <(pacman -Qtq) <(pacman -Qeq) | tr -d "\t"' ### @-
alias unused='comm -23 <(pacman -Qtq | sort) <(pacman -Qeq | sort) | tr -d "\t"' ### @-
### list pacman packages that weren't installed explicitly and don't satisfy any dependencies.
### this list can be used to free up some disk space.
alias makepkgf='makepkg -Af --skipchecksums --skippgpcheck' ### @- make the freakin' package!

View File

@ -183,6 +183,7 @@ fu! DetectShebang()
if p ==# 'bash' | setlocal ft=bash | endif
if p ==# 'dash' | setlocal ft=bash | endif
if p ==# 'false' | setlocal ft=bash | endif
if p ==# 'kuroko' | setlocal ft=python | endif
if p ==# 'lua' | setlocal ft=lua | endif
if p ==# 'perl' | setlocal ft=perl | endif
if p ==# 'perl6' | setlocal ft=raku | endif
@ -198,20 +199,21 @@ endf
if has('autocmd')
augroup tabs
au!
au BufRead,BufNewFile PKGBUILD call TabTwo()
au FileType ruby call TabTwo()
au FileType nim call TabTwo()
au BufRead,BufNewFile *.bt,*.1sc call TabFour()
au BufRead,BufNewFile *.ys call TabTwo()
au FileType javascript,processing call TabTwo()
au BufRead,BufNewFile .gitconfig call TabEight()
au BufRead,BufNewFile PKGBUILD call TabTwo()
au FileType ruby call TabTwo()
au FileType nim call TabTwo()
au BufRead,BufNewFile *.bt,*.1sc call TabFour()
au BufRead,BufNewFile *.ys call TabTwo()
au FileType javascript,processing call TabTwo()
au BufRead,BufNewFile .gitconfig call TabEight()
augroup END
augroup filetypes
au!
au BufRead,BufNewFile *.lib setlocal ft=spice
au BufRead,BufNewFile *.bt setlocal ft=c
au BufRead,BufNewFile *.bt setlocal ft=c
au BufRead,BufNewFile *.1sc setlocal ft=c
au BufRead,BufNewFile *.krk setlocal ft=python
au BufRead,BufNewFile *.asm setlocal ft=lips
au BufRead,BufNewFile *.nim setlocal ft=nim
au BufRead,BufNewFile *.pde setlocal ft=processing
@ -250,7 +252,7 @@ if has('autocmd')
endf
augroup resCur
au!
au BufWinEnter * call ResCur()
" au BufWinEnter * call ResCur()
augroup END
endif

View File

@ -38,6 +38,7 @@ function {
if [ "$SHLVL" -le 1 ] \
&& [ "${TERM#screen}" = "$TERM" ] \
&& [ "${TERM#tmux}" = "$TERM" ] \
&& [ -z "$ALACRITTY_LOG" ] \
&& (( $+commands[tmux] ))
then
# create a new session called "what" or attach if it already exists

View File

@ -21,6 +21,21 @@ getladspa() {
fi
}
ytdl() {
if has yt-dlp; then
yt-dlp "$@"
return
elif has yt-dlc; then
yt-dlc "$@"
return
elif has youtube-dl; then
youtube-dl "$@"
return
fi
echo "bro where is your youtube-dl" >&2
return 99
}
# Q: Why are these variables prefixed with _M_?
# A: I don't remember. :shobon:
_M_PRE_EMPH='equalizer=f=50:g=-10:width_type=o:w=4,equalizer=f=5000:g=+5:width_type=o:w=4'
@ -137,13 +152,13 @@ ytll() { ### @-
### watch a stream from youtube in mpv, etcetera etcetera.
### this is the low latency version that does not support seeking.
argc $# -ge 1 "$0" || return
youtube-dl -q -f best "$1" -o - | mpv_stream - --no-ytdl
ytdl -q -f best "$1" -o - | mpv_stream - --no-ytdl
}
ytgll() { # @-
# watch a stream from youtube in mpv. like `ytll`, but with a preference for different formats.
argc $# -ge 1 "$0" || return
youtube-dl -q -f 22/95/300/best "$1" -o - | mpv_stream - --no-ytdl
ytdl -q -f 22/95/300/best "$1" -o - | mpv_stream - --no-ytdl
}
ai() { # @-