diff --git a/cmd/mothd/main.go b/cmd/mothd/main.go index b377526..2ffb1d1 100644 --- a/cmd/mothd/main.go +++ b/cmd/mothd/main.go @@ -1,7 +1,7 @@ package main import ( - "github.com/namsral/flag" + "flag" "github.com/spf13/afero" "log" "mime" @@ -47,7 +47,7 @@ func main() { ) bindStr := flag.String( "bind", - ":8000", + ":8080", "Bind [host]:port for HTTP service", ) base := flag.String( @@ -55,6 +55,7 @@ func main() { "/", "Base URL of this instance", ) + flag.Parse() theme := NewTheme(afero.NewBasePathFs(afero.NewOsFs(), *themePath)) state := NewState(afero.NewBasePathFs(afero.NewOsFs(), *statePath)) diff --git a/cmd/mothd/theme.go b/cmd/mothd/theme.go index afb7e7e..c1d728b 100644 --- a/cmd/mothd/theme.go +++ b/cmd/mothd/theme.go @@ -3,6 +3,7 @@ package main import ( "github.com/spf13/afero" "time" + "log" ) type Theme struct { @@ -17,6 +18,7 @@ func NewTheme(fs afero.Fs) *Theme { // I don't understand why I need this. The type checking system is weird here. func (t *Theme) Open(name string) (ReadSeekCloser, error) { + log.Println(name) return t.Fs.Open(name) }