2
0
mirror of https://github.com/jmespath/jp synced 2025-08-22 09:37:10 +00:00
jp/scripts/build-self-contained
2015-12-04 17:19:09 -08:00

13 lines
357 B
Bash
Executable File

#!/bin/bash
# This is a self contained shell script for building jp without having to set
# up GOPATH. You just need go installed.
tempdir="$(mktemp -d -t jpbuild)"
tempgopath="$tempdir/go"
jppath="${tempgopath}/src/github.com/jmespath"
fakerepo="$jppath/jp"
mkdir -p $jppath
ln -s "$(pwd)" "$jppath/jp"
export GOPATH="$tempgopath"
cd "$fakerepo"
go build