Damien Lespiau f7fcba659c travis: Support building pushed branches
This commit refactors travisBuild.sh to support building pushed branched on top
of PRs and tags.

This was prompted by enabling travis on a forked repository. The devlopment
flow then becomes:
  - Fork google/go-jsonnet
  - Enable travis on fork repository
  - Push branch to forked repository
  - Travis runs on the pushed branch
  - Submit pull request once happy and tests pass in the forked repository

I tested 3 scenarii and they seem behave nicely:
  - Running CI for pushed branch
  - Running CI for tag
  - Running CI for a Pull Request

As a side note, the previous error path didn't work as intented:
  - The TRAVIS_PULL variable didn't exist
  - We weren't exiting with a non 0 value in the else branch, so the build
    succeeded instead of failing when travisBuild.sh didn't know what to do
    with the pushed branch
2018-09-24 10:47:07 -04:00
2017-09-28 22:21:46 -04:00
2018-04-12 14:06:52 -04:00
2018-01-15 21:05:52 -05:00
2018-06-22 14:14:14 -04:00
2017-09-29 12:36:04 -04:00
2018-04-28 01:34:42 -04:00
2018-06-22 14:14:14 -04:00
2018-07-18 20:25:08 -04:00
2017-10-10 00:06:14 -04:00
2018-07-19 16:09:27 -04:00

go-jsonnet

GoDoc Widget Travis Widget Coverage Status Widget

This an implementation of Jsonnet in pure Go. It is feature complete but is not as heavily exercised as the Jsonnet C++ implementation. Please try it out and give feedback.

This code is known to work on Go 1.8 and above. We recommend always using the newest stable release of Go.

Build instructions

export GOPATH=$HOME/go-workspace
mkdir -pv $GOPATH
go get github.com/google/go-jsonnet
cd $GOPATH/src/github.com/google/go-jsonnet
cd jsonnet
go build
./jsonnet /dev/stdin <<< '{x: 1, y: self.x} + {x: 10}'
{
   "x": 10,
   "y": 10
}

Running tests

./tests.sh  # Also runs `go test ./...`

Implementation Notes

We are generating some helper classes on types by using http://clipperhouse.github.io/gen/. Do the following to regenerate these if necessary:

go get github.com/clipperhouse/gen
go get github.com/clipperhouse/set
export PATH=$PATH:$GOPATH/bin  # If you haven't already
go generate

Generated Stdlib

To regenerate the standard library, do:

./reset_stdast_go.sh && go run cmd/dumpstdlibast.go
Description
No description provided
Readme Apache-2.0 24 MiB
Languages
Go 98.4%
Jsonnet 0.7%
Python 0.3%
C 0.3%
Starlark 0.2%