1
0
mirror of https://github.com/moparisthebest/pacman synced 2024-11-13 21:05:05 -05:00
pacman/scripts/aurbuild
Aaron Griffin 74e347f09b * modeline fixes / reformatting
* formatting / indentation fixes
* makepkg:
    Dan McGee <dpmcgee@gmail.com> - integrity check fix
    Jürgen Hötzel <juergen@hoetzel.info> - EUID usage and "x$foo" check revamp
2006-12-21 01:53:40 +00:00

26 lines
538 B
Bash
Executable File

#!/bin/bash
die() {
echo $*
exit 1
}
if [ "$1" == "" ]; then
echo "usage: aurbuild <package_name>"
echo
exit 1
fi
pkgname=$1
[ -d $pkgname ] && die "Directory '$pkgname' already exists"
[ -f $pkgname ] && die "File '$pkgname' already exists"
echo "Downloading $pkgname.tar.gz"
wget -q http://aur.archlinux.org/packages/$pkgname/$pkgname.tar.gz || die "Failed to fetch $1.pkg.tar.gz"
tar zxf $pkgname.tar.gz || die "Extraction failed"
rm -f $pkgname.tar.gz
cd $pkgname || die "Failed to cwd"
makepkg
# vim: set ts=2 sw=2 noet: