@@ -24,9 +24,9 @@ import (
2424
2525// Args is used by the gengo framework to pass args specific to this generator.
2626type 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
3030
3131 // PluralExceptions specify list of exceptions used when pluralizing certain types.
3232 // For example 'Endpoints:Endpoints', otherwise the pluralizer will generate 'Endpointes'.
@@ -45,7 +45,7 @@ func New() *Args {
4545func (args * Args ) AddFlags (fs * pflag.FlagSet ) {
4646 fs .StringVar (& args .OutputDir , "output-dir" , "" ,
4747 "the base directory under which to generate results" )
48- fs .StringVar (& args .OutputPkg , "output-pkg" , "" ,
48+ fs .StringVar (& args .OutputPackage , "output-pkg" , "" ,
4949 "the base Go import-path under which to generate results" )
5050 fs .StringSliceVar (& args .PluralExceptions , "plural-exceptions" , args .PluralExceptions ,
5151 "list of comma separated plural exception definitions in Type:PluralizedType format" )
@@ -60,7 +60,7 @@ func (args *Args) Validate() error {
6060 if len (args .OutputDir ) == 0 {
6161 return fmt .Errorf ("--output-dir must be specified" )
6262 }
63- if len (args .OutputPkg ) == 0 {
63+ if len (args .OutputPackage ) == 0 {
6464 return fmt .Errorf ("--output-pkg must be specified" )
6565 }
6666 return nil
0 commit comments