summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gitTag.common.go9
1 files changed, 4 insertions, 5 deletions
diff --git a/gitTag.common.go b/gitTag.common.go
index 81e44c3..c41f7c1 100644
--- a/gitTag.common.go
+++ b/gitTag.common.go
@@ -112,13 +112,12 @@ func (repo *Repo) IsLocalBranch(findname string) bool {
loop := repo.Tags.All()
for loop.Scan() {
t := loop.Next()
- // log.Info("LocalTagExists() tag:", t.Refname)
-
- tagname := t.Refname
- if strings.HasPrefix(tagname, "refs/heads") {
+ if !strings.HasPrefix(t.Refname, "refs/heads") {
+ // log.Info("LocalTagExists() skip tag:", t.Refname)
continue
}
- path, filename := filepath.Split(tagname)
+ // log.Info("LocalTagExists() check tag:", t.Refname)
+ path, filename := filepath.Split(t.Refname)
log.Log(INFO, "gitpb.IsBranch() tag:", path, filename, "from", repo.GetGoPath())
if filename == findname {
log.Log(INFO, "gitpb.IsBranch() found tag:", path, filename, "from", repo.GetGoPath())