updated on Sun Jan 15 16:02:00 UTC 2012
[aur-mirror.git] / pastebin-cli-git / PKGBUILD
blob4ddd111cbf709a8b392be3f9b83e032f302bfe28
1 # Contributor: Sychopx <infinity.illusion@gmail.com>
3 pkgname=pastebin-cli-git
4 pkgver=20110218
5 pkgrel=1
6 pkgdesc="Command line tool for pasting to pastebin"
7 arch=('i686' 'x86_64')
8 url="http://zhehaomao.com/software/pastebin-cli/"
9 license=('BSD')
10 depends=('curl')
11 makedepends=('git')
12 provides=('pastebin')
14 _gitroot="git://github.com/zhemao/pastebin-cli.git"
15 _gitname="pastebin-cli"
17 build() {
18         cd ${srcdir}
19         msg "Connecting to GIT server...."
21         if [ -d ${_gitname} ] ; then
22                 cd ${_gitname} && git pull origin
23                 msg "The local files are updated."
24         else
25                 git clone ${_gitroot}
26         fi
28         msg "GIT checkout done or server timeout"
29         msg "Starting make..."
31         rm -rf ${srcdir}/${_gitname}-build
32         git clone ${srcdir}/${_gitname} ${srcdir}/${_gitname}-build
33         cd ${srcdir}/${_gitname}-build
34         
35         make DESTDIR=$pkgdir || return 1
36   
37         install -D -m755 pastebin ${pkgdir}/usr/bin/pastebin || return 1
38