diff --git a/dev/devcam/server.go b/dev/devcam/server.go index 2c463671c..5bdc18f91 100644 --- a/dev/devcam/server.go +++ b/dev/devcam/server.go @@ -52,6 +52,8 @@ type serverCmd struct { noBuild bool fullClosure bool + + openBrowser bool // end of flag vars camliSrcRoot string // the camlistore source tree @@ -79,6 +81,8 @@ func init() { flags.BoolVar(&cmd.noBuild, "nobuild", false, "Do not rebuild anything.") flags.BoolVar(&cmd.fullClosure, "fullclosure", false, "Use the ondisk closure library.") + + flags.BoolVar(&cmd.openBrowser, "openbrowser", false, "Open the start page on startup.") return cmd }) } @@ -356,7 +360,8 @@ func (c *serverCmd) RunCommand(args []string) error { camliBin := filepath.Join(c.camliSrcRoot, "bin", "camlistored") cmdArgs := []string{ "-configfile=" + filepath.Join(c.camliSrcRoot, "config", "dev-server-config.json"), - "-listen=" + c.listen} + "-listen=" + c.listen, + "-openbrowser=" + strconv.FormatBool(c.openBrowser)} cmd := exec.Command(camliBin, cmdArgs...) cmd.Stdout = os.Stdout cmd.Stderr = os.Stderr