diff options
author | xyz <gky44px1999@gmail.com> | 2021-09-18 00:17:43 -0700 |
---|---|---|
committer | xyz <gky44px1999@gmail.com> | 2021-09-18 00:17:43 -0700 |
commit | 52e37d954a1143b1ae480c1db459793566bc79ed (patch) | |
tree | 1ba7ce49b42adfb9cc34797e85b7eb343e1b1cad /.local | |
parent | ca53eb05a2c1f3d2f30befce20b744c31c8e3dd0 (diff) |
upd, fast, all, refactor
Diffstat (limited to '.local')
-rwxr-xr-x | .local/bin/upd | 52 |
1 files changed, 33 insertions, 19 deletions
diff --git a/.local/bin/upd b/.local/bin/upd index b164977a..a9df9b29 100755 --- a/.local/bin/upd +++ b/.local/bin/upd @@ -1,9 +1,21 @@ #!/bin/sh # may need mkdir -p for some of the dirs? kg and ncm no need, how about refl and gall -refl () +all () { - sudo reflector --save /etc/pacman.d/mirrorlist --latest 200 --sort rate + fast + qb + ncm + kg + refl + gall +} + +fast () +{ + pac + misc + usb } gall () @@ -17,6 +29,12 @@ kg () curlkg -u64949d822c25328c -- "$XDG_MUSIC_DIR/not_pure/cheng_ruan/kg/" } +misc () +{ + tldr --update + nvim +PlugUpgrade +PlugUpdate +qa +} + ncm () { curlncm -a48860966 -- "$XDG_MUSIC_DIR/not_pure/lan_lan/ncm/artist/" @@ -40,39 +58,35 @@ qb () curlqb "$HOME/programs/qbittorrent_search_plugins/" } + +refl () +{ + sudo reflector --save /etc/pacman.d/mirrorlist --latest 200 --sort rate +} + usb () { cfgc push usb cfgl push usb - cfgs push usb + cfgs push git --git-dir="$XDG_DOCUMENTS_DIR/notes/.git" --work-tree="$XDG_DOCUMENTS_DIR/notes/" push usb } -misc () -{ - tldr --update - nvim +PlugUpgrade +PlugUpdate +qa -} - if [ $# -eq 0 ]; then - pac - misc - qb - ncm - kg - refl - gall + fast else - while getopts rgknpqum opt; do + while getopts afgkmnpqru opt; do case $opt in - r)refl;; + a)all;; + f)fast;; g)gall;; k)kg;; + m)misc;; n)ncm;; p)pac;; q)qb;; + r)refl;; u)usb;; - m)misc;; \?)exit 1;; esac done |