mirror of
				https://github.com/optim-enterprises-bv/kubernetes.git
				synced 2025-11-03 19:58:17 +00:00 
			
		
		
		
	Name check for go-to-protobuf in wrong spot
This commit is contained in:
		@@ -125,9 +125,6 @@ func Run(g *Generator) {
 | 
			
		||||
	protobufNames := NewProtobufNamer()
 | 
			
		||||
	outputPackages := generator.Packages{}
 | 
			
		||||
	for _, d := range strings.Split(g.Packages, ",") {
 | 
			
		||||
		if strings.Contains(d, "-") {
 | 
			
		||||
			log.Fatalf("Package names must be valid protobuf package identifiers, which allow only [a-z0-9_]: %s", d)
 | 
			
		||||
		}
 | 
			
		||||
		generateAllTypes, outputPackage := true, true
 | 
			
		||||
		switch {
 | 
			
		||||
		case strings.HasPrefix(d, "+"):
 | 
			
		||||
@@ -137,6 +134,9 @@ func Run(g *Generator) {
 | 
			
		||||
			d = d[1:]
 | 
			
		||||
			outputPackage = false
 | 
			
		||||
		}
 | 
			
		||||
		if strings.Contains(d, "-") {
 | 
			
		||||
			log.Fatalf("Package names must be valid protobuf package identifiers, which allow only [a-z0-9_]: %s", d)
 | 
			
		||||
		}
 | 
			
		||||
		name := protoSafePackage(d)
 | 
			
		||||
		parts := strings.SplitN(d, "=", 2)
 | 
			
		||||
		if len(parts) > 1 {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user