sqs / goreturns

A gofmt/goimports-like tool for Go programmers that fills in Go return statements with zero values to match the func return types
Other
529 stars 55 forks source link

Add -s flag for gofmt parity #45

Open johanbrandhorst opened 6 years ago

johanbrandhorst commented 6 years ago

gofmt offers a -s parameter for simplifying code, which is quite nice. I think goreturns should add this parameter as well since it promises to support a superset of gofmt's features, and I'd like both simplified code and auto-returns.

sqs commented 6 years ago

Yes, this would be great. Overall I would like to overhaul goreturns soon and make it shell out to goimports/gofmt and (probably) pass along flags to future-proof it.

A PR for this would be gladly accepted to get this in sooner, though!

MaerF0x0 commented 5 years ago

is this still the planned path? I can see if I can handle -s