From 9eabff46459a912b09aa7937199134b01d09def0 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Fri, 26 Sep 2025 23:43:29 -0500 Subject: save Tags.Master & Tags.Devel --- doNormal.go | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'doNormal.go') diff --git a/doNormal.go b/doNormal.go index 33cbcf6..06fec11 100644 --- a/doNormal.go +++ b/doNormal.go @@ -17,6 +17,7 @@ import ( "go.wit.com/lib/gui/shell" "go.wit.com/lib/protobuf/gitpb" "go.wit.com/log" + "google.golang.org/protobuf/proto" ) func doNormal() bool { @@ -130,6 +131,16 @@ func checkNormalRepoState(repo *gitpb.Repo) error { return ErrorLocalMasterBranch } + if repo.Tags.Master == nil { + if found := repo.GetRemoteTag(repo.GetMasterBranchName()); found != nil { + log.Info("found master tag ", repo.FullPath, found) + repo.Tags.Master = proto.Clone(found).(*gitpb.GitTag) + config.SetChanged("repos", true) + } else { + log.Info("not found master tag", repo.FullPath) + } + } + if repo.GetCurrentBranchName() != repo.GetUserBranchName() { log.Infof("changing to user(%s) branch: %s\n", repo.GetUserBranchName(), repo.FullPath) repo.CheckoutUser() -- cgit v1.2.3