Make the one error per line configurable.

master
Zed A. Shaw 2 weeks ago
parent 5d04b92884
commit 0e87dcf890
  1. 1
      .ttarpit.json
  2. 1
      config/settings.go
  3. 2
      game/engine.go

@ -1,6 +1,7 @@
{
"StartingHP": 10,
"Deadline": "1h30m0s",
"OneErrorPerLine": true,
"Includes": [
"^.*.go$"
],

@ -21,6 +21,7 @@ type Config struct {
Processes map[string]Process
StartingHP int
Deadline string
OneErrorPerLine bool
ConfigPath string

@ -50,7 +50,7 @@ func (game *Game) SeenError(errinfo data.ErrInfo) int {
}
func (game *Game) TakeHit(build *builder.Builder, errinfo data.ErrInfo) {
if game.SeenError(errinfo) > 1 {
if game.SeenError(errinfo) > 1 && game.settings.OneErrorPerLine {
return
}

Loading…
Cancel
Save