diff options
Diffstat (limited to 'reloadTags.go')
| -rw-r--r-- | reloadTags.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/reloadTags.go b/reloadTags.go index ce25b0c..3665567 100644 --- a/reloadTags.go +++ b/reloadTags.go @@ -168,11 +168,16 @@ func (repo *Repo) NewestTag() *GitTag { } // this should just do is.Exists(".git/refs/heads/findname") +// this is a simple check and doesn't work all the time func (repo *Repo) LocalTagExists(findname string) bool { fname := filepath.Join(".git/refs/heads", findname) if repo.Exists(fname) { return true } + fname = filepath.Join(".git/refs/tags", findname) + if repo.Exists(fname) { + return true + } /* loop := repo.Tags.SortByRefname() for loop.Scan() { |
