MCPcopy
hub / github.com/hasura/graphql-engine / SetupCodegenAssetsRepo

Method SetupCodegenAssetsRepo

cli/cli.go:592–605  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

590}
591
592func (ec *ExecutionContext) SetupCodegenAssetsRepo() error {
593 var op errors.Op = "cli.ExecutionContext.SetupCodegenAssetsRepo"
594 base := filepath.Join(ec.GlobalConfigDir, util.ActionsCodegenDirName)
595 base, err := filepath.Abs(base)
596 if err != nil {
597 return errors.E(op, fmt.Errorf("cannot get absolute path: %w", err))
598 }
599 ec.CodegenAssetsRepo = util.NewGitUtil(util.ActionsCodegenRepoURI, base, "")
600 ec.CodegenAssetsRepo.Logger = ec.Logger
601 if ec.GlobalConfig.CLIEnvironment == ServerOnDockerEnvironment {
602 ec.CodegenAssetsRepo.DisableCloneOrUpdate = true
603 }
604 return nil
605}
606
607// Validate prepares the ExecutionContext ec and then validates the
608// ExecutionDirectory to see if all the required files and directories are in

Callers 3

newActionsUseCodegenCmdFunction · 0.80
runMethod · 0.80
newActionsCodegenCmdFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected