Documentation ¶
Overview ¶
SPDX-License-Identifier: BSD-3-Clause Copyright (c) 2022, Unikraft GmbH and The KraftKit Authors. Licensed under the BSD-3-Clause License (the "License"). You may not use this file except in compliance with the License.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CliOption ¶
type CliOption func(*CliOptions) error
func WithDefaultConfigManager ¶
WithDefaultConfigManager instantiates a configuration manager based on default options.
func WithDefaultHTTPClient ¶
func WithDefaultHTTPClient() CliOption
WithDefaultHTTPClient initializes a HTTP client using host-provided configuration.
func WithDefaultIOStreams ¶
func WithDefaultIOStreams() CliOption
WithDefaultIOStreams instantiates ta new IO streams using environmental variables and host-provided configuration.
func WithDefaultLogger ¶
func WithDefaultLogger() CliOption
WithDefaultLogger sets up the built in logger based on provided conifg found from the ConfigManager.
func WithDefaultPluginManager ¶
func WithDefaultPluginManager() CliOption
WithDefaultPluginManager returns an initialized plugin manager using the host-provided configuration plugin path.
func WithHTTPClient ¶
WithHTTPClient sets a previously instantiated http.Client to be used within the command.
type CliOptions ¶
type CliOptions struct { IOStreams *iostreams.IOStreams Logger *logrus.Logger ConfigManager *config.ConfigManager[config.KraftKit] PackageManager packmanager.PackageManager PluginManager *plugins.PluginManager HTTPClient *http.Client }