(httpClient *http.Client, hostname, keyFile string, title string)
| 240 | } |
| 241 | |
| 242 | func sshKeyUpload(httpClient *http.Client, hostname, keyFile string, title string) (bool, error) { |
| 243 | f, err := os.Open(keyFile) |
| 244 | if err != nil { |
| 245 | return false, err |
| 246 | } |
| 247 | defer f.Close() |
| 248 | |
| 249 | return add.SSHKeyUpload(httpClient, hostname, f, title) |
| 250 | } |
| 251 | |
| 252 | func GetCurrentLogin(httpClient httpClient, hostname, authToken string) (string, error) { |
| 253 | query := `query UserCurrent{viewer{login}}` |
no test coverage detected