Refine update alias
This commit is contained in:
parent
5acb1dfb07
commit
efae4c58c0
1 changed files with 16 additions and 14 deletions
|
@ -154,10 +154,6 @@ update() {
|
||||||
plugins
|
plugins
|
||||||
}
|
}
|
||||||
|
|
||||||
repo() {
|
|
||||||
aur sync -Su --margs --noconfirm
|
|
||||||
}
|
|
||||||
|
|
||||||
plugins() {
|
plugins() {
|
||||||
nvim +PackerSync +TSUpdate
|
nvim +PackerSync +TSUpdate
|
||||||
zinit self-update
|
zinit self-update
|
||||||
|
@ -165,6 +161,11 @@ update() {
|
||||||
$HOME/.tmux/plugins/tpm/bin/update_plugins all
|
$HOME/.tmux/plugins/tpm/bin/update_plugins all
|
||||||
}
|
}
|
||||||
|
|
||||||
|
{%@@ if profile == "Moria" @@%}
|
||||||
|
repo() {
|
||||||
|
aur sync -Su --margs --noconfirm
|
||||||
|
}
|
||||||
|
|
||||||
docker-update() {
|
docker-update() {
|
||||||
for dir in $HOME/git/dotfiles/docker/*; do
|
for dir in $HOME/git/dotfiles/docker/*; do
|
||||||
cd $dir
|
cd $dir
|
||||||
|
@ -179,13 +180,12 @@ update() {
|
||||||
docker system prune -af --volumes
|
docker system prune -af --volumes
|
||||||
}
|
}
|
||||||
|
|
||||||
apt() {
|
{%@@ endif @@%}
|
||||||
|
{%@@ if profile == "mko-laptop" @@%}
|
||||||
|
apt-upd() {
|
||||||
sudo apt update && sudo apt full-upgrade -y && sudo apt autoremove -y && sudo apt autoclean -y
|
sudo apt update && sudo apt full-upgrade -y && sudo apt autoremove -y && sudo apt autoclean -y
|
||||||
}
|
}
|
||||||
|
{%@@ endif @@%}
|
||||||
if [ $# -eq 0 ]; then
|
|
||||||
1=all
|
|
||||||
fi
|
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
all)
|
all)
|
||||||
|
@ -204,18 +204,20 @@ update() {
|
||||||
{%@@ endif @@%}
|
{%@@ endif @@%}
|
||||||
{%@@ if profile == "mko-laptop" @@%}
|
{%@@ if profile == "mko-laptop" @@%}
|
||||||
apt)
|
apt)
|
||||||
apt
|
apt-upd
|
||||||
;;
|
;;
|
||||||
{%@@ endif @@%}
|
{%@@ endif @@%}
|
||||||
*)
|
*)
|
||||||
all
|
{%@@ if profile == "mko-laptop" @@%}
|
||||||
|
apt-upd
|
||||||
;;
|
;;
|
||||||
|
{%@@ else @@%}
|
||||||
|
paru
|
||||||
|
;;
|
||||||
|
{%@@ endif @@%}
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
|
|
||||||
# remove unneeded packages
|
|
||||||
autoremove() { sudo pacman -Rns $(pacman -Qdtq) }
|
|
||||||
|
|
||||||
# turn on usb tethering on my android phone
|
# turn on usb tethering on my android phone
|
||||||
tether() { adb shell su -c "service call connectivity 33 i32 1 s16 me" > /dev/null }
|
tether() { adb shell su -c "service call connectivity 33 i32 1 s16 me" > /dev/null }
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue