<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Best-Practices on Vishal Bhoriwal</title><link>https://www.vishalbhoriwal.me/tags/best-practices/</link><description>Recent content in Best-Practices on Vishal Bhoriwal</description><generator>Hugo</generator><language>en</language><lastBuildDate>Sat, 10 Feb 2024 00:00:00 +0000</lastBuildDate><atom:link href="https://www.vishalbhoriwal.me/tags/best-practices/index.xml" rel="self" type="application/rss+xml"/><item><title>On Writing Good Commit Messages</title><link>https://www.vishalbhoriwal.me/blog/commit-messages/</link><pubDate>Sat, 10 Feb 2024 00:00:00 +0000</pubDate><guid>https://www.vishalbhoriwal.me/blog/commit-messages/</guid><description>&lt;p&gt;A commit message is a letter to your future self. Make it worth reading.&lt;/p&gt;
&lt;h2 id="the-problem-with-bad-commits"&gt;The Problem with Bad Commits&lt;/h2&gt;
&lt;p&gt;We&amp;rsquo;ve all seen them:&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;fix
wip
asdf
final final FINAL
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;These tell you nothing. Six months later, when a bug surfaces and you&amp;rsquo;re spelunking through &lt;code&gt;git log&lt;/code&gt;, these are useless noise.&lt;/p&gt;
&lt;h2 id="the-rule-of-thumb"&gt;The Rule of Thumb&lt;/h2&gt;
&lt;p&gt;The subject line of a commit should complete this sentence:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;If applied, this commit will&amp;hellip;&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;So: &amp;ldquo;Add input validation to login form&amp;rdquo; rather than &amp;ldquo;validation stuff&amp;rdquo;.&lt;/p&gt;</description></item></channel></rss>