celestiaorg / smt

A Go library that implements a Sparse Merkle tree for a key-value map.
https://godoc.org/github.com/celestiaorg/smt
MIT License
138 stars 53 forks source link

Make go fmt formatting obligatory throughout the repo #4

Closed liamsi closed 4 years ago

liamsi commented 4 years ago

Motivation


diff -u <(echo -n) <(gofmt -d .) will report exit status 1 if the change contains file that aren't consistently formatted via go fmt.This guarantees consistent formatting of the code by every contributor (and automates this check via CI). e.g. see: seehttps://travis-ci.org/github/lazyledger/smt/builds/702763735


Note: I did not go fmt the whole repo (the build will fail) and prefer to leave that up to you @musalbas. If I do it, it would most likely touch every single line.