Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate generated code in multiple files #41

Open
icock opened this issue Jul 1, 2017 · 3 comments
Open

Separate generated code in multiple files #41

icock opened this issue Jul 1, 2017 · 3 comments

Comments

@icock
Copy link

icock commented Jul 1, 2017

Could genny offer a command line option to separate generated code in multiple files?

For example, "SomeType=string,int" will generate gen-source-string.go and gen-source-int.go.

@meyerzinn
Copy link

meyerzinn commented Aug 18, 2017

+1 definitely would be useful for me. Maybe another string interpolation for -out?

@pdrum
Copy link
Collaborator

pdrum commented Aug 17, 2018

@icock @20zinnm I think it would be usefule. Do you have some more specific ideas on how to get the parameters for what files to generate and where to put them?

@duckbrain
Copy link

One idea is expand of the generic name replacement.

eg: -out gen-source-Something.go Something=string,int Other=bool,float64 creates gen-source-string.go and gen-source-int.go where the Other variations are copied in each of the files, but the Something ones are distinct to their output files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants