wombat/gallery/new.go

22 lines
362 B
Go
Raw Normal View History

2019-01-01 19:41:03 +01:00
package gallery
import (
finstr "git.gutmet.org/finstr.git/initer"
"git.gutmet.org/goutil.git"
)
func New(name string) error {
fl := finstr.IniterFlags{}
fl.Dir = "photos" + name
fl.Markdown = true
return finstr.Init(fl)
}
func NewInteractive() error {
name, err := goutil.AskFor("Name (one word)")
if err != nil {
return err
}
return New(name)
}