blob: 9907934873ccaf9fdb38a9875ca65584e43f6914 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
#!/usr/bin/bash
# Upgrade system
sudo pacman -Syu
# Remove orphans
mapfile -t orphans < <(pacman -Qdttq)
if (( ${#orphans[@]} )); then
sudo pacman -Rns "${orphans[@]}"
fi
# Remove dropped packages
mapfile -t foreign < <(pacman -Qmq)
if (( ${#foreign[@]} )); then
mapfile -t dropped < \
<(expac '%n %p' "${foreign[@]}" | grep -v 'Justin Gassner' | cut -d' ' -f1)
if (( ${#dropped[@]} )); then
sudo pacman -Rns "${dropped[@]}"
fi
fi
# Manage .pac* files
sudo pacdiff
# Update nvim and mpv plugins
git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME submodule update --remote
|