Mercurial > gemma
view Makefile @ 2741:87aed4f9b1b8
Added calculation of Nash Sutcliffe efficiency coefficents.
GET /api/data/nash-sutcliffe/{gauge}?when={WHEN}
'when' is optional in form of "2006-01-02T15:04:05.000" and defaults to
current server time.
curl -H "X-Gemma-Auth:$KEY" http://${server}:${port}/api/data/nash-sutcliffe/${gauge} | jq .
{
"when": "2019-03-20T10:38:05.687",
"coeffs": [
{
"value": 0,
"samples": 0,
"hours": 24
},
{
"value": 0,
"samples": 0,
"hours": 48
},
{
"value": 0,
"samples": 0,
"hours": 72
}
]
}
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Wed, 20 Mar 2019 10:47:01 +0100 |
parents | 77202406b1a7 |
children | f7a32b0b9235 |
line wrap: on
line source
# Simple Makefile to build all of Gemma # # Authors: Sascha Wilde <wilde@intevation.de> basedir := $(dir $(realpath $(firstword $(MAKEFILE_LIST)))) BUILDBASE := $(basedir).buildbase GOPATH := $(BUILDBASE)/go GOCACHE := $(BUILDBASE)/gocache ENVWARPPER := $(BUILDBASE)/run-with-env.sh BINDIR := /usr/local/bin export BUILDBASE 3rdpartylibs-stamp := $(BUILDBASE)/3rdpartylibs-build .PHONY: all 3rdpartylibs gemma client clean all: gemma client $(ENVWARPPER): @echo "Preparing go build environment:" mkdir -p "$(GOCACHE)" mkdir -p "$(GOPATH)/src/gemma.intevation.de" [ -e "$(GOPATH)/src/gemma.intevation.de/gemma" ] || \ ln -s "$(basedir)" "$(GOPATH)/src/gemma.intevation.de/gemma" @echo "Creating wrapper script:" echo '#!/bin/sh' >"$(ENVWARPPER)" echo 'export GOPATH=$(GOPATH)' >>"$(ENVWARPPER)" echo 'export GOCACHE=$(GOCACHE)' >>"$(ENVWARPPER)" echo 'exec "$$@"' >>"$(ENVWARPPER)" chmod +x "$(ENVWARPPER)" $(3rdpartylibs-stamp): $(ENVWARPPER) 3rdpartylibs.sh "$(ENVWARPPER)" bash ./3rdpartylibs.sh && \ touch $@ 3rdpartylibs: $(3rdpartylibs-stamp) gemma: $(3rdpartylibs-stamp) $(ENVWARPPER) cd cmd/gemma && "$(ENVWARPPER)" go build client: $(MAKE) -f Makefile.build -C client install: gemma cp cmd/gemma/gemma $(BINDIR) tar: all v="gemma-$$(hg id -i)" ;\ tar --transform "s@^@$${v}/@" \ -cJf "../$${v}.tar.xz" \ cmd/gemma/gemma schema web example_conf.toml clean: $(MAKE) -f Makefile.build -C client $@ rm -f "$(gemma-bin)" rm -rf "$(BUILDBASE)"