Documentation ¶
Overview ¶
Provide general KCL compilation method
Index ¶
- Constants
- func CompileUsingCmd(sourceKclFiles []string, targetFile string, args map[string]string, ...) (string, string, error)
- func CompileWithSpinner(workDir string, filenames, settings, arguments, overrides []string, ...) (*models.Spec, *pterm.SpinnerPrinter, error)
- func EnableRPC() bool
- func GetKclPath() string
- func GetKclvmPath() string
- func Init() error
- func Overwrite(fileName string, overrides []string) (bool, error)
- type CompileResult
Constants ¶
View Source
const KusionKclPathEnv = "KUSION_KCL_PATH"
Variables ¶
This section is empty.
Functions ¶
func CompileUsingCmd ¶
func CompileUsingCmd(sourceKclFiles []string, targetFile string, args map[string]string, settings []string) (string, string, error)
Simply call kcl cmd
func CompileWithSpinner ¶
func CompileWithSpinner(workDir string, filenames, settings, arguments, overrides []string, stack *projectstack.Stack, ) (*models.Spec, *pterm.SpinnerPrinter, error)
Types ¶
type CompileResult ¶
The result of a KCL compilation
func Compile ¶
func Compile(workDir string, filenames, settings, arguments, overrides []string, disableNone bool, overrideAST bool) (*CompileResult, error)
Compile General KCL compilation method
func NewCompileResult ¶
func NewCompileResult(k *kcl.KCLResultList) *CompileResult
New a CompileResult by KCLResultList
func NewCompileResultByMapList ¶
func NewCompileResultByMapList(mapList []map[string]interface{}) *CompileResult
New a CompileResult by map array
func (*CompileResult) RawYAML ¶ added in v0.4.1
func (c *CompileResult) RawYAML() string
Click to show internal directories.
Click to hide internal directories.