Skip to content

Instantly share code, notes, and snippets.

@baskerville
Created February 7, 2012 11:40
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save baskerville/1759288 to your computer and use it in GitHub Desktop.
dwb-hg PKGBUILD Cleanup Patch
--- PKGBUILD 2012-02-06 12:48:15.000000000 +0100
+++ PKGBUILD_OK 2012-02-07 12:30:48.804453842 +0100
@@ -17,19 +17,20 @@
build() {
cd "$srcdir"
- if [ -d "${hgrepo}" ]; then
- cd $hgrepo
+ if [ -d "$hgrepo" ]; then
+ cd "$hgrepo"
hg pull -u || test $? -eq 255 && return 1
else
- hg clone "$hgroot/$hgrepo"
+ hg clone "${hgroot}/${hgrepo}"
fi
- rm -rf $srcdir/$_hgrepo-build
- cp -a ${srcdir}/${hgrepo} ${srcdir}/${hgrepo}-build
- cd ${srcdir}/${hgrepo}-build
+ rm -rf "${srcdir}/${hgrepo}-build"
+ cp -a "${srcdir}/${hgrepo}" "${srcdir}/${hgrepo}-build"
+ cd "${srcdir}/${hgrepo}-build"
make
}
+
package() {
- cd ${srcdir}/${hgrepo}-build
- make DESTDIR=${pkgdir} install
+ cd "${srcdir}/${hgrepo}-build"
+ make DESTDIR="${pkgdir}" install
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment