Skip to content

Commit

Permalink
Default to looking for config in working directory
Browse files Browse the repository at this point in the history
  • Loading branch information
CameronNemo authored and kelindar committed Apr 18, 2019
1 parent 3b28d24 commit 1fe33d9
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions main.go
Expand Up @@ -5,7 +5,6 @@ import (
"flag"
"fmt"
"os"
"path/filepath"

"github.com/emitter-io/config/dynamo"
"github.com/emitter-io/config/vault"
Expand All @@ -16,14 +15,8 @@ import (
)

func main() {
// Get the directory of the process
exe, err := os.Executable()
if err != nil {
panic(err.Error())
}

// Process command-line arguments
argConfig := flag.String("config", filepath.Join(filepath.Dir(exe), "emitter.conf"), "The configuration file to use for the broker.")
argConfig := flag.String("config", "emitter.conf", "The configuration file to use for the broker.")
argHelp := flag.Bool("help", false, "Shows the help and usage instead of running the broker.")
flag.Parse()
if *argHelp {
Expand Down

0 comments on commit 1fe33d9

Please sign in to comment.