Rewrite filecheck in Go. v0.1