Skip to content
This repository has been archived by the owner on Jun 16, 2021. It is now read-only.

Fix function comments based on best practices from Effective Go #518

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Daanikus
Copy link

Every exported function in a program should have a doc comment. The first sentence should be a summary that starts with the name being declared.
From effective go.

I generated this with CodeLingo and I'm keen to get some feedback, but this is automated so feel free to close it and just say "opt out" to opt out of future CodeLingo outreach PRs.

@Daanikus
Copy link
Author

I'm not a huge fan of the colon-ifying (so to speak) and I welcome any feedback as to how I could improve the logic for this. Thanks.

Copy link
Collaborator

@vdemeester vdemeester left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Daanikus thanks for the contribution 🤗

  1. As from effective go "The first sentence should be a summary that starts with the name being declared.", this means it should be a sentence — thus something like HashString generates a hash string used to detect service volume config changes for example (no need for :)
  2. As written in the README, This is not really maintained anymore — the reason are diverse but mainly lack of time from the maintainers. I should archive it to mark is as such and put it in read-only mode.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants