Skip to content

Instantly share code, notes, and snippets.

@sxiii
Created January 25, 2019 19:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sxiii/c4f2b6332c9714e54bab2f2ed0e745a1 to your computer and use it in GitHub Desktop.
Save sxiii/c4f2b6332c9714e54bab2f2ed0e745a1 to your computer and use it in GitHub Desktop.
In case you break ArchLinux / Manjaro installation, that's how to download and install broken packages from the list
#!/bin/bash
# REQUIREMENTS: kittypack (search on github)
# This small script downloads all packages which names are shown in packagenames.txt (separated by spaces)
for item in $(cat packagenames.txt); do
echo "Item: $item"
repo=$(kittypack --format %r $item)
echo "Repo: $repo"
wget https://www.archlinux.org/packages/$repo/x86_64/$item/download/ -O $item.pkg.tar.xz
done
#!/bin/bash
# This small script installs all downloaded packages:
for name in $(ls *tar.xz); do
sudo pacman -U $name
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment