MCPcopy Index your code
hub / github.com/wavetermdev/waveterm / preRunSetupRpcClient

Function preRunSetupRpcClient

cmd/wsh/cmd/wshcmd-root.go:85–95  ·  view source on GitHub ↗
(cmd *cobra.Command, args []string)

Source from the content-addressed store, hash-verified

83}
84
85func preRunSetupRpcClient(cmd *cobra.Command, args []string) error {
86 jwtToken := os.Getenv(wshutil.WaveJwtTokenVarName)
87 if jwtToken == "" {
88 return fmt.Errorf("wsh must be run inside a Wave-managed SSH session (WAVETERM_JWT not found)")
89 }
90 err := setupRpcClient(nil, jwtToken)
91 if err != nil {
92 return err
93 }
94 return nil
95}
96
97func getIsTty() bool {
98 if fileInfo, _ := os.Stdout.Stat(); (fileInfo.Mode() & os.ModeCharDevice) != 0 {

Callers 2

runVersionCmdFunction · 0.85
debugTermPreRunFunction · 0.85

Calls 1

setupRpcClientFunction · 0.85

Tested by

no test coverage detected