init

package
v0.0.0-...-905e1c4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 7, 2026 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultDigestConfig

func DefaultDigestConfig() (*digest.Config, error)

func RunAIConfig

func RunAIConfig(
	ctx context.Context,
	cnf *config.Config,
	dg *digest.Digest,
	path string,
	opts *Options,
	stdout, stderr io.Writer,
) error

RunAIConfig runs the command to generate configuration for a project using AI.

Types

type Input

type Input struct {
	Digest       *digest.Digest
	ExtraContext string `json:"extra_context,omitempty"`

	OrganizationID string `json:"organization_id,omitempty"`
	ProjectID      string `json:"project_id,omitempty"`

	Debug bool `json:"debug,omitempty"`
}

Input represents input for the /ai/generate-configuration API.

type Options

type Options struct {
	OnlyShowDigest bool
	ExtraContext   string

	HTTPClient     *http.Client
	AIServiceURL   string
	UserAgent      string
	RequestTimeout time.Duration // Defaults to 10 minutes

	OrganizationID string
	ProjectID      string

	IsInteractive bool
	Yes           bool
	IsDebug       bool
	DebugLogFunc  func(fmt string, args ...any)
}

type Output

type Output struct {
	ConfigYAML string `json:"config_yaml"`
	Valid      bool   `json:"valid"`
}

Output represents output from the /ai/generate-configuration API.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL