mirror of
https://github.com/coder/coder.git
synced 2025-03-15 19:19:58 +00:00
Relates to https://github.com/coder/coder/issues/16419 Builds upon https://github.com/coder/coder/pull/16638 and adds a command `exp rpty` that allows you to open a ReconnectingPTY session to an agent. This ultimately allows us to add an integration-style CLI test to verify the functionality added in #16638 .
22 lines
492 B
Go
22 lines
492 B
Go
package cli
|
|
|
|
import "github.com/coder/serpent"
|
|
|
|
func (r *RootCmd) expCmd() *serpent.Command {
|
|
cmd := &serpent.Command{
|
|
Use: "exp",
|
|
Short: "Internal commands for testing and experimentation. These are prone to breaking changes with no notice.",
|
|
Handler: func(i *serpent.Invocation) error {
|
|
return i.Command.HelpHandler(i)
|
|
},
|
|
Hidden: true,
|
|
Children: []*serpent.Command{
|
|
r.scaletestCmd(),
|
|
r.errorExample(),
|
|
r.promptExample(),
|
|
r.rptyCommand(),
|
|
},
|
|
}
|
|
return cmd
|
|
}
|