After the patch updates.sh becomes an order of magnitude faster while remaining reasonably KISS.
It also lets you flexibly ignore or not ignore specific pacman repositories.
A yet another order of magnitude speedup is possible by using join and functional bash-fu. it's self-contained - paste to bash to see it mimicking update.sh -b:
After the patch
updates.sh
becomes an order of magnitude faster while remaining reasonably KISS.It also lets you flexibly ignore or not ignore specific
pacman
repositories.A yet another order of magnitude speedup is possible by using
join
and functional bash-fu. it's self-contained - paste to bash to see it mimickingupdate.sh -b
:Note that
join
is designed to only operate on sorted data and thus this approach avoids quadratic algorithms entirely.But I'm not sure if it's KISS enough.