Files
guz.one/cmd/build/main.go
Gustavo "Guz" L. de Mello 69e24e9330 refactor: rename module
2024-05-23 10:44:57 -03:00

29 lines
484 B
Go

package main
import (
"context"
"flag"
"log"
"www/config"
"www/internals"
)
func main() {
dir := flag.String("d", "./dist", "the directory to write the files")
staticDir := flag.String("s", "./static", "the directory to copy static files from")
w := internals.StaticWriter{
DistDir: dir,
StaticDir: staticDir,
Pages: config.ROUTES,
Context: context.Background(),
Logger: *log.Default(),
}
err := w.WriteAll()
if err != nil {
log.Fatal(err)
}
}