TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

A Git Style Guide

42 pointsby pasxizeisabout 10 years ago

3 comments

davexunitabout 10 years ago
I&#x27;m very happy to see this guide encouraging the use of squashing and rebasing. It&#x27;s really frustrating to see patch sets being merged that look like:<p>* Add widget<p>&lt;code review happens&gt;<p>* Fix typo<p>* Add test<p>* Fix test<p>* etc.<p>People fear rebasing because they already pushed to a remote server. Just delete the remote branch and re-create it after you&#x27;ve rebased. Assuming, of course, that this is a feature branch of some sort that no one else depends on.<p>Clean, logical commits and a mostly linear history make me a happy developer.
hobarreraabout 10 years ago
A lot of these items seem to go against current standards for no particular reason (or with no clear explanation). I&#x27;ve mentioned two here [1], but there&#x27;s several others.<p>[1]: <a href="https:&#x2F;&#x2F;github.com&#x2F;agis-&#x2F;git-style-guide&#x2F;issues&#x2F;4" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;agis-&#x2F;git-style-guide&#x2F;issues&#x2F;4</a>
评论 #9326270 未加载
a3nabout 10 years ago
&gt;Prefer dashes over underscores.<p>Why? Is this just an arbitrary style preference, or is there some practical basis?
评论 #9321790 未加载
评论 #9321079 未加载