@@ -24,9 +24,9 @@ import (
24
24
25
25
// Args is used by the gengo framework to pass args specific to this generator.
26
26
type Args struct {
27
- OutputDir string // must be a directory path
28
- OutputPkg string // must be a Go import-path
29
- GoHeaderFile string
27
+ OutputDir string // must be a directory path
28
+ OutputPackage string // must be a Go import-path
29
+ GoHeaderFile string
30
30
31
31
// PluralExceptions specify list of exceptions used when pluralizing certain types.
32
32
// For example 'Endpoints:Endpoints', otherwise the pluralizer will generate 'Endpointes'.
@@ -45,7 +45,7 @@ func New() *Args {
45
45
func (args * Args ) AddFlags (fs * pflag.FlagSet ) {
46
46
fs .StringVar (& args .OutputDir , "output-dir" , "" ,
47
47
"the base directory under which to generate results" )
48
- fs .StringVar (& args .OutputPkg , "output-pkg" , "" ,
48
+ fs .StringVar (& args .OutputPackage , "output-pkg" , "" ,
49
49
"the base Go import-path under which to generate results" )
50
50
fs .StringSliceVar (& args .PluralExceptions , "plural-exceptions" , args .PluralExceptions ,
51
51
"list of comma separated plural exception definitions in Type:PluralizedType format" )
@@ -60,7 +60,7 @@ func (args *Args) Validate() error {
60
60
if len (args .OutputDir ) == 0 {
61
61
return fmt .Errorf ("--output-dir must be specified" )
62
62
}
63
- if len (args .OutputPkg ) == 0 {
63
+ if len (args .OutputPackage ) == 0 {
64
64
return fmt .Errorf ("--output-pkg must be specified" )
65
65
}
66
66
return nil
0 commit comments