(opts *ViewOptions)
| 473 | } |
| 474 | |
| 475 | func shouldFetchJobs(opts *ViewOptions) bool { |
| 476 | if opts.Prompt { |
| 477 | return true |
| 478 | } |
| 479 | if opts.Exporter != nil { |
| 480 | if slices.Contains(opts.Exporter.Fields(), "jobs") { |
| 481 | return true |
| 482 | } |
| 483 | } |
| 484 | return false |
| 485 | } |
| 486 | |
| 487 | func getLog(httpClient *http.Client, hostname string, logPath safeurl.SafeURL) (io.ReadCloser, error) { |
| 488 | // The response body is the log archive, which is handed to the caller rather than decoded. |