MCPcopy Create free account
hub / github.com/remotemobprogramming/mob / openCommandFor

Function openCommandFor

mob.go:35–45  ·  view source on GitHub ↗
(c config.Configuration, filepath string)

Source from the content-addressed store, hash-verified

33)
34
35func 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
47type GitVersion struct {
48 Major int

Callers 1

Calls 2

injectCommandWithMessageFunction · 0.85
IsOpenCommandGivenMethod · 0.80

Tested by

no test coverage detected