From b600ebdd5a92c07ebbbca4f2c4138297aaaa527a Mon Sep 17 00:00:00 2001 From: Cedric Girard Date: Mon, 23 Jun 2014 15:52:46 +0200 Subject: [PATCH] update ledmon PKGBUILD to "new" git standards --- pkgbuild/ledmon/PKGBUILD | 31 ++++++++++--------------------- 1 file changed, 10 insertions(+), 21 deletions(-) diff --git a/pkgbuild/ledmon/PKGBUILD b/pkgbuild/ledmon/PKGBUILD index 03bb8a4..85e93a8 100644 --- a/pkgbuild/ledmon/PKGBUILD +++ b/pkgbuild/ledmon/PKGBUILD @@ -1,6 +1,6 @@ # Maintainer: Cedric Girard pkgname=ledmon -pkgver=20110126 +pkgver=r6.d4b6a09 pkgrel=1 pkgdesc="Monitor your keyboard LED [C] (unmaintained)" arch=('i686' 'x86_64') @@ -9,32 +9,21 @@ license=('GPL') depends=('libx11') makedepends=('git') -_gitroot="https://github.com/jgoerzen/ledmon.git" -_gitname="ledmon" +source=('ledmon::git+https://github.com/jgoerzen/ledmon.git') +md5sums=('SKIP') + +pkgver() { + cd "$srcdir"/ledmon + printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} build() { - cd "$srcdir" - msg "Connecting to GIT server...." - - if [ -d $_gitname ] ; then - cd $_gitname && git pull origin - msg "The local files are updated." - else - git clone $_gitroot $_gitname - fi - - msg "GIT checkout done or server timeout" - msg "Starting make..." - - rm -rf "$srcdir/$_gitname-build" - git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build" - cd "$srcdir/$_gitname-build" - + cd "$srcdir"/ledmon make } package() { - cd "$srcdir/$_gitname-build" + cd "$srcdir"/ledmon install -d "$pkgdir/usr/bin/" cp ledmon "$pkgdir/usr/bin/" }