Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Dotnet8WebAPI = Template{"dotnet8-webapi"} // Dotnet8WebApp = Template{"dotnet8-webapp"}. Dotnet8Worker = Template{"dotnet8-worker"} // Go Template = Template{"go"}. Templates = enum.New( Dotnet8WebAPI, Dotnet8Worker, ) )
View Source
var Command *cli.Command = &cli.Command{ Name: commandName, Aliases: []string{"c"}, Usage: "Create a new project from one of Elvia's templates.", UsageText: "3lv create [options] <output-directory>", Flags: []cli.Flag{ shared.SystemNameFlag( "The name of your system (Kubernetes namespace) you want to create your application in.", ), shared.ApplicationNameFlag( "The name of the application you want to create.", ), shared.RuntimeCloudProviderFlag(), &cli.StringFlag{ Name: "template", Aliases: []string{"t"}, Usage: "The template to use for the project. Supported templates are: " + strings.Join(Templates.Values(), ", "), Value: Dotnet8WebAPI.Value, Action: func(_ context.Context, _ *cli.Command, template string) error { parsed := Templates.Parse(template) if parsed == nil { return cli.Exit( fmt.Sprintf( "Template '%s' is not supported. Supported templates are: %s", template, Templates.Values(), ), 1, ) } return nil }, }, &cli.StringFlag{ Name: "default-branch", Aliases: []string{"b"}, Usage: "The default branch of the repository", Value: "trunk", }, &cli.StringFlag{ Name: "github-actions-directory", Aliases: []string{"G"}, Usage: "The root directory of your GitHub repository." + " The path specified will be prepended to '.github/workflows'.", }, }, Action: Create, }
Functions ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.