dotfiles/bin/create-pacman-pkglist.sh
foo-dogsquared 687ca4359f Move the scripts to 'bin' directory
Just a change of preference.
2019-12-21 23:59:25 +08:00

16 lines
264 B
Bash

#!/bin/sh
# Simply creates a package list at $HOME as `pkglist.txt`
pkglist=$(pacman -Qqne)
pkglist_filepath="$HOME/pkglist.txt"
if [[ -f $pkglist_filepath ]]; then
rm "$pkglist_filepath"
fi
touch $pkglist_filepath
echo "$pkglist" >> $pkglist_filepath