[arch-commits] Commit in grafana/trunk (PKGBUILD)

Sébastien Luttringer seblu at archlinux.org
Thu Mar 23 01:26:44 UTC 2017


    Date: Thursday, March 23, 2017 @ 01:26:43
  Author: seblu
Revision: 218429

upgpkg: grafana 4.1.2-1

Modified:
  grafana/trunk/PKGBUILD

----------+
 PKGBUILD |   26 ++++++++++++++------------
 1 file changed, 14 insertions(+), 12 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2017-03-22 21:56:08 UTC (rev 218428)
+++ PKGBUILD	2017-03-23 01:26:43 UTC (rev 218429)
@@ -4,7 +4,7 @@
 # Contributor: Gilles Hamel <hamelg at laposte dot net>
 
 pkgname=grafana
-pkgver=4.1.1
+pkgver=4.1.2
 pkgrel=1
 pkgdesc='Gorgeous metric viz, dashboards & editors for Graphite, InfluxDB & OpenTSDB'
 url='http://grafana.org'
@@ -11,7 +11,7 @@
 arch=('x86_64' 'i686')
 license=('Apache')
 depends=('glibc' 'freetype2' 'fontconfig')
-makedepends=('git' 'go' 'npm')
+makedepends=('git' 'go' 'npm' 'grunt-cli')
 backup=("etc/grafana.ini")
 source=("git+https://github.com/grafana/grafana.git#tag=v$pkgver"
         "grafana.service"
@@ -38,20 +38,22 @@
 }
 
 build() {
-  # $GOPATH tunning
-  export GOPATH="$srcdir"
-  export PATH="$PATH:$GOPATH/bin"
+  msg2 'GOPATH setup'
+  export GOPATH="$srcdir/gopath"
+  export PATH+=":$GOPATH/bin"
   mkdir -p "$GOPATH/src/github.com/grafana/"
-  ln -fsr "$srcdir/grafana/" "$GOPATH/src/github.com/grafana/grafana"
+  ln -fsrT "$srcdir/grafana/" "$GOPATH/src/github.com/grafana/grafana"
   cd "$GOPATH/src/github.com/grafana/grafana"
 
-  # building the backend
-  go run build.go setup
-  go run build.go build
+  msg2 'building the backend'
+  go run build.go setup build
 
-  # building the frontend
-  npm install
-  npm run build
+  msg2 'building the frontend'
+  export NPM_CONFIG_PREFIX="$srcdir/npm"
+  export PATH+=":$NPM_CONFIG_PREFIX/bin"
+  npm install -g yarn
+  yarn install --pure-lockfile
+  grunt release
 }
 
 package() {


More information about the arch-commits mailing list