(c config.Configuration, filepath string)
| 33 | ) |
| 34 | |
| 35 | func openCommandFor(c config.Configuration, filepath string) (string, []string) { |
| 36 | if !c.IsOpenCommandGiven() { |
| 37 | return "", []string{} |
| 38 | } |
| 39 | filepathWithoutSpaces := strings.ReplaceAll(filepath, " ", "&spc&") |
| 40 | split := strings.Split(injectCommandWithMessage(c.OpenCommand, filepathWithoutSpaces), " ") |
| 41 | for i := 0; i < len(split); i++ { |
| 42 | split[i] = strings.ReplaceAll(split[i], "&spc&", " ") |
| 43 | } |
| 44 | return split[0], split[1:] |
| 45 | } |
| 46 | |
| 47 | type GitVersion struct { |
| 48 | Major int |
no test coverage detected