forked from TrueCloudLab/frostfs-api-go
[#107] protogen: Remove unused parameter
Signed-off-by: Evgenii Stratonikov <e.stratonikov@yadro.com>
This commit is contained in:
parent
33653962b7
commit
c1b5f46f98
1 changed files with 0 additions and 10 deletions
|
@ -2,8 +2,6 @@ package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"flag"
|
"flag"
|
||||||
"fmt"
|
|
||||||
"os"
|
|
||||||
|
|
||||||
"git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/util/protogen/internalgengo"
|
"git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/util/protogen/internalgengo"
|
||||||
"google.golang.org/protobuf/compiler/protogen"
|
"google.golang.org/protobuf/compiler/protogen"
|
||||||
|
@ -12,18 +10,10 @@ import (
|
||||||
func main() {
|
func main() {
|
||||||
var flags flag.FlagSet
|
var flags flag.FlagSet
|
||||||
genFuzz := flags.Bool("fuzz", false, "generate fuzz tests")
|
genFuzz := flags.Bool("fuzz", false, "generate fuzz tests")
|
||||||
yamlConfigPath := flags.String("config", "", "path to the configuration")
|
|
||||||
|
|
||||||
protogen.Options{
|
protogen.Options{
|
||||||
ParamFunc: flags.Set,
|
ParamFunc: flags.Set,
|
||||||
}.Run(func(gen *protogen.Plugin) error {
|
}.Run(func(gen *protogen.Plugin) error {
|
||||||
if *yamlConfigPath != "" {
|
|
||||||
s, e := os.Getwd()
|
|
||||||
fmt.Fprintln(os.Stderr, s, e)
|
|
||||||
data, err := os.ReadFile(*yamlConfigPath)
|
|
||||||
fmt.Fprintln(os.Stderr, string(data), err)
|
|
||||||
}
|
|
||||||
|
|
||||||
for _, f := range gen.Files {
|
for _, f := range gen.Files {
|
||||||
if f.Generate {
|
if f.Generate {
|
||||||
internalgengo.GenerateFile(gen, f)
|
internalgengo.GenerateFile(gen, f)
|
||||||
|
|
Loading…
Reference in a new issue