pages-server/main.go

22 lines
359 B
Go
Raw Normal View History

package main
import (
"os"
_ "github.com/joho/godotenv/autoload"
"github.com/rs/zerolog/log"
2021-12-05 13:45:17 +00:00
"codeberg.org/codeberg/pages/cli"
"codeberg.org/codeberg/pages/server"
)
func main() {
app := cli.CreatePagesApp()
app.Action = server.Serve
2021-12-03 01:12:51 +00:00
if err := app.Run(os.Args); err != nil {
log.Error().Err(err).Msg("A fatal error occurred")
2021-12-03 01:12:51 +00:00
os.Exit(1)
}
}