Skip to content
/ cmg Public

Small CLI (or web) tool for generating fair and balanced Catan board layouts

License

Notifications You must be signed in to change notification settings

joostvdg/cmg

Repository files navigation

Catan Map Generator (CMG)

App for generating Catan maps which are fair and balanced.

Badges

license GitHub release GitHub Action Heroku

Codacy Badge Go Report Card gopherbadger-tag-do-not-edit DepShield Badge

Live version

The application is running as a free heroku app to try: https://catan-map-generator.herokuapp.com/api/map.

Look for the Code to see the API for for more commands (or the shell scripts such as 6p-game.sh).

The UI is available at https://catan-ui.herokuapp.com//.

Run as Google Cloud Function

See the wrapper project github.com/joostvdg/cmg-gcf for running it as a Cloud Function.

Run on Heroku

  • get Heroku CLI: brew tap heroku/brew && brew install heroku
  • create app with Heroku: heroku create
  • configure go.mod file (see below)
  • publish to Heroku app: git push heroku master

Go.mod

When using Go 1.11+, just use gomod for managing deps, don't use the others tools unless you have a good reason.

When using gomod, you have to add some annotations for Heroku to your go.mod file. Docs state it defaults to building ., it seemed it was ./cmd/. which was not correct for me.

Probably best to state it explicitly.

// +heroku goVersion go1.11
// +heroku install .

For more info, read Heroku's docs on Go.