gspot/main.go
abs3nt 86c2c38dfe
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/tag/woodpecker Pipeline was successful
log settings
2024-02-18 22:17:28 -08:00

33 lines
611 B
Go

package main
import (
"gfx.cafe/util/go/fxplus"
"go.uber.org/fx"
"git.asdf.cafe/abs3nt/gspot/src/components/cache"
"git.asdf.cafe/abs3nt/gspot/src/components/cli"
"git.asdf.cafe/abs3nt/gspot/src/components/commands"
"git.asdf.cafe/abs3nt/gspot/src/components/logger"
"git.asdf.cafe/abs3nt/gspot/src/services"
)
func main() {
var s fx.Shutdowner
app := fx.New(
fxplus.WithLogger,
fx.Populate(&s),
services.Config,
fx.Provide(
fxplus.Context,
cache.NewCache,
commands.NewCommander,
services.NewSpotifyClient,
logger.NewLogger,
),
fx.Invoke(
cli.Run,
),
)
app.Run()
}