<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Commit Message on Everyone Has a Story</title><link>https://19051992.xyz/tags/commit-message/</link><description>Recent content in Commit Message on Everyone Has a Story</description><generator>Hugo</generator><language>en</language><managingEditor>BhaveshSGupta@disroot.org (Bhavesh S. Gupta)</managingEditor><webMaster>BhaveshSGupta@disroot.org (Bhavesh S. Gupta)</webMaster><lastBuildDate>Mon, 22 Jul 2019 12:12:00 +0530</lastBuildDate><atom:link href="https://19051992.xyz/tags/commit-message/index.xml" rel="self" type="application/rss+xml"/><item><title>Introduction to Git and seven rules of great Git Commit Message</title><link>https://19051992.xyz/blog/introduction-to-git-and-seven-rules-of-a-great-git-commit-message/</link><pubDate>Mon, 22 Jul 2019 12:12:00 +0530</pubDate><author>BhaveshSGupta@disroot.org (Bhavesh S. Gupta)</author><guid>https://19051992.xyz/blog/introduction-to-git-and-seven-rules-of-a-great-git-commit-message/</guid><description>&lt;p>As part of summer training at #dgplug, Sayan took our basics to Git session. We were introduced to basics of VCS(Version Control System), need to use a VCS and introduction to Git.&lt;/p>
&lt;p>These were some of commands we learn during the session conducted over the course of two days,&lt;/p>
&lt;ul>
&lt;li>git init is used initialize Git repository
&lt;div class="highlight-container">

 &lt;button class="copy-code-btn outline">Copy&lt;/button>

 
 &lt;pre tabindex="0">&lt;code>$ git init&lt;/code>&lt;/pre>
&lt;/div>
&lt;/li>
&lt;li>git config to used to configure various Git configuration using below command one can configure their Name and Email globally for Git.
&lt;div class="highlight-container">

 &lt;button class="copy-code-btn outline">Copy&lt;/button>

 
 &lt;pre tabindex="0">&lt;code>$ git config --global user.name &amp;#34;&amp;lt;Name&amp;gt;&amp;#34;
$ git config --global user.email &amp;#34;&amp;lt;email&amp;gt;&amp;#34;&lt;/code>&lt;/pre>
&lt;/div>
&lt;/li>
&lt;li>git add is used to add files to stage area in Git.
&lt;div class="highlight-container">

 &lt;button class="copy-code-btn outline">Copy&lt;/button>

 
 &lt;pre tabindex="0">&lt;code>$ git add helloworld.txt
$ git add .
$ git add -u&lt;/code>&lt;/pre>
&lt;/div>
&lt;/li>
&lt;li>git status to see status of you Git repository. Whether there are changes that are still not added to stage or there are changes which are added to stage but not committed.
&lt;div class="highlight-container">

 &lt;button class="copy-code-btn outline">Copy&lt;/button>

 
 &lt;pre tabindex="0">&lt;code>$ git status&lt;/code>&lt;/pre>
&lt;/div>
&lt;/li>
&lt;li>git commit is used to commit your files from stage.
&lt;div class="highlight-container">

 &lt;button class="copy-code-btn outline">Copy&lt;/button>

 
 &lt;pre tabindex="0">&lt;code>$ git commit -m &amp;#34;Snapshot 2&amp;#34;&lt;/code>&lt;/pre>
&lt;/div>
&lt;/li>
&lt;li>git diff is used to difference between current state and previous state.
&lt;div class="highlight-container">

 &lt;button class="copy-code-btn outline">Copy&lt;/button>

 
 &lt;pre tabindex="0">&lt;code>$ git diff&lt;/code>&lt;/pre>
&lt;/div>
&lt;/li>
&lt;li>git log is used to get commit logs.
&lt;div class="highlight-container">

 &lt;button class="copy-code-btn outline">Copy&lt;/button>

 
 &lt;pre tabindex="0">&lt;code>$ git log
$ git log -2
$ git log -p -2
$ git log --stat&lt;/code>&lt;/pre>
&lt;/div>
&lt;/li>
&lt;/ul>
&lt;p>As part of home task we were asked to read &lt;a href="https://chris.beams.io/posts/git-commit/">https://chris.beams.io/posts/git-commit/&lt;/a>, which explains How to write a Git commit message.&lt;/p></description></item></channel></rss>