summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 37599598c8314f0f0feb08b5c15f0bb0ea8f86b8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# Maintainer: Mike Swanson <mikeonthecomputer@gmail.com>

pkgname=emacs-nyan-mode
pkgver=20120517
pkgrel=1
pkgdesc="Nyan Cat in your Emacs modeline"
arch=('any')
url="http://github.com/TeMPOraL/nyan-mode/"
license=('GPL')
depends=('emacs')
makedepends=('git')
install=emacs-nyan-mode.install

_gitroot=git://github.com/TeMPOraL/nyan-mode.git
_gitname=nyan-mode

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 build..."

  cd "$srcdir/$_gitname"

  emacs -batch -f batch-byte-compile nyan-mode.el
}

package() {
  cd "$srcdir/$_gitname"
  install -d $pkgdir/usr/share/emacs/site-lisp
  cp -a $srcdir/$_gitname/*.el* $srcdir/$_gitname/img $pkgdir/usr/share/emacs/site-lisp
}

# vim:set ts=2 sw=2 et: