Giter Site home page Giter Site logo

awesome-go-style's Introduction

This is a collection of style guides for Go.

Be sure to read about writing engineering guidelines before trying to adopt one of these wholesale.

(For more commentary on these, see my blog post Idiomatic Go Resources)

The Classics

Googler Talks

Go Wiki Pages

Non-Googlers

Further Reading

Corporate/Project-specific Style Guildes

General tips for Code Reviews:

My own attempt at best practices for TODO comments (extracted from existing Go practices, but otherwise mostly undocumented):

// For TODOs, BUGs, and NOTEs please use the standard form:
//
//    // TODO(username): ...
//
// The username (generally yours) means "for more information see", not
// "I claim responsibility for fixing this." Please use TODO rather than FIXME,
// XXX, HACK, etc.  This limits the number of things to grep for.
//
//    * TODO denotes missing features or functionality
//    * BUG denotes known broken code; these are displayed in godoc
//    * NOTE is used to highlight a particularly important or subtle section of code
//    * SECURITY and SECBUG are used for security related notes and issues

If you have a bug tracker, TODO(bug#) is probalby more useful as they're likely to stay static while maintainers move over time. Similarly, including dates or release versions in the comment can ensure TODOs are revisisted at appropriate times.

Find this useful? Buy me a coffee!

awesome-go-style's People

Contributors

dgryski avatar bwplotka avatar jekamas avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.