diff --git a/.travis.yml b/.travis.yml index e8ce4b827..fa30a20c6 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,7 @@ language: go go: - - 1.3 - - tip + - 1.4 before_install: - "export DISPLAY=:99.0" @@ -12,6 +11,15 @@ before_install: - sudo apt-get update -qq - sudo apt-get install -qq libglew-dev libglfw3-dev +install: + - go get -t -v ./... + - go get github.com/gopherjs/gopherjs + - go get github.com/gopherjs/webgl + +script: + - go test -v ./... + - gopherjs build -v github.com/hajimehoshi/ebiten/example/blocks + notifications: email: recipients: diff --git a/_docs/index.tmpl.html b/_docs/index.tmpl.html index 1f6c9b3c4..de7cbd4ba 100644 --- a/_docs/index.tmpl.html +++ b/_docs/index.tmpl.html @@ -67,9 +67,10 @@ table.examples iframe {
:; brew install glew
:; brew install glfw3 # or homebrew/versions/glfw3
-:; go get -u github.com/hajimehoshi/ebiten
-If you want to use GopherJS, execute this:
-:; go get -u -tag=js github.com/hajimehoshi/ebiten
+:; go get github.com/hajimehoshi/ebiten
+If you want to run your game on a web browser, execute this:
+:; go get github.com/gopherjs/gopherjs
+:; go get github.com/gopherjs/webgl
:; cd $GOHOME/src/github.com/hajimehoshi/ebiten/example
@@ -77,16 +78,14 @@ table.examples iframe {
Execute the example on a web browser
If you can the example screens above, Ebiten is working on your browser! Each example above works as an independent html in an iframe. If you want to execute the examples apart from this site, execute this:
-:; go get github.com/gopherjs/gopherjs
-:; go run $GOPATH/src/github.com/hajimehoshi/ebiten/example/server/main.go
+:; go run $GOPATH/src/github.com/hajimehoshi/ebiten/example/server/main.go
Then, open localhost:8000
on your browser.
localhost:8000/?EXAMPLE_NAME
shows other examples (e.g. localhost:8000/?rotate
).
Of cource, you can execute gopherjs yourself. Please see GopherJS site for more detail.
Run your game on a web browser
Compile your game with GopherJS:
-:; go get github.com/gopherjs/gopherjs
-:; gopherjs build -o yourgame.js path/to/yourgame
+:; gopherjs build -o yourgame.js path/to/yourgame
Then, open the below HTML on your HTTP server:
<!DOCTYPE html>
<script src="yourgame.js"></script>
diff --git a/_docs/public/index.html b/_docs/public/index.html
index c653f0d86..b890ac240 100644
--- a/_docs/public/index.html
+++ b/_docs/public/index.html
@@ -308,9 +308,10 @@ func main() {
Install on Mac OS X
:; brew install glew
:; brew install glfw3 # or homebrew/versions/glfw3
-:; go get -u github.com/hajimehoshi/ebiten
-If you want to use GopherJS, execute this:
-:; go get -u -tag=js github.com/hajimehoshi/ebiten
+:; go get github.com/hajimehoshi/ebiten
+If you want to run your game on a web browser, execute this:
+:; go get github.com/gopherjs/gopherjs
+:; go get github.com/gopherjs/webgl
:; cd $GOHOME/src/github.com/hajimehoshi/ebiten/example
@@ -318,16 +319,14 @@ func main() {
Execute the example on a web browser
If you can the example screens above, Ebiten is working on your browser! Each example above works as an independent html in an iframe. If you want to execute the examples apart from this site, execute this:
-:; go get github.com/gopherjs/gopherjs
-:; go run $GOPATH/src/github.com/hajimehoshi/ebiten/example/server/main.go
+:; go run $GOPATH/src/github.com/hajimehoshi/ebiten/example/server/main.go
Then, open localhost:8000
on your browser.
localhost:8000/?EXAMPLE_NAME
shows other examples (e.g. localhost:8000/?rotate
).
Of cource, you can execute gopherjs yourself. Please see GopherJS site for more detail.
Run your game on a web browser
Compile your game with GopherJS:
-:; go get github.com/gopherjs/gopherjs
-:; gopherjs build -o yourgame.js path/to/yourgame
+:; gopherjs build -o yourgame.js path/to/yourgame
Then, open the below HTML on your HTTP server:
<!DOCTYPE html>
<script src="yourgame.js"></script>