title: Git command to commit all changes including files removed or created
body: <p>After making changes to files already tracked by <code>git</code> I usually do a:</p>
  
  <pre><code>git commit -a -m "a message describing what you did"
  </code></pre>
  
  <p>followed by</p>
  
  <pre><code>git push origin master
  </code></pre>
  
  <p>to commit and then push all changes to my Github account. The first command however does not work for commiting files either added or removed. To do that I would have to first type:</p>
  
  <pre><code>git add -A
  </code></pre>
  
  <p>as mentioned here: <a href="https://stackoverflow.com/questions/9329244/how-to-commit-and-push-all-changes-including-deletes">How to commit and push all changes, including deletes?</a>.</p>
  
  <p>In this other question <a href="https://stackoverflow.com/questions/2419249/git-commit-all-the-files-using-single-cmd">Git commit all files using single command</a> the accepted answer indicates that the only way to apply the <strong>full</strong> commit (ie: including files added or removed, not only edited) and then the push is by combining them with the <code>&amp;&amp;</code> command like so:</p>
  
  <pre><code>git add -A &amp;&amp; git commit
  </code></pre>
  
  <p>which in my case would look like:</p>
  
  <pre><code>git add -A &amp;&amp; git commit -a -m "a message describing what you did" &amp;&amp; git push origin master
  </code></pre>
  
  <p>Now for the question(s): is this large command correct? Is there a way to create a new <code>git</code> command to apply these three commands all at once? Furthermore: is this merging of commands recommended or discouraged? If so, please state the reason.</p>
  
  <hr>
  
  <h2>Edit</h2>
  
  <p>I immediately regret this decision: <a href="https://stackoverflow.com/questions/20288482/edit-last-pushed-commits-message">Edit last pushed commit&#39;s message</a>.</p>