Skip to content
A simple Battlesnake AI written in Kotlin
Kotlin
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
gradle/wrapper
src
.gitignore
.travis.yml
CONTRIBUTING.md
LICENSE
Procfile
README.md
app.json
build.gradle
gradlew
gradlew.bat
settings.gradle
system.properties

README.md

starter-snake-kotlin

Build Status

A simple Battlesnake written in Kotlin.

Visit https://docs.battlesnake.io for API documentation and instructions for creating a game.

This snake is built using a lightweight http server Spark framework - http://sparkjava.com/documentation

Deploy

Requirements

Running the snake

Assign the mainName variable in build.gradle to the proper Snake classname.

Use ngrok to make a locally running snake visible to the BattleSnake server.

./gradlew run

The snake will start up on port 8080.

Run the tests

./gradlew test

Executable UberJar

Build the uberjar build/libs/starter-snake-kotlin.jar with:

./gradlew stage

Run the uberjar with:

java -jar build/libs/starter-snake-kotlin.jar

Deploying to Heroku

  1. Create a new Heroku app with:
heroku create [APP_NAME]
  1. Deploy code to Heroku with:
git push heroku master
  1. Open Heroku app in browser with:
heroku open

or visit http://APP_NAME.herokuapp.com.

  1. View server logs with the heroku logs command with:
heroku logs --tail
You can’t perform that action at this time.