Hi Michał, Do the second and third line(s) depend on the success of the previous one(s)? If so, a Bash script seems a good option as it allows you to stop the whole process if one step fails.
If you are not a fan of Bash or of makefiles, or if you don't want to restrict yourself to systems that have Bash or Make installed, something like mage <https://github.com/magefile/mage> (make/rake in Go) might meet your needs. But if you are only concerned about the number of go:generate lines being larger than one, I don't think this is a problem. That said, I am not a heavy user of go generate, so this is nothing more than my opinion. A go generate power user might tell you a different story... Best, Christoph On Monday, October 16, 2017 at 8:24:04 PM UTC+2, mic...@scylladb.com wrote: > > I have a use case where I use multi line go generate, similar to > https://github.com/containous/traefik/blob/master/generate.go > > //go:generate rm -vf autogen/gen.go > //go:generate mkdir -p static > //go:generate go-bindata -pkg autogen -o autogen/gen.go ./static/... > ./templates/... > > Would you recommend refactoring this to a single go generate and a bash > script? > > -- > Michał Matczuk > -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.