Categories
BLOG

bingo on the go

Bingo: What are 1 to go/2 to go Games?

xTG, refers to the position of your ticket in a bingo game, i.e. 1TG – one number to go, 2TG – 2 numbers, etc.

To reward our players who are close to winning, some of our games will be scheduled with one of 3 types of new xTG feature, either:

  • 1 To Go. or.
  • 2 To Go. or.
  • Both 1 and 2 To Go. if you have either 1 or 2 to go on a ticket.

These special games will have a specific prize payout for players who achieve the xTG criterion on their tickets ONLY when playing for the last prize in the game.

Please see section “Prize Options” below.

xTG games can each be configured differently.

They may pay an xTG prize.

  • Per Player – e.g. you get one prize if you have at least one of your tickets matching the xTG feature applied to the game.
  • Per Ticket – e.g. you get one prize for every ticket which matches the xTG criteria.

Prizes may also be a share of an xTG Feature Pot or a fixed amount, e.g. £0.10p per qualification.

Prizes may be paid to your Bingo or Cash Balance.

Please see section “Before a Game Starts” below to find out how you know what xTG prize options applied to a game.

Before a Game Starts

Before an xTG game starts, a blind will show that the xTG game is about to start. It will detail the prize options for the game.

If an xTG game precedes another xTG game, and they have exactly the same prize options, the blind will only show once before the first game.

Bingo: What are 1 to go/2 to go Games? xTG, refers to the position of your ticket in a bingo game, i.e. 1TG – one number to go, 2TG – 2 numbers, etc. To reward our players who are close to

Bingo on the go

go get like, simple CLI that allows automated versioning of Go package level binaries (e.g required as dev tools by your project!) built on top of Go Modules, allowing reproducible dev environments.

From our experience all repositories and projects require some tools and binaries to be present on the machine to be able to perform various development operations like building, formatting, releasing or static analysis. For smooth development all such tools should be pinned to a certain version and bounded to the code commits there were meant to be used against.

Go modules does not aim to solve this problem, and even if they will do at some point it will not be on the package level, which makes it impossible to e.g pin minor version X.Y.0 of package module1/cmd/abc and version X.Z.0 of module1/cmd/def .

At the end bingo , has following features:

  • It allows maintaining separate, hidden, nested Go modules for Go buildable packages you need without obfuscating your own module or worrying with tool’s cross dependencies!
  • Package level versioning, which allows versioning different (or the same!) package multiple times from a single module in different versions.
  • Works also for non-Go projects. It only requires the tools to be written in Go.
  • No need to install bingo in order to use pinned tools. This avoids the chicken & egg problem. Only go build required.
  • Easy upgrade, downgrade, addition, or removal of the needed binary’s version, with no risk of dependency conflicts.
    • NOTE: Tools are often not following semantic versioning, so bingo allows to pin by the commit.
  • Immutable binary names, which gives a reliable way for users and CIs to use the expected version of the binaries, with reinstall on-demand only if needed.
  • Optional, automatic integration with Makefiles.

You can read full a story behind bingo in this blog post.

  • Go 1.14+
  • Linux or MacOS (Want Windows support? Helps us out, should be trivial!)
  • All tools that you wish to “pin” have to be built in Go (they don’t need to use Go modules at all).

or if you already installed bingo and want to pin it (inception!):

The key idea is that you can manage your tools similar to your Go dependencies via go get :

Once pinned, anyone can reliably install correct version of the tool by either doing:

bingo allows to easily maintain a separate, nested Go Module for each binary. By default, it will keep it .bingo/ .mod This allows to correctly pin the binary without polluting the main go module or other’s tool module.

Also, make sure to check out the generated .bingo/Variables.mk if your project uses Makefile . It has useful helper variables 💖 that makes it super easy to install pinned binaries without even installing bingo (it will use just go build !). For shell users, you can invoke source .bingo/variables.env to source those variables.

See an extensive and up-to-date description of the bingo usage below:

Let’s show a few examples on popular goimports tool (which formats Go code including imports):

Pinning latest goimports :

This will install (at the time of writing) binary: $/goimports-v0.0.0-20200601175630-2caf76543d99

After running above, pinning (or downgrading/upgrading) version:

This will pin to that commit and install $/goimports-v0.0.0-20200519204825-e64124511800

Installing (and pinning) multiple versions:

This will pin and install three versions of goimports. Very useful to compatibility testing.

Unpinning goimports totally from the project:

PS: go get allows that, did you know? I didn’t (:

Editing .mod file manually. You can totally go to .bingo/goimports.mod and edit the version manually. Just make sure to bingo get goimports to install that version!

Installing all tools:

Bonus: Makefile mode! If you use Makefile , bingo generates a very simple helper with nice variables. After running any bingo get command, you will notice .bingo/Variables.mk file. Feel free to include this in your Makefile ( include .bingo/Variables.mk on the top of your Makefile).

From now in your Makefile you can use, e.g. $(GOIMPORTS) variable which reliably ensures a correct version is used and installed.

Bonus number 2! Using immutable names might be hard to maintain for your other scripts so bingo also produces environment variables you can source to you shell. It’s as easy as:

From now on you can use, e.g. $(GOIMPORTS) variable which holds currently pinned binary name of the goimports tool.

To see production example see:

Any contributions are welcome! Just use GitHub Issues and Pull Requests as usual. We follow Thanos Go coding style guide.

@bwplotka inspired by Paul’s research and with a bit of help from Duco (:

About

Like `go get` but for Go tools! CI Automating versioning of Go binaries in a nested, isolated Go modules.

Like `go get` but for Go tools! CI Automating versioning of Go binaries in a nested, isolated Go modules. – bwplotka/bingo ]]>