Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit febc743

Browse files
committedMar 11, 2025·
fix: remove build and deploy commands in dev cli
fixes: #4796
1 parent 00ed52d commit febc743

File tree

2 files changed

+14
-3
lines changed

2 files changed

+14
-3
lines changed
 

‎cmd/ftl/cmd_interactive.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ type interactiveCmd struct {
1515
}
1616

1717
func (i *interactiveCmd) Run(ctx context.Context, binder KongContextBinder, projectConfig projectconfig.Config, eventSource *schemaeventsource.EventSource, manager *currentStatusManager) error {
18-
err := terminal.RunInteractiveConsole(ctx, createKongApplication(&SharedCLI{}, manager), eventSource, func(ctx context.Context, k *kong.Kong, args []string, additionalExit func(int)) error {
18+
err := terminal.RunInteractiveConsole(ctx, createKongApplication(&InteractiveCLI{}, manager), eventSource, func(ctx context.Context, k *kong.Kong, args []string, additionalExit func(int)) error {
1919
return runInnerCmd(ctx, k, projectConfig, binder, args, additionalExit)
2020
})
2121
if err != nil {

‎cmd/ftl/main.go

+13-2
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,6 @@ type SharedCLI struct {
6161
Update updateCmd `cmd:"" help:"Update a deployment."`
6262
Kill killCmd `cmd:"" help:"Kill a deployment."`
6363
Schema schemaCmd `cmd:"" help:"FTL schema commands."`
64-
Build buildCmd `cmd:"" help:"Build all modules found in the specified directories."`
65-
Deploy deployCmd `cmd:"" help:"Build and deploy all modules found in the specified directories."`
6664
Download downloadCmd `cmd:"" help:"Download a deployment."`
6765
Secret secretCmd `cmd:"" help:"Manage secrets."`
6866
Config configCmd `cmd:"" help:"Manage configuration."`
@@ -72,8 +70,14 @@ type SharedCLI struct {
7270
Postgres postgresCmd `cmd:"" help:"Manage PostgreSQL databases."`
7371
}
7472

73+
type BuildAndDeploy struct {
74+
Build buildCmd `cmd:"" help:"Build all modules found in the specified directories."`
75+
Deploy deployCmd `cmd:"" help:"Build and deploy all modules found in the specified directories."`
76+
}
77+
7578
type CLI struct {
7679
SharedCLI
80+
BuildAndDeploy
7781
LogConfig log.Config `embed:"" prefix:"log-" group:"Logging:"`
7882

7983
Authenticators map[string]string `help:"Authenticators to use for FTL endpoints." mapsep:"," env:"FTL_AUTHENTICATORS" placeholder:"HOST=EXE,…"`
@@ -92,6 +96,13 @@ type CLI struct {
9296
MCP mcpCmd `cmd:"" help:"Start the MCP server."`
9397
}
9498

99+
// The CLI that is used when running in interactive mode.
100+
type InteractiveCLI struct {
101+
SharedCLI
102+
BuildAndDeploy
103+
}
104+
105+
// The embedded CLI when running in dev mode.
95106
type DevModeCLI struct {
96107
SharedCLI
97108
Logs logsCmd `cmd:"" help:"Log commands."`

0 commit comments

Comments
 (0)
Please sign in to comment.