{"modulePath":"github.com/deepsourcelabs/cli","version":"v0.10.2","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package generate\n\n## Constants\n\n```go\nconst DEEPSOURCE_TOML_VERSION = 1\n```\n\n## Functions\n\n```go\nfunc NewCmdConfigGenerate() *cobra.Command\n```\nNewCmdConfigGenerate handles the generation of DeepSource config based on user inputs\n\n## Types\n\n```go\ntype Analyzer struct {\n\tName                string      `toml:\"name,omitempty\" json:\"name,omitempty\"`\n\tRuntimeVersion      string      `toml:\"runtime_version,omitempty\" json:\"runtime_version,omitempty\"`\n\tEnabled             bool        `toml:\"enabled\" json:\"enabled\"`\n\tDependencyFilePaths []string    `toml:\"dependency_file_paths,omitempty\" json:\"dependency_file_paths,omitempty\"`\n\tMeta                interface{} `toml:\"meta,omitempty\" json:\"meta,omitempty\"`\n\tThresholds          interface{} `toml:\"thresholds,omitempty\" json:\"thresholds,omitempty\"`\n}\n```\nDSConfig is the struct for .deepsource.toml file\n\n```go\ntype AnalyzerMetadata struct {\n\tFieldName   string\n\tType        string\n\tTitle       string\n\tDescription string\n\tOptions     []string\n\tUserInput   string\n}\n```\nStruct to hold the data regarding the compulsary meta fields as required by analyzers Also, the userinput for that field\n\n```go\ntype DSConfig struct {\n\tVersion         int           `toml:\"version\" json:\"version\"`\n\tExcludePatterns []string      `toml:\"exclude_patterns\" json:\"exclude_patterns,omitempty\"`\n\tTestPatterns    []string      `toml:\"test_patterns\" json:\"test_patterns,omitempty\"`\n\tAnalyzers       []Analyzer    `toml:\"analyzers,omitempty\" json:\"analyzers,omitempty\"`\n\tTransformers    []Transformer `toml:\"transformers,omitempty\" json:\"transformers,omitempty\"`\n}\n```\n\n```go\ntype Options struct {\n\tActivatedAnalyzers    []string // Analyzers activated by user\n\tAnalyzerMetaMap       map[string][]AnalyzerMetadata\n\tActivatedTransformers []string // Transformers activated by the user\n\tExcludePatterns       []string\n\tTestPatterns          []string\n\tGeneratedConfig       string\n}\n```\nOptions holds the metadata.\n\n```go\nfunc (o *Options) Run() error\n```\nRun executes the command.\n\n```go\ntype Transformer struct {\n\tName    string `toml:\"name\" json:\"name\"`\n\tEnabled bool   `toml:\"enabled\" json:\"enabled\"`\n}\n```\n\n","path":"github.com/deepsourcelabs/cli/command/config/generate","name":"generate","synopsis":"","isRedistributable":true}
