aboutsummaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/config.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/config/config.go b/config/config.go
index a637f6d..2c3b8b9 100644
--- a/config/config.go
+++ b/config/config.go
@@ -8,6 +8,7 @@ import (
"sort"
"strconv"
+ "gopkg.in/src-d/go-git.v4/internal/url"
format "gopkg.in/src-d/go-git.v4/plumbing/format/config"
)
@@ -399,3 +400,7 @@ func (c *RemoteConfig) marshal() *format.Subsection {
return c.raw
}
+
+func (c *RemoteConfig) IsFirstURLLocal() bool {
+ return url.IsLocalEndpoint(c.URLs[0])
+}