GoogleCloudPlatform / GoogleCloudPlatform/gcsfuse

Codebase style conflicts with Go official style guide

Open
#581 0 comments 0 reactions 0 assignees View on GitHub
Eng-Backlog feature request p1
Dominant language
Go
Stars
2.3k
Forks
510
Avg merge
2d 17h
Merged PRs (30d)
35

Description

Golang style:
- https://github.com/golang/go/wiki/CodeReviewComments
- https://go.dev/doc/effective_go

In this codebase:

1. [Line lengths](https://github.com/golang/go/wiki/CodeReviewComments#line-length) are limited to 80 characters, which breaks function defs and calls, contracting the best practice.
2. [Named return parameters](https://github.com/golang/go/wiki/CodeReviewComments#named-result-parameters) and [naked returns](https://github.com/golang/go/wiki/CodeReviewComments#named-result-parameters) are prevalent but against the guidance.
3. [Comment sentences](https://github.com/golang/go/wiki/CodeReviewComments#comment-sentences) do not always start with the function or struct name.
4. [Error strings](https://github.com/golang/go/wiki/CodeReviewComments#error-strings) are sometimes capitalized.
5. [Package comments](https://github.com/golang/go/wiki/CodeReviewComments#package-names) are not always written.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.