resolveWorkingDirForSession accepts an explicit --repo flag value and falls back to the current working directory. Unlike resolveRepoDir it does not require the target to be a git repository, so users can inspect sessions even after archiving a checkout.
(input string)
| 121 | // require the target to be a git repository, so users can inspect sessions |
| 122 | // even after archiving a checkout. |
| 123 | func resolveWorkingDirForSession(input string) (string, error) { |
| 124 | dir, _, err := resolveWorkingDir(input, false) |
| 125 | if err != nil { |
| 126 | return "", err |
| 127 | } |
| 128 | return dir, nil |
| 129 | } |
| 130 | |
| 131 | func printSessionTable(w io.Writer, summaries []session.Summary) { |
| 132 | tw := tabwriter.NewWriter(w, 0, 0, 2, ' ', 0) |
no test coverage detected