Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # check if pacsrv installed and set it as our installer
- if [ -a /usr/bin/pacsrv ]; then
- export installer=pacsrv
- else
- export installer=pacman
- fi
- # use pacman to do a full system update
- function update {
- sudo $installer -Syu
- sudo /storage/Launchers/updateCount # update our count of available packages
- checkUpdates | head -n 1
- }
- function aur {
- git clone https://aur.archlinux.org/"$1".git
- }
- function mkpkg {
- makepkg -s "$@"
- if [ "$?" = 0 ]; then
- mv *.pkg.tar.xz ..
- cd ..
- fi
- }
- # use pacman to install compiled packages and update our number of available updates
- function install {
- # check if we're supplied anything
- if [ -n "$1" ]; then
- # install specific packages
- echo installing "$@"
- sudo $installer -U "$@"
- else
- # install all packages in current working directory
- echo installing all packages
- echo Package list:
- l *.pkg.tar.xz
- sudo $installer -U *.pkg.tar.xz
- fi
- if [ "$?" = 0 ]; then
- cd ..
- fi
- sudo /storage/Launchers/updateCount # update our count of available packages
- checkUpdates | head -n 1
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement