summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 52a65416c743114991ded5785ab3944342d4a881 (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
# Maintainer:  dacoit <dacoit at tuta.io>
pkgname=tutanota
pkgver=2.3.1
pkgrel=1
pkgdesc='Tutanota end-to-end encrypted email client webapp'
url='https://tutanota.de'
arch=('any')
license=('GPL3')
makedepends=('npm' 'gulp')
source=("https://github.com/tutao/tutanota/archive/tutanota-release-$pkgver.tar.gz")
md5sums=('319083759e7d1a38a4984845e6376bd4')

# Set to any value to install a symlink 
# from the document root to the webapp
_doc_root_symlink=
_doc_root="/srv/http"

build() {
  cd "$pkgname-$pkgname-release-$pkgver/web"
  npm install
  gulp dist
}

package() {
  mkdir -p "$pkgdir/usr/share/webapps"
  cp -a "$pkgname-$pkgname-release-$pkgver/web/build" "$pkgdir/usr/share/webapps/$pkgname"
  if [ -n "$_doc_root_symlink" ]; then
      mkdir -p "$pkgdir/$_doc_root"
      ln -s "/usr/share/webapps/$pkgname" "$pkgdir/$_doc_root/$pkgname"
  fi
}