Refactoring after code review
Fix issues from code review:
-
Use dep or modules -
Go modules #34 (closed) -
Add comments to exported functions -
Missed error processing https://goreportcard.com/report/gitlab.com/postgres-ai/joe#L278 -
golint and misspell warning from the same link (@NikolayS: I suppose there are multiple tools around – various linters – are we sure with our choice? let's discuss in this issue) -
Use absolute path of package instead of dots in imports, e.g. "../ec2ctrl". Different in modules https://stackoverflow.com/a/53016796/319692 -
Short write is possible here https://gitlab.com/postgres-ai/joe/blob/master/src/provision/aws.go#L323 better to do it like here https://golang.org/src/io/ioutil/ioutil.go?s=2534:2602#L69 or use lib functions (@NikolayS: this was written before moving the DB Lab code to a separate repository; so, the link is to joe
repository. We need to start with applying changes indatabase-lab
first because Joe code will eventually be based on it as well)
Edited by Artyom Kartasov