Thx, it is perfect. Le lundi 19 février 2018 20:35:48 UTC+1, Stéphane Jeandeaux a écrit : > > > Hi Jerome, > > You can take a look at git hooks https://golang.org/misc/git/pre-commit. > > Code: > test -z "$(gofmt -s -l $(find . -name '*.go' -type f -print) | tee > /dev/stderr)" > > Thanks and regards, > Stephane Jeandeaux. > > On Mon, Feb 19, 2018 at 6:44 AM Jérôme LAFORGE <jerome....@gmail.com > <javascript:>> wrote: > >> Hello Gophers, >> Has any one of you setted up the validation of format (goimports, go fmt) >> into Gitlab CI? >> My goal is to reject the commit that doesn't respect the Go's format. >> >> Thx in adv >> BR >> >> -- >> 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...@googlegroups.com <javascript:>. >> For more options, visit https://groups.google.com/d/optout. >> >
-- 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.