Browse Source

Actually use the default and enable travisci service

kegan/travis
Kegan Dougal 8 years ago
parent
commit
1d23f6bd94
  1. 1
      src/github.com/matrix-org/go-neb/goneb.go
  2. 3
      src/github.com/matrix-org/go-neb/services/travisci/travisci.go

1
src/github.com/matrix-org/go-neb/goneb.go

@ -26,6 +26,7 @@ import (
_ "github.com/matrix-org/go-neb/services/guggy"
_ "github.com/matrix-org/go-neb/services/jira"
_ "github.com/matrix-org/go-neb/services/rssbot"
_ "github.com/matrix-org/go-neb/services/travisci"
"github.com/matrix-org/go-neb/types"
_ "github.com/mattn/go-sqlite3"
"github.com/prometheus/client_golang/prometheus"

3
src/github.com/matrix-org/go-neb/services/travisci/travisci.go

@ -152,6 +152,9 @@ func notifToTemplate(n webhookNotification) map[string]string {
}
func outputForTemplate(travisTmpl string, tmpl map[string]string) (out string) {
if travisTmpl == "" {
travisTmpl = DefaultTemplate
}
out = travisTmpl
for tmplVar, tmplValue := range tmpl {
out = strings.Replace(out, "%{"+tmplVar+"}", tmplValue, -1)

Loading…
Cancel
Save