Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Cmd = &cobra.Command{ Use: "board [device ID]", Short: "ssh into a pi", Long: "open an ssh connection to a pi with the ability to enter commands", Args: args.ValidDeviceID, Run: func(cmd *cobra.Command, args []string) { sshArgs := []string{"ssh", fmt.Sprintf("pi@%s.byu.edu", args[0])} sshPath, err := exec.LookPath("ssh") if err != nil { fmt.Printf("failure to find ssh executable: %v", err) os.Exit(1) } err = syscall.Exec(sshPath, sshArgs, os.Environ()) if err != nil { fmt.Printf("board error: %v\n", err) os.Exit(1) } }, }
Cmd .
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.