summaryrefslogtreecommitdiffstats
path: root/matterbridge.go
diff options
context:
space:
mode:
authorWim <wim@42.be>2015-12-18 20:54:28 +0100
committerWim <wim@42.be>2015-12-18 20:54:28 +0100
commitf0a5d2396fd7307fefd883d4f794e7def003af45 (patch)
tree9c1e8ca3a801a1fb4bff8b62959172c8a7d6cfbc /matterbridge.go
parentbdac03f725858fad0f55cd56fc5d72ac07073d79 (diff)
downloadmatterbridge-msglm-f0a5d2396fd7307fefd883d4f794e7def003af45.tar.gz
matterbridge-msglm-f0a5d2396fd7307fefd883d4f794e7def003af45.tar.bz2
matterbridge-msglm-f0a5d2396fd7307fefd883d4f794e7def003af45.zip
Add option to specify configfile
Diffstat (limited to 'matterbridge.go')
-rw-r--r--matterbridge.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/matterbridge.go b/matterbridge.go
index bd324608..80e97b35 100644
--- a/matterbridge.go
+++ b/matterbridge.go
@@ -2,6 +2,7 @@ package main
import (
"crypto/tls"
+ "flag"
"github.com/42wim/matterbridge/matterhook"
"github.com/peterhellberg/giphy"
"github.com/thoj/go-ircevent"
@@ -116,6 +117,8 @@ func (b *Bridge) giphyRandom(query []string) string {
}
func main() {
- NewBridge("matterbot", NewConfig("matterbridge.conf"))
+ flagConfig := flag.String("conf", "matterbridge.conf", "config file")
+ flag.Parse()
+ NewBridge("matterbot", NewConfig(*flagConfig))
select {}
}