summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--forgeConfig.proto4
-rw-r--r--humanShowRepo.go6
-rw-r--r--patchset.Make.go2
-rw-r--r--patchset.proto8
4 files changed, 15 insertions, 5 deletions
diff --git a/forgeConfig.proto b/forgeConfig.proto
index e96001d..81e2f2c 100644
--- a/forgeConfig.proto
+++ b/forgeConfig.proto
@@ -12,7 +12,7 @@ import "google/protobuf/timestamp.proto"; // Import the well-known type for Time
// package names sometimes must be different than the binary name
// for example 'zookeeper' is packaged as 'zookeeper-go'
// due to the prior apache foundation project. This happens and is ok!
-message ForgeConfig {
+message ForgeConfig { // `autogenpb:nomutex`
string goPath = 1; // `autogenpb:unique` `autogenpb:sort` // Examples: 'go.wit.com/apps/go-clone' or "~/mythings" or "/home/src/foo"
bool writable = 2; // if you have write access to the repo
@@ -34,7 +34,7 @@ message ForgeConfig {
string goSrc = 13; // is ~/go/src unless a go.work file is found
}
-message ForgeConfigs { // `autogenpb:marshal`
+message ForgeConfigs { // `autogenpb:marshal` `autogenpb:nomutex`
string uuid = 1; // could be useful for /usr/share/file/magic someday?
string version = 2; // could be used for protobuf schema change violations?
repeated ForgeConfig ForgeConfigs = 3;
diff --git a/humanShowRepo.go b/humanShowRepo.go
index 1416d3b..4e5ccfa 100644
--- a/humanShowRepo.go
+++ b/humanShowRepo.go
@@ -61,7 +61,11 @@ func (f *Forge) HumanPrintRepo(check *gitpb.Repo) {
// testNext(check)
found := new(gitpb.Repos)
- found.AppendUniqueGoPath(check)
+ if !found.AppendByGoPath(check) {
+ log.Info("forgepb check. repo already existed", check.FullPath, check.GetGoPath())
+ } else {
+ log.Info("forgepb check. repo was new", check.FullPath, check.GetGoPath())
+ }
f.PrintHumanTable(found)
printTime("Last Pull", check.Times.LastPull.AsTime())
diff --git a/patchset.Make.go b/patchset.Make.go
index fd68efb..ac1c60b 100644
--- a/patchset.Make.go
+++ b/patchset.Make.go
@@ -139,7 +139,7 @@ func (p *Patchset) addPatchFiles(repo *gitpb.Repo) error {
patch.Data = data
patch.parseData()
patch.StartHash = repo.DevelHash()
- p.Patches = append(p.Patches, patch)
+ p.Patches.Append(patch)
log.Info("ADDED PATCH FILE", path)
return nil
})
diff --git a/patchset.proto b/patchset.proto
index b905c6c..616e389 100644
--- a/patchset.proto
+++ b/patchset.proto
@@ -16,8 +16,14 @@ message Patch {
repeated string Files = 10; // the filenames this patch changes
}
+message Patches { // `autogenpb:marshal`
+ string uuid = 1; // `autogenpb:uuid:be926ad9-1111-484c-adf2-d96eeabf3079` // todo: add autogenpb support for this
+ string version = 2; // `autogenpb:version:v0.0.45` // todo: add autogenpb support for this
+ repeated Patch Patches = 3;
+}
+
message Patchset { // `autogenpb:marshal`
- repeated Patch Patches = 1; // `autogenpb:unique` `autogenpb:sort`
+ Patches patches = 1; // `autogenpb:unique` `autogenpb:sort`
string name = 2; // `autogenpb:sort`
string comment = 3; //
string gitAuthorName = 4; // `autogenpb:sort`