aboutsummaryrefslogtreecommitdiff
path: root/internal/rtree/repo.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/rtree/repo.go')
-rw-r--r--internal/rtree/repo.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/internal/rtree/repo.go b/internal/rtree/repo.go
index 59f3811..f710666 100644
--- a/internal/rtree/repo.go
+++ b/internal/rtree/repo.go
@@ -49,6 +49,11 @@ func (r Repo) AbsolutePath() string {
return filepath.Join(RootPath, r.CheckoutPath)
}
+//GitDirPath returns the path of the .git directory of this repo.
+func (r Repo) GitDirPath() string {
+ return filepath.Join(r.AbsolutePath(), ".git")
+}
+
//NewRepoFromAbsolutePath initializes a Repo instance by scanning the existing
//checkout at the given path.
func NewRepoFromAbsolutePath(path string) (repo Repo, err error) {