Files
opencloud/ocis/pkg/runtime/options.go
T
Jörn Friedrich Dreyer 8e028f17e9 change module name
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
2025-01-13 09:58:18 +01:00

31 lines
510 B
Go

package runtime
import (
"github.com/opencloud-eu/opencloud/ocis-pkg/log"
"github.com/urfave/cli/v2"
)
// Options is a runtime option
type Options struct {
Services []string
Logger log.Logger
Context *cli.Context
}
// Option undocumented
type Option func(o *Options)
// Services option
func Services(s []string) Option {
return func(o *Options) {
o.Services = append(o.Services, s...)
}
}
// Context option
func Context(c *cli.Context) Option {
return func(o *Options) {
o.Context = c
}
}