X-Git-Url: https://git.martlubbers.net/?a=blobdiff_plain;f=shell%2F.local%2Fbin%2Fupdate;h=2dedbc064882a5a9d3f52fda8865b89cb56b40af;hb=c59a11e7dc0bdceb25590ce97ab2eab76ec5818a;hp=b32ce611baed29b9515f1da5640fe70422fc88b0;hpb=7efd7af689d6679b43e1606460d52258571db2e8;p=dotfiles.git diff --git a/shell/.local/bin/update b/shell/.local/bin/update index b32ce61..2dedbc0 100755 --- a/shell/.local/bin/update +++ b/shell/.local/bin/update @@ -1,17 +1,10 @@ #!/bin/sh -DV=/etc/debian_version NUL='>/dev/null 2>&1' cmd() { - if [ -f $DV ] - then - echo -n 'apt-get update && apt-get dist-upgrade -y ' - [ `head -c 1 $DV` -ge 9 ] && echo -n '--' || -n '&& apt-get ' - echo -n 'autoremove --purge && apt-get clean && apt-get autoclean' - else - echo -n 'pacman -Syu && pacman -Qdtq | ifne xargs pacman -R' - fi + echo -n 'apt-get update && apt-get dist-upgrade -y && ' + echo -n 'apt-get autoremove --purge && apt-get clean && apt-get autoclean' } sudo sh -c "$(cmd)" -sh -c "tlmgr update --all --self && offlineimap -u ttyui && vdirsyncer sync && khal -c .config/khal/config $NUL && khard $NUL && pass git pull origin master" +sh -c "tlmgr update --all --self && offlineimap -o -u ttyui && vdirsyncer sync && khal -c .config/khal/config $NUL && khard $NUL && pass git pull origin master"