File: main.go

package info (click to toggle)
golang-github-influxdata-yarpc 0.0.1-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 276 kB
  • sloc: makefile: 2
file content (26 lines) | stat: -rw-r--r-- 576 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package main

import (
	"github.com/gogo/protobuf/vanity/command"
	"github.com/influxdata/yarpc/cmd/protoc-gen-yarpc/generator"
	"github.com/influxdata/yarpc/cmd/protoc-gen-yarpc/yarpc"
)

func main() {
	g := generator.New()
	g.Request = command.Read()
	g.Suffix = ".yarpc.go"
	g.CommandLineParameters(g.Request.GetParameter())

	// Create a wrapped version of the Descriptors and EnumDescriptors that
	// point to the file that defines them.
	g.WrapTypes()

	g.SetPackageNames()
	g.BuildTypeNameMap()

	p := &yarpc.Plugin{}
	g.GeneratePlugin(p)

	command.Write(g.Response)
}