<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress.com" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>

<channel>
	<title>git-2 &amp;laquo; WordPress.com Tag Feed</title>
	<link>http://en.wordpress.com/tag/git-2/</link>
	<description>Feed of posts on WordPress.com tagged "git-2"</description>
	<pubDate>Wed, 19 Jun 2013 14:32:58 +0000</pubDate>

	<generator>http://en.wordpress.com/tags/</generator>
	<language>en</language>

<item>
<title><![CDATA[Default editor for Git]]></title>
<link>http://delboy1978uk.wordpress.com/2012/09/02/default-editor-for-git/</link>
<pubDate>Sun, 02 Sep 2012 00:58:33 +0000</pubDate>
<dc:creator>delboy1978uk</dc:creator>
<guid>http://delboy1978uk.wordpress.com/2012/09/02/default-editor-for-git/</guid>
<description><![CDATA[Just created a new site, and went to perform my initial commit to my Git repository, and yuk! Vi, or]]></description>
<content:encoded><![CDATA[<p>Just created a new site, and went to perform my initial commit to my Git repository, and yuk! Vi, or Vim, appeared! :-s Don&#8217;t get me wrong, Vi/Vim is powerful and can do all sorts, but I like Nano, or Pico! Last time this happened I type in a command to change the editor, but what I forgot to add was to make it the GLOBAL  default. A slight tweak, and the command looks like this. No more Vi! Awesome <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<pre>git config --global core.editor "nano"</pre>
]]></content:encoded>
</item>
<item>
<title><![CDATA[git reset]]></title>
<link>http://robinnagpal.wordpress.com/2012/08/18/git-reset/</link>
<pubDate>Sat, 18 Aug 2012 07:06:00 +0000</pubDate>
<dc:creator>robinnagpal</dc:creator>
<guid>http://robinnagpal.wordpress.com/2012/08/18/git-reset/</guid>
<description><![CDATA[Git provides us with various options for modifying history and one of these is “git reset”. Git rese]]></description>
<content:encoded><![CDATA[<p>Git provides us with various options for modifying history and one of these is “git reset”. Git reset along with different parameters, can be used for the following</p>
<ol>
<li>We want to keep the files as same but want to reduce the number of commits</li>
<li>Want our working directory to represent a particular commit</li>
<li>erase or discard the previous commits</li>
</ol>
<p>To achieve all this and more, git provides us with reset command which takes three types of parameters i.e. “&#8211;soft”,  “&#8211;mixed” and “&#8211;hard”</p>
<p>Let’s continue with our previous example to understand this clearly. Currently we have four files in our repository a.txt, b.txt, c.txt and d.txt.  We now modify the contents of d.txt</p>
<pre class="brush: plain; title: ; notranslate" title="">
$ echo &#34;Commit 4 in branch 1:before reset&#34; &#62;&#62; d.txt
</pre>
<p>If we try to print the contents of the file, it looks like this</p>
<pre class="brush: plain; title: ; notranslate" title="">
$ cat d.txt
“Commit 2 in branch 2”
“Commit 3 in branch 2”
Commit 4 in branch 1:before reset
</pre>
<p>Now let’s create another file e.txt</p>
<pre class="brush: plain; title: ; notranslate" title="">
$ echo &#34;Commit 4 in branch 1:before reset&#34; &#62;&#62; e.txt
</pre>
<p>Lets see the contents</p>
<pre class="brush: plain; title: ; notranslate" title="">
$ cat e.txt
Commit 4 in branch 1:before reset
</pre>
<p>Our repository will now look like this<br />
<img style="border:0 none;" src="https://lh4.googleusercontent.com/wbXjBdd_3ySWO9ty04Hqf5LHO94fFEz-eoaoVvbG-7C-jIxt-qjLM5QTFMPqQNBuQoI7QbTK0aRKDv-FxBEBYEvpK7t622qLiRWmiZPZAXHSuIT23xw" alt="" width="357px;" height="174px;" /></p>
<p>And now let’s add these changes to index</p>
<pre class="brush: plain; title: ; notranslate" title="">
$git add .
</pre>
<p><img style="border:0 none;" src="https://lh4.googleusercontent.com/Dbb7Lvwi-_rgplLQB9IbgTHOmqj2SyYgg7StB26xmHZJ9CDgFDw4cv5vCxDz4snZghR4esYle9MqJwsivYNQArhKXcIOW_6slkyvTXp93n12NShIT9Q" alt="" width="370px;" height="183px;" /></p>
<p>We will now try all the reset options one by one</p>
<ol>
<li><strong>git reset &#8211;soft HEAD^</strong>: This command will just move the HEAD  to previous commit. We could have also used “HEAD~2” or “HEAD~3” depending on where exactly we want to take the HEAD. After executing this command our repository looks like this<br />
<img style="border:0 none;" src="https://lh6.googleusercontent.com/F9yk0Ry2Cn1Qt912-fOIMcsqp1knfi23tOuo7NTQHHrpygsuQGcVPHJF4iWKURLe5Ltrx3IQQsBAx494RvQAK39QocL-GGGSTmoS_C2UgbFYrTarsGs" alt="" width="392px;" height="177px;" /><br />
So from here we see that our changes are still there in the index, it is only our HEAD, which now points to the previous commit. Also, content of all the files remain the same as it was before i.e. if we print the contents of b.txt</p>
<pre class="brush: plain; title: ; notranslate" title="">
$ cat b.txt
“Commit 2 in branch 2”
“Commit 3 in branch 2”
Commit 4 in branch 1:before reset
</pre>
</li>
<li><strong>git reset &#8211;mixed HEAD^</strong> : This command will move our HEAD to the previous commit and will modify our index to align it with the contents of the previous commit.
<pre class="brush: plain; title: ; notranslate" title="">
$ git reset --mixed HEAD^
Unstaged changes after reset:
M    d.txt
</pre>
<p>So our repository now looks like this<br />
<img style="border:0 none;" src="https://lh6.googleusercontent.com/8RnGWcaRPvUMHrZq5GSWl3GFR29U40vgCIcHcmNFNjJWlVriZ9QxUBQn33ow8zLsX3W5H1vcUrtQrm9BqxxAO58zT0MSh5RDJBf5NzWG_Cg-XGQfOGQ" alt="" width="397px;" height="179px;" /><br />
Here red dot shows the unstaged changes. Let’s check this with the status command</p>
<pre class="brush: plain; title: ; notranslate" title="">
$git status
# On branch master
# Changes not staged for commit:
#   (use &#34;git add &#60;file&#62;...&#34; to update what will be committed)
#   (use &#34;git checkout -- &#60;file&#62;...&#34; to discard changes in working directory)
#
#    modified:   d.txt
#
# Untracked files:
#   (use &#34;git add &#60;file&#62;...&#34; to include in what will be committed)
#
#    e.txt
no changes added to commit (use &#34;git add&#34; and/or &#34;git commit -a&#34;)
</pre>
<li><strong>git reset &#8211;hard HEAD^</strong> : This command is going to move the HEAD to the previous commit. Also, it will remove all the staged changes and will show you working directory corresponding to the commit on which you have moved. i.e. the previous commit in our case. After this command, your repository will look like this<br />
<img style="border:0 none;" src="https://lh3.googleusercontent.com/ir6mXJI6UoDt6ZYNenmevm6vsnXRTEE8UH2_9If2mbkUWZpNJ6Gt1Xpf-pRHxfLO6nI8gSOCWPn7J9NNXyW0EpBMGyOyp4gVLbC_F9Hm1CPGMMt2yl8" alt="" width="362px;" height="161px;" /><br />
This command is irreversible and the you will loose all the changes that are in your index.</li>
</ul>
]]></content:encoded>
</item>
<item>
<title><![CDATA[List files having conflicts on git]]></title>
<link>http://codephile.wordpress.com/2012/08/17/list-files-having-conflicts-on-git/</link>
<pubDate>Fri, 17 Aug 2012 20:47:24 +0000</pubDate>
<dc:creator>vighnesh1987</dc:creator>
<guid>http://codephile.wordpress.com/2012/08/17/list-files-having-conflicts-on-git/</guid>
<description><![CDATA[Credit: http://stackoverflow.com/questions/3065650/whats-the-simplest-way-to-git-a-list-of-conflicte]]></description>
<content:encoded><![CDATA[<p>Credit: http://stackoverflow.com/questions/3065650/whats-the-simplest-way-to-git-a-list-of-conflicted-files</p>
<p><script src="https://gist.github.com/3382467.js"></script></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Colorize your git output]]></title>
<link>http://codephile.wordpress.com/2012/08/17/colorize-your-git-output/</link>
<pubDate>Fri, 17 Aug 2012 20:28:24 +0000</pubDate>
<dc:creator>vighnesh1987</dc:creator>
<guid>http://codephile.wordpress.com/2012/08/17/colorize-your-git-output/</guid>
<description><![CDATA[Add this to your .git/config file to prettify the output that you see when you run `git status`, `gi]]></description>
<content:encoded><![CDATA[<p>Add this to your .git/config file to prettify the output that you see when you run `git status`, `git log`, etc</p>
<p><script src="https://gist.github.com/3375690.js"></script></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Git Internals - branches]]></title>
<link>http://robinnagpal.wordpress.com/2012/08/05/git-internals-branches/</link>
<pubDate>Sun, 05 Aug 2012 04:05:26 +0000</pubDate>
<dc:creator>robinnagpal</dc:creator>
<guid>http://robinnagpal.wordpress.com/2012/08/05/git-internals-branches/</guid>
<description><![CDATA[By reading this post you will have the understanding of the following points Some useful terminologi]]></description>
<content:encoded><![CDATA[<p>By reading this post you will have the understanding of the following points</p>
<ol>
<li>Some useful terminologies<br />
Master<br />
HEAD<br />
Branch</li>
<li>What do we mean by a branch in Git and why is it so easy and fast to create branches in Git</li>
<li>What are Local and Remote branches.</li>
<li>Some commands that help us to create and use branches.</li>
</ol>
<p>These pointers are going to provide us enough knowledge to use Git branching for our project.</p>
<p><strong>Master</strong><br />
This is the initial branch that is created when you initialize a repository. You can imagine it to be something like trunk that is there is SVN.</p>
<p><strong>HEAD</strong><br />
it is the reference of the current branch you have checked out. This is represented by the “HEAD” file that is present in the .git folder. If you cat the contents of the file you will see something like</p>
<pre class="brush: plain; title: ; notranslate" title="">
ref: refs/heads/master
</pre>
<p>This tells that our working copy points to the latest commit of master. Suppose you are in a branch “branch_1”, then the contents of the HEAD will be</p>
<pre class="brush: plain; title: ; notranslate" title="">
ref: refs/heads/branch_1
</pre>
<p><strong>Branch</strong><br />
As we have learned that every commit contains following things</p>
<ol>
<li>A reference to a single parent commit object, or to two parent commit objects, if that is a merge commit.</li>
<li>Reference to a tree object which further contains various blobs or further tree objects.</li>
<li>Some info regarding the commit i.e. author name, email, commit message etc.</li>
</ol>
<p>So every individual commit is capable of representing the complete snapshot of the project of the time the commit object was made, and it this commit object that makes the Git branching so easy, cheap and robust.</p>
<p>So a branch is nothing but a 40 character string that contains reference to the commit object.<br />
I can understand that it might have been hard to consume this knowledge till now, but stay will me for some more time, and I can assure you that once you get the understanding of the branching model, you will fall in love with it.</p>
<p>Let’s try to visualize this with diagrams</p>
<p>Suppose we have three commits “mc_1” ,”mc_2” and “mc_3” till now, and all of these are in the master.</p>
<p style="text-align:center;"><a href="http://robinnagpal.files.wordpress.com/2012/08/master.png"><img class="aligncenter  wp-image-41" style="border:0 none;" title="master" src="http://robinnagpal.files.wordpress.com/2012/08/master.png?w=346&#038;h=230" alt="" width="346" height="230" /></a><br />
We now decide to make a branch “branch_1” from master. To achieve this we execute the  following commands</p>
<pre class="brush: bash; title: ; notranslate" title="">
$ git branch branch_1
$ git checkout branch_1
</pre>
<p>Both of these commands can be combined into one command i.e.</p>
<pre class="brush: bash; title: ; notranslate" title="">
$ git checkout -b branch_1
</pre>
<p>Now our repository should look something like this</p>
<p style="text-align:center;"><a href="http://robinnagpal.files.wordpress.com/2012/08/branch_1.png"><img class="aligncenter size-medium wp-image-44" style="border:0 none;" title="branch_1" src="http://robinnagpal.files.wordpress.com/2012/08/branch_1.png?w=300&#038;h=300" alt="" width="300" height="300" /></a></p>
<p>We can now see that our HEAD points to “branch_1”, and we can confirm this by viewing the contents of HEAD file.</p>
<pre class="brush: bash; title: ; notranslate" title="">
$ cat .git/HEAD
ref: refs/heads/branch_1
</pre>
<p>If we see the contents of folder .git/refs/heads we see the following files</p>
<pre class="brush: plain; title: ; notranslate" title="">
branch_1
master
</pre>
<p>When we created the branch, a new file “branch_1” was created, which contains the SHA1 id of the “mc_3” commit. This is all what a branch is, i.e. a 40 character string that points to the latest commit in that branch.</p>
<p>Let’s now add and commit something to the branch.</p>
<pre class="brush: bash; title: ; notranslate" title="">
$ echo “Greeting !!” &#62; greeting.txt
$git add greeting.txt
$git commit -m “Our first commit to the branch” .
</pre>
<p>We now have our first commit in the branch. Below is how our repository looks like now.</p>
<p style="text-align:center;"><a href="http://robinnagpal.files.wordpress.com/2012/08/branch1_commit.png"><img class="aligncenter  wp-image-43" style="border:0 none;" title="branch1_commit" src="http://robinnagpal.files.wordpress.com/2012/08/branch1_commit.png?w=451&#038;h=309" alt="" width="451" height="309" /></a></p>
<p>Here “bc_1” is the new commit object of the new branch. If we check contents of the file .git/refs/branch_1 , we will see it containing the pointer to our new commit object i.e.  contains the SHA1 code of commit object bc_1.</p>
<p>Now let’s come back to the master branch and add something there.</p>
<pre class="brush: bash; title: ; notranslate" title="">
$git checkout master
$echo “Happy Birthday” &#62;wishes.txt
$ git add wishes.txt
$ git commit -m “Our first commit in master after creation of the branch” .
</pre>
<p>After this commit our repository will look something like this</p>
<p style="text-align:center;"><a href="http://robinnagpal.files.wordpress.com/2012/08/master_commit.png"><img class="aligncenter  wp-image-42" style="border:0 none;" title="master_commit" src="http://robinnagpal.files.wordpress.com/2012/08/master_commit.png?w=451&#038;h=355" alt="" width="451" height="355" /></a></p>
<p>So, we see how easy it is to make and manage branches in GIT. Once you start working with these branches, you will definitely fall in love with the way Git manages these branches.</p>
<p>Lets try to edit our greeting file and then switch to “branch_1”</p>
<pre class="brush: bash; title: ; notranslate" title="">
$echo “Merry Christmas”&#62;greeting.txt
$git checkout branch_1
</pre>
<p>When you execute the second command, you get the following error</p>
<pre class="brush: plain; title: ; notranslate" title="">
error: The following untracked working tree files would be overwritten by checkout:
greeting.txt
Please move or remove them before you can switch branches.
Aborting
</pre>
<p>Git asks to either commit or remove your changes before you switch to any other branch. This scenario seems to be trivial, where we can just commit or file and switch to another branch. But think of a real case scenario, where you will be having multiple file, which you don’t want to commit,  nor revert those changes. There is a git utility stash that helps you deal with with these type of scenarios.</p>
<p><strong>Local and Remote Branches   </strong><br />
Local branches are what we saw above and remote branches come into picture when you start working in a distributed manner. Since Git is a distributed version control system, you can easily pull and push contents from various team members who have the sane project git repository on their machine. All of this is done by using remote branches.</p>
<p>After reading the above examples you should be able to conceptualize that why is it so fast, easy and cheap to create branches in Git.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Git Internals - .git folder]]></title>
<link>http://robinnagpal.wordpress.com/2012/08/04/git-internals-git-folder/</link>
<pubDate>Sat, 04 Aug 2012 11:15:48 +0000</pubDate>
<dc:creator>robinnagpal</dc:creator>
<guid>http://robinnagpal.wordpress.com/2012/08/04/git-internals-git-folder/</guid>
<description><![CDATA[If you are one of those 80% of the people who just believe in getting the work done and don’t care a]]></description>
<content:encoded><![CDATA[<p>If you are one of those 80% of the people who just believe in getting the work done and don’t care about the internals, this blog is not for you. It is not that I am against the people who just believe in getting the work done, but it is that I can’t be one of them.</p>
<p>In this blog post I am going to highlight the way GIT tracks your files and how it maintains the versions of it. After reading these concepts you will have answer to the following questions</p>
<ol>
<li>Why is GIT called a distributed version control system.</li>
<li>Why creating and switching of branches is so fast in GIT</li>
<li>What happens internally when you commit, make a branch, move your code from one revision to other etc.</li>
</ol>
<p>Assuming that you have very basic or minimal knowledge of GIT, I am going to discuss some of the common terminologies that are common throughout various version control systems.</p>
<ul>
<li><strong>Repository</strong> this is where all your project is stored. This filesystem/directory has the complete knowledge of all the versions of the files that you want you version control system to track.</li>
<li><strong>Commit</strong> this is some kind of snapshot of the files you are tracking at that particular time. To make this snapshot identifiable, versions control systems generally attach some metadata to it.</li>
<li><strong>Branch</strong> this is where you decide to work upon a common code in different ways. After you create a branch, each branch is now independent of the other and has its own history, along with a common history of before the time the branch was created.</li>
</ul>
<p>Now lets get started by creating a repository first</p>
<pre class="brush: bash; title: ; notranslate" title=""> $git init </pre>
<p>Execute this command in the directory you want to be tracked by GIT.</p>
<p><strong>The GIT Repository</strong><br />
Let see the contents of this folder after the execution of above command,</p>
<pre class="brush: bash; title: ; notranslate" title=""> $ ls -latr </pre>
<p>We now see a new directory named .git inside this folder. Let’s see what’s inside this .git folder</p>
<pre class="brush: plain; title: ; notranslate" title="">

refs
info
hooks
HEAD
description
config
branches
objects

</pre>
<p>Everything that is tracked by GIT is present under this .git folder. This folder includes all the versions of your files, branches of your code, and pre/post scripts that you want GIT to run etc. Description of each of the above mentioned folders/files will help you understand how GIT is so efficient and the way git maintains various versions of the files internally.</p>
<p>Lets one by one see what is the role played by the above files and folders</p>
<p><strong>refs</strong> &#8211; This folder contains info of all the references to tags, branches, stash, head. Since, currently we have no remote or local branches, or any stash or tags, we will not be able to see all the contents of this directory. However, a typical git repository will have the following contents</p>
<pre class="brush: plain; title: ; notranslate" title="">

heads/
remotes/
tags/
stash
</pre>
<p><strong>info</strong> &#8211; This conspicuous part of this directory is the exclude file. We can edit this file to include the patterns of the files we don’t want to commit or to be tracked by GIT.</p>
<p><strong>hooks</strong> &#8211; This folders contains the scripts that we might wish to hook-in i.e. want to be executed before or after some operation, like we want to perform an operation before a commit, after a commit, after update etc. We can see some sample hooks already present in this folder</p>
<pre class="brush: plain; title: ; notranslate" title="">
applypatch-msg.sample
commit-msg.sample
post-commit.sample
post-receive.sample
post-update.sample
pre-applypatch.sample
pre-commit.sample
pre-rebase.sample
prepare-commit-msg.sample
update.sample

</pre>
<p><strong>HEAD</strong> &#8211; This includes the current ref we are looking at. In our case, since we are on the master itself, we see that the file contains the reference to master</p>
<pre class="brush: plain; title: ; notranslate" title="">
ref: refs/heads/master

</pre>
<p>If we were on a branch we could expect the contents to be something like this</p>
<pre class="brush: plain; title: ; notranslate" title="">

ref: refs/heads/production_fix

</pre>
<p>where “production_fix” is the name of the branch.</p>
<p><strong>description</strong> &#8211; As the name suggests, this files contains the description of the repository we have created. Since we have not entered any information in this file we see the following contents in the file.</p>
<pre class="brush: plain; title: ; notranslate" title="">
Unnamed repository; edit this file 'description' to name the repository.
</pre>
<p>Some of the GIT UI tools use this file to show the description of the repository to the user.<br />
<strong>config</strong> &#8211; This file contains the configurations specific to repository. We can change our username or email which will be used in the commit, by adding entry in this file. Current snapshot of our file looks like this.</p>
<pre class="brush: plain; title: ; notranslate" title="">

[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true

</pre>
<p><strong>branches</strong> a deprecated way to store the URL to git fetch, pull or push is to create a file in<br />
branches/&#60;name&#62;, and use that name to the command instead of repository parameter.</p>
<p><strong>objects</strong> &#8211; We can call this as the database of the git repository. Git mainly stores all its contents in three type of objects i.e. commit, tree, and blob. More details about these objects will be discussed in the next article.</p>
<p>With continued use of git for the project, there are a number of files are folder that are added by git in this .git directory. However, the folders and files mentioned above are enough to give you good understanding of GIT repository.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[GIT tutorials]]></title>
<link>http://cowboybkit.wordpress.com/2012/08/03/git-tutorials/</link>
<pubDate>Fri, 03 Aug 2012 08:28:51 +0000</pubDate>
<dc:creator>cowboybkit</dc:creator>
<guid>http://cowboybkit.wordpress.com/2012/08/03/git-tutorials/</guid>
<description><![CDATA[Tutorial 1: Switch changed code to new branch If you make some change on master branch and want to t]]></description>
<content:encoded><![CDATA[Tutorial 1: Switch changed code to new branch If you make some change on master branch and want to t]]></content:encoded>
</item>
<item>
<title><![CDATA[What the Git? ]]></title>
<link>http://jinacs.wordpress.com/2012/07/23/what-the-git/</link>
<pubDate>Mon, 23 Jul 2012 18:39:10 +0000</pubDate>
<dc:creator>jacobmoe</dc:creator>
<guid>http://jinacs.wordpress.com/2012/07/23/what-the-git/</guid>
<description><![CDATA[Trying to get started with Ruby on Rails &#8211; the popular web development language &#8211; I foun]]></description>
<content:encoded><![CDATA[<p>Trying to get started with <a href="http://en.wikipedia.org/wiki/Ruby_on_Rails">Ruby on Rails</a> &#8211; the popular web development language &#8211; I found <a href="http://eddorre.com/posts/rails-ultimate-install-guide-on-os-x-lion-using-rvm-homebrew-and-pow">this helpful but slightly out-of-date install guide</a> for getting setup on Mac OS X.  Follow the instructions, but get the software from the respective websites rather than using the download links provided.</p>
<p>One of the steps is installing something called &#8220;Git.&#8221; As it turns out, Git is an incredibly useful version control system, but it took some searching before I found a clear explanation for what exactly that means. Most explanations went something like: &#8220;Git is a lightweight version control system with an emphasis on speed.&#8221; But what is a version control system and how is it used? Luckily, I found these easy to follow screencasts with the basics to understand and get started using Git:<br />
<span class='embed-youtube' style='text-align:center; display: block;'><iframe class='youtube-player' type='text/html' width='640' height='390' src='http://www.youtube.com/embed/K2wBGt-j0fE?version=3&#038;rel=0&#038;fs=1&#038;showsearch=0&#038;showinfo=1&#038;iv_load_policy=1&#038;wmode=transparent' frameborder='0'></iframe></span><br />
<span class='embed-youtube' style='text-align:center; display: block;'><iframe class='youtube-player' type='text/html' width='640' height='390' src='http://www.youtube.com/embed/0BIGxolZQHo?version=3&#038;rel=0&#038;fs=1&#038;showsearch=0&#038;showinfo=1&#038;iv_load_policy=1&#038;wmode=transparent' frameborder='0'></iframe></span><br />
<span class='embed-youtube' style='text-align:center; display: block;'><iframe class='youtube-player' type='text/html' width='640' height='390' src='http://www.youtube.com/embed/ojVzmIp6Xv0?version=3&#038;rel=0&#038;fs=1&#038;showsearch=0&#038;showinfo=1&#038;iv_load_policy=1&#038;wmode=transparent' frameborder='0'></iframe></span><br />
<span class='embed-youtube' style='text-align:center; display: block;'><iframe class='youtube-player' type='text/html' width='640' height='390' src='http://www.youtube.com/embed/pv25aLwYpEU?version=3&#038;rel=0&#038;fs=1&#038;showsearch=0&#038;showinfo=1&#038;iv_load_policy=1&#038;wmode=transparent' frameborder='0'></iframe></span></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Deployment through Capistrano]]></title>
<link>http://fan0o.wordpress.com/2012/07/04/deployment-through-capistrano/</link>
<pubDate>Wed, 04 Jul 2012 07:25:39 +0000</pubDate>
<dc:creator>fan0o</dc:creator>
<guid>http://fan0o.wordpress.com/2012/07/04/deployment-through-capistrano/</guid>
<description><![CDATA[Install gem gem install capistrano Generate a key ssh-keygen Copy  the key without white spaces or a]]></description>
<content:encoded><![CDATA[Install gem gem install capistrano Generate a key ssh-keygen Copy  the key without white spaces or a]]></content:encoded>
</item>
<item>
<title><![CDATA[Git Cheat sheet]]></title>
<link>http://fan0o.wordpress.com/2012/06/26/git-cheat-sheet/</link>
<pubDate>Tue, 26 Jun 2012 13:30:57 +0000</pubDate>
<dc:creator>fan0o</dc:creator>
<guid>http://fan0o.wordpress.com/2012/06/26/git-cheat-sheet/</guid>
<description><![CDATA[Setup ----- git clone &lt;repo&gt; clone the repository specified by &lt;repo&gt;; this is similar t]]></description>
<content:encoded><![CDATA[Setup ----- git clone &lt;repo&gt; clone the repository specified by &lt;repo&gt;; this is similar t]]></content:encoded>
</item>
<item>
<title><![CDATA[Git Primer]]></title>
<link>http://metacognitionmission.wordpress.com/2012/06/25/git-primer/</link>
<pubDate>Mon, 25 Jun 2012 18:57:53 +0000</pubDate>
<dc:creator>hctahkram</dc:creator>
<guid>http://metacognitionmission.wordpress.com/2012/06/25/git-primer/</guid>
<description><![CDATA[Quick reference guide for useful Git commands Based off the Git Book I wrote this when I was told to]]></description>
<content:encoded><![CDATA[<h1><span style="text-decoration:underline;">Quick reference guide for useful Git commands</span></h1>
<h3>Based off the <a href="git-scm.com/boo">Git Book</a></h3>
<p>I wrote this when I was told to learn Git for work.</p>
<h3><span style="text-decoration:underline;"><strong>Index</strong></span></h3>
<h6><span style="text-decoration:underline;">1. Git Basics</span></h6>
<h6><span style="text-decoration:underline;">2. States of Files</span></h6>
<h6><span style="text-decoration:underline;">3.</span><span style="text-decoration:underline;"> <strong>Getting and Creating Projects</strong></span></h6>
<ul>
<li>
<h6>Initializing Git Repository</h6>
</li>
<li>
<h6>Cloning an Existing Repository</h6>
</li>
</ul>
<h6><span style="text-decoration:underline;">4. <strong>Basic Snapshotting</strong></span></h6>
<ul>
<li>
<h6>Checking Status of your files</h6>
</li>
<li>
<h6>Tracking new files</h6>
</li>
<li>
<h6>Ignoring Files</h6>
</li>
<li>
<h6>Viewing Changes</h6>
</li>
<li>
<h6>Committing your Changes</h6>
</li>
<li>
<h6>Removing Files</h6>
</li>
<li>
<h6>Moving Files</h6>
</li>
</ul>
<h6><span style="text-decoration:underline;">5. <strong>Viewing the Commit History</strong></span></h6>
<ul>
<li>
<h6>Limiting Log Output</h6>
</li>
<li>
<h6>Using a GUI</h6>
</li>
</ul>
<h6><span style="text-decoration:underline;">6. <strong>Undoing Things</strong></span></h6>
<ul>
<li>
<h6>Changing Your Last Commit</h6>
</li>
<li>
<h6>Unstaging a File</h6>
</li>
<li>
<h6>Unmodifying a Modified File</h6>
</li>
</ul>
<h6><span style="text-decoration:underline;">7. <strong>Working with Remotes</strong></span></h6>
<ul>
<li>
<h6>Showing your Remotes</h6>
</li>
<li>
<h6>Adding Remote Repositories</h6>
</li>
<li>
<h6>Fetching and Pulling from your Remotes</h6>
</li>
<li>
<h6>Pushing to your Remotes</h6>
</li>
<li>
<h6>Inspecting a Remote</h6>
</li>
<li>
<h6>Removing and Renaming Remotes</h6>
</li>
</ul>
<h6><span style="text-decoration:underline;">8. <strong>Tagging</strong></span></h6>
<ul>
<li>
<h6>Viewing Tags</h6>
</li>
<li>
<h6>Viewing Tag Data</h6>
</li>
<li>
<h6>Creating Annotated Tags</h6>
</li>
<li>
<h6>Signed Tags</h6>
</li>
<li>
<h6>Lightweight Tags</h6>
</li>
<li>
<h6>Verifying Tags</h6>
</li>
<li>
<h6>Tagging Older Commits</h6>
</li>
<li>
<h6>Pushing Tags to Remote</h6>
</li>
</ul>
<h6><span style="text-decoration:underline;">9. <strong>Basic Branching and Merging</strong></span></h6>
<ul>
<li>
<h6>Create a Branch</h6>
</li>
<li>
<h6>Merging Branches</h6>
</li>
<li>
<h6>Deleting Branches</h6>
</li>
<li>
<h6>Branch Management</h6>
</li>
</ul>
<h6><span style="text-decoration:underline;">10. <strong>Branching Workflow</strong></span></h6>
<h6><span style="text-decoration:underline;">11.<strong> Remote Branches</strong></span></h6>
<ul>
<li>
<h6>Pushing</h6>
</li>
<li>
<h6>Tracking Branches</h6>
</li>
<li>
<h6>Deleting Remote Branches</h6>
</li>
</ul>
<h6><span style="text-decoration:underline;">12. <strong>Rebasing</strong></span></h6>
<ul>
<li>
<h6>The Basic Rebase</h6>
</li>
<li>
<h6>More Complex Rebasing</h6>
</li>
<li>
<h6>Drawbacks of Rebasing</h6>
</li>
</ul>
<h3><span style="text-decoration:underline;">1. Git Basics</span></h3>
<ul>
<li>
<h6>Git takes snapshots of your commits, rather than saving differences. Acts more like a mini filesystem.</h6>
</li>
<li>
<h6>Nearly every opertaion is local. You don&#8217;t need to be online to make commits.</h6>
</li>
<li>
<h6>Git uses checksums for lots of things, including identifying commits.</h6>
</li>
<li>
<h6>Git generally only adds data. It is hard to get the system to do anything that is not undoable or make it erase data in any way.</h6>
</li>
</ul>
<h3><span style="text-decoration:underline;">2. States of Files</span></h3>
<ul>
<li>
<h6>Modify the Files -&#62; Stage the Files -&#62; Commit The Files</h6>
</li>
<li>
<h6>Unstaged (Unmodified) -&#62; Unstaged (Modified) -&#62; Staged Files ( <strong><em>git add</em></strong>) -&#62; Committed ( <strong><em>git commit</em></strong>)</h6>
</li>
</ul>
<h3><span style="text-decoration:underline;">3. Getting and Creating Projects</span></h3>
<h4><strong>Initializing Git Repository</strong></h4>
<p>To start tracking an project. This creates all the necessary repository files. (Nothing will be tracked yet!)</p>
<p><strong><em>git init</em></strong></p>
<h4>Cloning an Existing Repository</h4>
<p>Different from checkout. Cloning copies almost all data on a repository. Includes all previous versions of every file in the project.</p>
<p><strong><em>git clone [url]</em></strong></p>
<h3></h3>
<h3></h3>
<h3><span style="text-decoration:underline;">4. Basic Snapshotting</span></h3>
<h5>Checking Status of your files</h5>
<p><strong><em>git status</em></strong></p>
<h5><em>Tracking new files</em></h5>
<p><em><strong>git add &#60;file&#62;</strong><br />
</em></p>
<h5><em>Ignoring Files</em></h5>
<p>This is generally for ignoring automatically generated files.</p>
<p>You can do this by creating/editing the <strong>.gitignore </strong>file.</p>
<p>Rules for patterns you can put into <strong>.gitignore</strong>:</p>
<ul>
<li>Blank lines or lines starting with # are ignored.</li>
<li>Standard glob patterns work.
<ul>
<li>* &#8211; matches zero or more characters</li>
<li>[abc] &#8211; matches any character inside the brackets (a,b,c in this case)</li>
<li>? &#8211; matches a single character</li>
<li>[0-9] &#8211; matches any characters in range within bracket.</li>
</ul>
</li>
<li>You can end patterns with a forward slash ( /) to specify a directory.</li>
<li>You can negate a pattern by starting it with an exclamation point ( !).</li>
</ul>
<h5>Viewing changes</h5>
<p>To see changes that are not yet staged.</p>
<p><strong><em>git diff</em></strong></p>
<p><em><strong>&#8211;cached</strong> or <strong>&#8211;staged</strong> - </em>Shows what you&#8217;ve staged that will go into the next commit.</p>
<h5>Commiting your changes</h5>
<p><strong><em>git commit</em></strong></p>
<p><em><strong>-a</strong> </em>- makes Git automatically stages every file that is tracked. (Otherwise you need to <em>git add</em> each file),</p>
<p><strong><em>-v</em></strong> - shows diff in changelog so you can see exactly what you did (is removed when the commit is created).</p>
<p><strong><em>-m</em></strong> - inline commit &#124; ex. git commit -m &#8220;Story 182: Destroyed all the bug monsters&#8221;</p>
<h5>Removing Files</h5>
<p><strong><em>git rm &#60;file&#62;</em></strong></p>
<p><strong><em>-f </em>- </strong>force removal, used if file was modified and added to index already</p>
<p><strong>&#8211;cached </strong>- keep file in working tree, but remove git tracking.</p>
<p>Git does its own filename expansion in addition to your shell, see example below.</p>
<p><em><strong>ex: </strong>git rm log/\*.log</em> - <span style="text-decoration:underline;">backslash is necessary</span> (removes all files in log directory with .log extension)</p>
<h5>Moving Files</h5>
<p>Git doesn&#8217;t explicitly track file movement. If you rename a file in Git, it won&#8217;t know.</p>
<p><strong><em>git mv file_from file_to</em></strong></p>
<p>OR you can remove old file from tracking and add new one. ( <em>git rm, git add)</em></p>
<p><em><br />
</em></p>
<h3><span style="text-decoration:underline;">5. Viewing the Commit History</span></h3>
<p><strong><em>git log</em></strong></p>
<p><em><strong>-p</strong> </em>- shows the diff introduced in each commit</p>
<p><strong>-&#60;n&#62; </strong>- limits the output to the last n entries if diffed</p>
<p><strong>&#8211;stat </strong>- abbreviated stats</p>
<p><strong>&#8211;shortstat</strong> - display only changed/insertions/deletions from &#8211;stat</p>
<p><strong>&#8211;name-only </strong>- list of files modified</p>
<p><strong>&#8211;name-status </strong>- shows the list of files affected with added/modified/deleted information</p>
<p><strong>&#8211;abbrev-commit </strong>- abbreviates checksum</p>
<p><strong>&#8211;relative-date </strong>- displays date relative to today (&#8220;2 weeks ago&#8221;)</p>
<p><strong>&#8211;pretty </strong>- allows formatting of log output</p>
<p><strong>=oneline </strong>- prints each commit on single line</p>
<p><strong>=short</strong></p>
<p><strong>=full</strong></p>
<p><strong>=fuller</strong></p>
<p><strong>&#8211;graph </strong>- ASCII graph showing branch and merge history</p>
<h5>Limiting Log Output</h5>
<p><strong><em>git log</em></strong></p>
<p><strong>&#8211;since, &#8211;after</strong> - Limit the commits made after date ( <strong>ex.</strong> <em>git log &#8211;since=2.weeks or &#8211;since=&#8221;2008-10-01&#8243;</em>)</p>
<p><strong>&#8211;until, &#8211;before</strong> - Limits the commits to before date</p>
<p><strong>&#8211;author</strong> - only shows commits which author entry matches string</p>
<p><strong>&#8211;comitter</strong> - only shows commits which committer entry matches string</p>
<p><strong>&#8211;grep</strong> - search for keywords in commit messages</p>
<p><strong>&#8211;all-match </strong>- specifies that all log limiters must be true (ex. when searching author and grep, otherwise it will match all commits with either.)</p>
<p><strong>&#8211;&#60;dir&#62;, &#8211;&#60;file&#62; </strong>- always the last option, only shows commits relative to a directory or file.</p>
<p><strong>&#8211;no-merges</strong> - don&#8217;t show merges</p>
<h5>Using a GUI to Visualize History</h5>
<p><strong><em>gitk</em></strong></p>
<p>Opens GUI interface for viewing git log.</p>
<h4><span style="text-decoration:underline;">6. Undoing Things</span></h4>
<h5>Changing your last Commit</h5>
<p><strong><em>git commit &#8211;amend</em></strong></p>
<p>Takes your staging area and uses it for the commit.</p>
<h5>Unstaging a file</h5>
<p><strong><em>git reset HEAD &#60;file&#62;</em></strong></p>
<p>Unstages a modified file in git.</p>
<h5>Unmodifying a Modified File</h5>
<p><strong><em>git checkout &#8212; &#60;file&#62;</em></strong></p>
<p>Reverts any changes on a specific file.</p>
<h4><span style="text-decoration:underline;">7. Working with Remotes</span></h4>
<h5>Showing your Remotes</h5>
<p><strong><em>git remote</em></strong></p>
<p><em>*-v* -</em> shows URLs and lists all remotes</p>
<h5>Adding Remote Repositories</h5>
<p>Add a remote repository with your custom shortname</p>
<p><strong><em>git remote add [shortname] [url]</em></strong></p>
<h5>Fetching and pulling from your Remotes</h5>
<p>Pull all data from remote project that you don&#8217;t have. Doesn&#8217;t automatically merge.</p>
<p><strong><em>git fetch [remote-name]</em></strong></p>
<p>Pull all data from remote project that you don&#8217;t have. Automatically try to merge.</p>
<p><strong><em>git pull</em></strong></p>
<h5>Pushing to Your Remotes</h5>
<p>Push your changes to the remote repository, must have write access.</p>
<p><strong><em>git push [remote-name] [branch-name]</em></strong></p>
<h5>Inspecting a Remote</h5>
<p>View more information about a remote repository.</p>
<p><strong><em>git remote show [remote-name]</em></strong></p>
<h5></h5>
<h5>Removing and Renaming Remotes</h5>
<p>Change remote&#8217;s shortname</p>
<p><em><strong>git remote rename &#60;old shortname&#62; &#60;new shortname&#62;<br />
</strong></em></p>
<p>Remove a reference to remote repository</p>
<p><strong><em>git remote rm</em></strong> <strong>&#60;shortname&#62;</strong></p>
<p><span style="text-decoration:underline;"><br />
</span></p>
<h4><span style="text-decoration:underline;">8. Tagging</span></h4>
<h5>Viewing Tags</h5>
<p><strong><em>git tag</em></strong></p>
<h5>Viewing Tag Data</h5>
<p><strong><em>git show</em></strong> &#60;<em><strong>tag name&#62;</strong></em></p>
<h5></h5>
<h5>Creating Annotated Tags</h5>
<p>This is the most common type of commit. It adds a message to describe the tag,</p>
<p><strong><em>git tag -a &#60;name of tag&#62; -m &#60;tag message&#62;</em></strong></p>
<h5>Signed Tags</h5>
<p><strong><em>git tag -s &#60;name of tag&#62; -m &#60;tag message&#62;</em></strong></p>
<h5>Lightweight Tags</h5>
<p>Only contains the commit checksum.</p>
<p><strong><em>git tag &#60;tagname&#62;</em></strong></p>
<h5>Verifying Tags</h5>
<p><strong><em>git tag -v [tag name]</em></strong></p>
<h5>Tagging Older Commits</h5>
<p>To tag old commits, simply add the commit checksum of the paticular commit at the end of the command.</p>
<p><strong><em>git tag -a &#60;tag name&#62; &#60;commit checksum&#62;</em></strong></p>
<h5>Pushing Tag<em>s </em>to Remote</h5>
<p>Git does not transfer tags by default to the remote repository.</p>
<p><strong><em>git push &#60;repository shortname&#62; &#60;tagname&#62;</em></strong></p>
<p><em><strong>&#8211;tags - </strong></em>push all tags to remote server</p>
<h4><span style="text-decoration:underline;">9. Basic Branching and Merging</span></h4>
<p>For more detailed info:</p>
<p><a href="http://git-scm.com/book/en/Git-Branching-Basic-Branching-and-Merging" rel="nofollow">http://git-scm.com/book/en/Git-Branching-Basic-Branching-and-Merging</a></p>
<h5>Create a Branch</h5>
<p>Creates a branch off the current tree.</p>
<p><strong><em>git branch &#60;branch name&#62;</em></strong></p>
<p>This does not switch to the branch however, you still need to perform a checkout to do that.</p>
<p><strong>OR</strong></p>
<p><strong><em>git checkout -b &#60;branch name&#62;</em></strong></p>
<p>This will create a new branch and switch to it.</p>
<h5>Merging Branches</h5>
<p>Merges branch specified with the branch you are currently on.</p>
<p><strong><em>git merge &#60;branch to merge&#62;</em></strong></p>
<h5>Deleting Branches</h5>
<p><strong><em>git branch -d &#60;branch name&#62;</em></strong></p>
<h5>Branch Management</h5>
<p><strong><em>git branch</em></strong></p>
<p><em><strong>-v - </strong></em>show last commit on each branch</p>
<p><em><strong>&#8211;merged - </strong></em>See what branches have already merged into the branch you are on.</p>
<p><em><strong>&#8211;no-merged - </strong></em>Opposite of <strong><em>&#8211;merged</em></strong></p>
<h3></h3>
<h3><span style="text-decoration:underline;">10. Branching Workflow</span></h3>
<p>To learn more about using branches in your workflow:</p>
<p><a href="http://git-scm.com/book/en/Git-Branching-Branching-Workflows" rel="nofollow">http://git-scm.com/book/en/Git-Branching-Branching-Workflows</a></p>
<h3><span style="text-decoration:underline;">11. </span><span style="text-decoration:underline;">Remote Branches</span></h3>
<p>They&#8217;re local branches that you can&#8217;t move; moved automatically whenever you do any network communication. They act as bookmarks to remind you where the branches on your remote repositories were the last time you connected to them.Simple pointers.</p>
<p>Here is a the detailed explanation with diagrams and examples:</p>
<p><a href="http://git-scm.com/book/en/Git-Branching-Remote-Branches" rel="nofollow">http://git-scm.com/book/en/Git-Branching-Remote-Branches</a></p>
<h4>Pushing</h4>
<p>Must have write access.</p>
<p>This isn&#8217;t done automatically.</p>
<p>To push up a branch <strong><em>git push (remote) (branch)</em></strong></p>
<p>Can also do: <strong><em>git push (remote) (local branch name):(desired remote branch name)</em></strong></p>
<p>When you do a fetch of new remote branches, you don&#8217;t automatically have a local editable copy.</p>
<p>To get a local branch, must check it out.</p>
<p><strong><em>git checkout -b (desired branch name) (remote)/(branch)</em></strong></p>
<h4>Tracking Branches</h4>
<p>These are local branches that have a direct relationship to a remote branch. This is useful for when you type git push/pull, Git will automatically know which server and branch to push/pull from.</p>
<p><strong><em>git checkout &#8211;track origin/serverfix</em></strong></p>
<h4>Deleting Remote Branches</h4>
<p><strong><em>git push (remote) <img src='http://s0.wp.com/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> branch)</em></strong></p>
<p><em><strong><br />
</strong></em></p>
<h3><span style="text-decoration:underline;">12. Rebasing</span></h3>
<p>An alternate way to integrate changes from one branch into another, other than merge.</p>
<h4>The Basic Rebase</h4>
<p>Rather than merging in two branches together. Rebasing simply takes any changes on a branch and &#8220;replays&#8221; or &#8220;patches&#8221; it ontop of the other.</p>
<p>This is exactly the same as <strong><em>merge</em></strong> however, your git history will now be linear and cleaner. No longer having branch divergences.</p>
<p><strong><em>git checkout branch</em></strong></p>
<p><strong><em>git rebase master</em></strong></p>
<p><strong><em>git checkout master</em></strong></p>
<p><strong><em>git merge branch</em></strong></p>
<p>Basically take the branches changes, apply them onto master, switch to the master, and fast forward.</p>
<p>Now the branch changes are integrated onto the end of the master changes, and the master pointer has moved to accomodate those changes.</p>
<h4>More Complex Rebasing</h4>
<p>For diagrams and more details: http://git-scm.com/book/en/Git-Branching-Rebasing</p>
<p>If you have multiple branches, you can do more complex rebasing using the <em><strong>&#8211;onto </strong></em>option of <strong><em>rebase</em></strong>.</p>
<p><strong><em>ex: git rebase &#8211;onto master server client</em></strong></p>
<p>What this does is figure out the patches from the <strong>common ancestors</strong> of the client and server branches, and replay them onto master.(Along with all the client changes).</p>
<p>In this example case, the client has some common ancestry with the server branch. This is useful if you want to integrate the client changes, without integrating the server changes, while still keeping the common changes that are necessary for the client branch to be implemented. See the link for diagrams.</p>
<h4>Drawbacks of Rebasing</h4>
<p><strong>DO NOT REBASE COMMITS THAT YOU HAVE PUSHED TO A PUBLIC REPOSITORY.</strong></p>
<p>Rebasing changes the commit hashes, making it look like commits that have already have been committed look new. Causing everyone to have to remerge their old work in.</p>
<p>Use rebasing as a way to clean up and work with commits <strong>BEFORE</strong> you push them.</p>
<p><strong><br />
</strong></p>
<p><em><br />
</em></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Installing Git on Mac OS X]]></title>
<link>http://vandadnp.wordpress.com/2012/06/24/installing-git-on-mac-os-x/</link>
<pubDate>Sun, 24 Jun 2012 15:59:49 +0000</pubDate>
<dc:creator>VandadNP</dc:creator>
<guid>http://vandadnp.wordpress.com/2012/06/24/installing-git-on-mac-os-x/</guid>
<description><![CDATA[If you want to install Git on your OS X Lion, whether you have Xcode or not, you can head to: http:/]]></description>
<content:encoded><![CDATA[If you want to install Git on your OS X Lion, whether you have Xcode or not, you can head to: http:/]]></content:encoded>
</item>
<item>
<title><![CDATA[GIT: How to add and remove tags]]></title>
<link>http://lostintechworld.wordpress.com/2012/06/22/git-how-to-add-and-remove-tags/</link>
<pubDate>Fri, 22 Jun 2012 01:00:22 +0000</pubDate>
<dc:creator>Aqua23</dc:creator>
<guid>http://lostintechworld.wordpress.com/2012/06/22/git-how-to-add-and-remove-tags/</guid>
<description><![CDATA[To add tags: If your tag is named v1.1 : -  git tag -a v1.1 -m &#8220;Version 1.1&#8243; - git push]]></description>
<content:encoded><![CDATA[<p><strong>To add tags:</strong></p>
<p>If your tag is named v1.1 :</p>
<p>-  git tag -a v1.1 -m &#8220;Version 1.1&#8243;</p>
<p>- git push &#8211;tags</p>
<p><strong>To remove tags:</strong></p>
<p>If your tag is named v1.1</p>
<p>- git tag -d v1.1</p>
<p>This will remove from remote repository:</p>
<p>- git push origin :refs/tags/v1.1</p>
<p>&#160;</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Git: How to remove a submodule]]></title>
<link>http://lostintechworld.wordpress.com/2012/06/05/git-how-to-remove-a-submodule/</link>
<pubDate>Tue, 05 Jun 2012 22:08:37 +0000</pubDate>
<dc:creator>Aqua23</dc:creator>
<guid>http://lostintechworld.wordpress.com/2012/06/05/git-how-to-remove-a-submodule/</guid>
<description><![CDATA[1. Delete the relevant section from the .gitmodules file. For eg. I want to delete &#8220;TestModule]]></description>
<content:encoded><![CDATA[<p>1. Delete the relevant section from the <code>.gitmodules</code> file.</p>
<div>For eg. I want to delete &#8220;TestModule&#8221; Submodule:</div>
<div>- Go to root directory of git repository</div>
<div>- Run nano .gitmodules</div>
<div>- Delete submodule,path and url section pertaining to &#8220;TestModule&#8221; submodule</div>
<div>
<p>[submodule "TestProj/Classes/TestModule"]<br />
path = TestProj/Classes/TestModule<br />
url = <a href="https://github.com/hrastogi/TestModule.git" rel="nofollow">https://github.com/hrastogi/TestModule.git</a></p>
<p>2. Delete the relevant section from <code>.git/config</code>.</p>
<div>For eg.</div>
<div>- Go to root directory of git repository</div>
<div>- Run nano .git/config</div>
<div>- Delete submodule and url section pertaining to &#8220;TestModule&#8221; submodule</div>
<div>
<p>[submodule "TestProj/Classes/TestModule"]<br />
url = <a href="https://github.com/hrastogi/TestModule.git" rel="nofollow">https://github.com/hrastogi/TestModule.git</a></p>
</div>
<p>3. Run <code>git rm --cached path_to_submodule</code> (no trailing slash).</p>
<p>For eg:</p>
<p>- rm &#8211;cached  TestProj/Classes/TestModule</p>
<p>4. Commit and delete the now untracked submodule files i.e delete &#8220;TestModule&#8221; directory locally.</p>
<p>Refer : <a title="Delete Submodule" href="http://stackoverflow.com/questions/1260748/how-do-i-remove-a-git-submodule" target="_blank">Delete Submodule</a></p>
</div>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Changing URL for Remote]]></title>
<link>http://myrailslearnings.wordpress.com/2012/05/06/changing-url-for-remote/</link>
<pubDate>Mon, 07 May 2012 01:26:11 +0000</pubDate>
<dc:creator>admin</dc:creator>
<guid>http://myrailslearnings.wordpress.com/2012/05/06/changing-url-for-remote/</guid>
<description><![CDATA[I changed the hosting of my repo from Github to Bitbucket.  I like Bitbucket because not only does i]]></description>
<content:encoded><![CDATA[<p>I changed the hosting of my repo from Github to Bitbucket.  I like Bitbucket because not only does it house the code and history, but also it ties in with a bug tracker that allows for tracking (and assigning) of bugs, but also collaboration with developers.</p>
<p>To remap my remote repo, I did this:</p>
<p>git remote set-url [example] [git://github.com/user/test.git]</p>
<p>where:</p>
<p>[example] = repo name</p>
<p>[git://github.com/user/test.git] = new repo url</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Git Commands]]></title>
<link>http://myrailslearnings.wordpress.com/2012/05/06/git-commands/</link>
<pubDate>Sun, 06 May 2012 19:19:02 +0000</pubDate>
<dc:creator>admin</dc:creator>
<guid>http://myrailslearnings.wordpress.com/2012/05/06/git-commands/</guid>
<description><![CDATA[Here are the git commands I use most often (I use git GUI so I don&#8217;t usually type the commands]]></description>
<content:encoded><![CDATA[<p>Here are the git commands I use most often (I use git GUI so I don&#8217;t usually type the commands git add, git commit, &#38; git push to move files):</p>
<ul>
<li>git branch &#8211; tells you what branch you are currently in</li>
<li>git checkout <!-- Missing Branch URL --> &#8211; switch branches</li>
<li>git merge <!-- Missing Branch URL --> &#8211; bring in the code from the named branch, into the current branch</li>
<li>git pull [repository] <!-- Missing Branch URL --> &#8211; pull my files</li>
<li>git push [repository] <!-- Missing Branch URL --> &#8211; push my files</li>
<li>git stash &#8211; store local changes (usually when there is a merge conflict)</li>
<li>git stash apply (retrieve the stashed local changes)</li>
</ul>
<p>for me:<br />
[repository] = origin<br />
<!-- Missing Branch URL --> = master and dev</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Using Git with Github on Windows]]></title>
<link>http://sinairv.wordpress.com/2012/05/05/using-git-with-github-on-windows/</link>
<pubDate>Sat, 05 May 2012 04:20:32 +0000</pubDate>
<dc:creator>Sina Iravanian</dc:creator>
<guid>http://sinairv.wordpress.com/2012/05/05/using-git-with-github-on-windows/</guid>
<description><![CDATA[If you&#8217;re new to Git and don&#8217;t know how to install Git on Windows, read my earlier post:]]></description>
<content:encoded><![CDATA[<p>If you&#8217;re new to Git and don&#8217;t know how to install Git on Windows, read my earlier post: <a href="http://sinairv.wordpress.com/2012/05/01/how-to-setup-git-for-windows/">How to Setup Git for Windows</a></p>
<p>In an earlier <a href="http://sinairv.wordpress.com/2012/05/04/using-git-with-codeplex-on-windows/">post</a>, I described the preliminary steps required to work with git on CodePlex. However using git with <a href="https://github.com">Github</a> requires more initial steps.</p>
<p><strong>Generating SSH Keys.</strong> Before proceeding to Git operations we need to create SSH public and private keys, and register the public key on the Github site. In order to generate the keys we can use <em>PuTTY Key Generator</em>, which is already bundled with TortoiseGit fortunately. This program is called &#8220;<em>Puttygen</em>&#8221; and can be found in start-menu under TortoiseGit:</p>
<p><img src="http://sinairv.files.wordpress.com/2012/05/tortoisegit-puttygen.png" alt="puttygen under TortoiseGit in Windows start-menu" /></p>
<p>After running Puttygen you need to press &#8220;<em>Generate</em>&#8220;, and make some crazy mouse movements in the spotted area to provide some random data for the program (wow, what a brilliant idea). When finished you will have the public key generated. It is recommended that you provide a <em>passphrase</em> so that you would have a more secure private key. After that save your public and private keys using the 2 save buttons near the bottom of the window. But these are not all that you need to save! The public key format that Github and some other applications require you to provide is not the one that this program has saved for you. The topmost field which is labeled &#8220;<em>Public key for passing into OpenSSH authorized_keys file</em>&#8221; is the one that Github needs. It should be in one line (i.e., with no line-breaks), therefore we would refer to it later as the <em>one-line-public-key</em>. Please save the contents of this field and the next &#8220;<em>key fingerprint</em>&#8221; field somewhere for future references.  </p>
<p><img src="http://sinairv.files.wordpress.com/2012/05/puttygenfields.png" alt="Puttygen fields" /></p>
<p><strong>Registering SSH Keys in Github.</strong> Browse to Github, and go to your <em>Account Seetings</em>, and select <em>SSH Keys</em> therein. Press the <em>Add SSH key</em> button on the right. Provide a name for the key (I chose TortoiseGit), and paste the <em>one-line-public-key</em> in the <em>Key</em> field. Press <em>Add Key</em>. You may be prompted for your Github account password next. When finished, Github adds this key to its list of keys and provides a fingerprint. Make sure this fingerprint matches the <em>key fingerprint</em> that <em>Puttygen</em> created for you.</p>
<p><strong>Creating a Repository in Github.</strong> Browse to the Github page and press the &#8220;<em>Create a New Repo</em>&#8221; button at the top of the page.</p>
<p><img src="http://sinairv.files.wordpress.com/2012/05/githubnewrepo.png" alt="Github Create New Repo" /></p>
<p>In the new form that appears, enter desired values for your project&#8217;s name and description. Currently there&#8217;s an option to add a README file or an appropriate <code>.gitignore</code> file to the repository. While making use of these options are recommended, in this tutorial I intend to start from a completely empty repository; therefore I unchecked those options. When finished press the &#8220;<em>Create repository</em>&#8221; button. With these steps I created a project called &#8220;<em>PdfRenamer</em>&#8220;.</p>
<p><strong>Setting up TortoiseGit for the new project.</strong> After creating the repository, Github introduces some helpful basic commands to start working with the repository. We don&#8217;t intend to use the command-line, however this page contains useful information such as user-name and email with which Github recognizes you, and the git repository address, as highlighted below:</p>
<p><img src="http://sinairv.files.wordpress.com/2012/05/githubnewprojectaddressandusername1.png" alt="Github New Project Address And User-Name" /></p>
<p>We need to do the following steps next:</p>
<ol>
<li>Right click somewhere in the Windows explorer window, and from the context-menu go to: <em>TortoiseGit &#62; Settings &#62;&#62; Git branch</em>; and fill the user-name and email fields with the ones suggested by Github, and press OK.</li>
<li>Create a folder preferably with the same name as your project (in my case <em>PdfRenamer</em>), and browse into it with Windows explorer.</li>
<li>Right click somewhere in the folder and from the context menu select &#8220;<em>Git Create repository here&#8230;</em>&#8220;. A window pops-up. Make sure that &#8220;<em>Make it Bare</em>&#8221; is <em>not</em> checked; and press OK.</li>
<li>Right click somewhere in the folder and from the context menu go to:  <em>TortoiseGit &#62; Settings &#62;&#62; Git branch &#62;&#62; Remote sub-branch</em>. In the &#8220;<em>Remote</em>&#8221; field enter &#8220;<em>origin</em>&#8220;, in the URL field enter the <em>git repository address</em> which was highlighted above and is in the form of <code>git@github.com:[username]/[projectname].git</code>; and finally in front of &#8220;<em>putty key</em>&#8221; provide the address to the <em>SSH private key</em> which we saved earlier in this tutorial, and has the <code>.ppk</code> extension. When finished press the &#8220;<em>Add New/Save</em>&#8221; button. After that <em>origin</em> should be added to the list of Remotes.</li>
</ol>
<p><img src="http://sinairv.files.wordpress.com/2012/05/tortoisegitremotesetting.png" alt="TortoiseGit Remote Setting" /></p>
<p><strong>Add files to the project structure.</strong> With git, adding a file to a project structure and having it reflected in the remote repository requires 3 operations: <em>add</em>, <em>commit</em>, and <em>push</em>. The first 2 operations are required for adding the file to the local repository, and the third one reflects the changes to the remote repository. This last operation can be postponed to a later time when you want to <em>push</em> a bundle of changes all at once.</p>
<p>To start, create a <code>Readme.txt</code> file in the root folder. Right click on the newly added file, from the context menu select: <em>TortoiseGit &#62; add</em>; check the files to be added, and press OK. This was the first operation: <em>add</em>. In the new window press &#8220;<em>commit &#8230;</em>&#8220;, provide a meaningful commit message in the new window, and press OK when finished. This was the second operation: <em>commit</em> which reflects the changes to your local repository, the one in your hard-drive. You can push the changes in the next window if you want, however it&#8217;s not a good idea to push every local commit to the remote repository (that&#8217;s why we are using a DVCS after all). </p>
<p>Before continuing to the <em>push</em> command, let&#8217;s talk about some naming conventions in the Git world. With DVCSs such as git you can have different remote repositories which you may choose from to push your changes to. By convention, the default name for the remote repository is &#8220;<em>origin</em>&#8220;. In our case <em>origin</em> is the remote repository at the Github server, for which we manually added the link before. On the other hand, each project may have several <em>branches</em>. Conceptually a branch is another copy of the same project where other features are developed and tested. For example imagine that at a certain stage of development you may decide to add a new feature to your project. You may create a new branch called &#8220;test&#8221;, develop and test the feature there, and finally merge the changes with the code at the main branch. By convention, the main branch is called &#8220;<em>master</em>&#8220;.</p>
<p>When it comes to <em>push</em>, you need to know which branch of the code you want to push to which remote repository. In our simple case we want to push the <em>master</em> branch to the <em>origin</em> repository. For this purpose, right click somewhere on the Windows explorer that shows the project root folder, and select: <em>TortoiseGit &#62; Push&#8230;</em>. Make sure the name of the branches for local and remote repositories and the name of the remote repository are selected correctly. More importantly make sure that the &#8220;<em>Autoload Putty Key</em>&#8221; check-box is also checked, and press OK. Next, the TortoiseGit will prompt you for the private-key passphrase. Note that this is not your Github account password, this is the passphrase that you chose when creating the private key with <em>Puttygen</em>. After finishing the push operation, check the sources in the project&#8217;s Github page to make sure the changes have been reflected there. Note that after the first push, the <em>PuTTY authentication agent (Pageant)</em> get&#8217;s run in the background, so that you won&#8217;t need to enter the passphrase anytime you want to push to Github.</p>
<p><strong>Updating the local repository with the latest changes made by other team members to the remote repository.</strong> Well, there are two solutions. The one that I prefer is using git <em>pull</em>. You can easily find this command in the TortoiseGit&#8217;s context menu. The <em>pull</em> command, preserves the history of changes made by different people and makes a final merge afterwards. The other solution is git <em>fetch</em> and <em>rebase</em>. The <em>fetch</em> command only receives the latest changes from the remote repository but does <em>not</em> apply them. The <em>rebase</em> command first applies the remote changes to the repository, then applies your changes. Therefore it always seems that you have made the recent changes, while it may not be true. See this <a href="http://stackoverflow.com/questions/3357122/git-pull-vs-git-fetch-git-rebase">stackoverflow question</a> for a better explanation.</p>
<p><strong>Note:</strong> At any stage, if git complains about connecting through a <em>null</em> proxy, then you will have to remove proxy settings from the global <code>.gitconfig</code> file. For more information see tip 7 on my earlier <a href="http://sinairv.wordpress.com/2012/05/01/how-to-setup-git-for-windows/">post</a></p>
<p>You may also want to see my earlier <a href="http://sinairv.wordpress.com/2012/05/04/using-git-with-codeplex-on-windows/">post</a> that describes using git with <a href="http://www.codeplex.com">CodePlex</a> on Windows.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Using Git with CodePlex on Windows]]></title>
<link>http://sinairv.wordpress.com/2012/05/04/using-git-with-codeplex-on-windows/</link>
<pubDate>Fri, 04 May 2012 04:58:36 +0000</pubDate>
<dc:creator>Sina Iravanian</dc:creator>
<guid>http://sinairv.wordpress.com/2012/05/04/using-git-with-codeplex-on-windows/</guid>
<description><![CDATA[If you&#8217;re new to Git and don&#8217;t know how to install Git on Windows, read my earlier post:]]></description>
<content:encoded><![CDATA[<p>If you&#8217;re new to Git and don&#8217;t know how to install Git on Windows, read my earlier post: <a href="http://sinairv.wordpress.com/2012/05/01/how-to-setup-git-for-windows/">How to Setup Git for Windows</a></p>
<p>On 21 March 2012, the <a href="http://www.codeplex.com">CodePlex</a> team <a href="http://blogs.msdn.com/b/codeplex/archive/2012/03/21/git-commit-m-codeplex-now-supports-git.aspx">announced</a> their support for Git.</p>
<p>Creating a project with Git source control is very easy in CodePlex and is done with a few clicks at no time. Suppose the project name is <code>CodePlexGitTest</code>. In order to make any changes to the project structure you need to clone the project first. This way you will have your own copy of the repository on your hard disk. To do this the path to the git repository is needed. This can be obtained from the <em>Source Code</em> tab of the project&#8217;s CodePlex page, by pressing the <em>Git</em> link/button under &#8220;<em>Source Control</em>&#8221; section on the right pane, as seen below:</p>
<p><img src="http://sinairv.files.wordpress.com/2012/05/codeplexgit.png" alt="Git Repository Information on CodePlex" /></p>
<p>In order to clone the project, move to the folder that is going to host the project directory. Right click somewhere in the Windows explorer window and choose <em>Git Clone</em>. In the opened window set the &#8220;<em>Url</em>&#8221; field to the &#8220;<em>Clone URL</em>&#8221; value above, leave other options unchanged, and press OK. After prompting for your CodePlex user-name and password, it should now create the folder structure for your empty repository (<strong>Note:</strong> in case that git complains about connecting through a <em>null</em> proxy, then you will have to remove proxy settings from the global <code>.gitconfig</code> file. For more information see tip 7 on my earlier <a href="http://sinairv.wordpress.com/2012/05/01/how-to-setup-git-for-windows/">post</a>). </p>
<p>Now that you have the currently empty project structure at your hard-drive, it&#8217;s time to add some files to it. Using git, adding a file to a project structure and having it reflected in the remote repository requires 3 operations: <em>add</em>, <em>commit</em>, and <em>push</em>. The first 2 operations are required for adding the file to the local repository, and the third one reflects the changes to the remote repository. This last operation can be postponed to a later time when you want to <em>push</em> a bundle of changes all at once.</p>
<p>To start, create a <code>Readme.txt</code> file in the root folder. Right click on the newly added file, from the context menu select: <em>TortoiseGit &#62; add</em>; check the files to be added, and press OK. This was the first operation: <em>add</em>. In the new window press &#8220;<em>commit &#8230;</em>&#8220;, provide a meaningful commit message in the new window, and press OK when finished. This was the second operation: <em>commit</em> which reflects the changes to your local repository, the one in your hard-drive. You can push the changes in the next window if you want, however it&#8217;s not a good idea to push every local commit to the remote repository (that&#8217;s why we are using a DVCS after all). </p>
<p>Before continuing to the <em>push</em> command, let&#8217;s talk about some naming conventions in the git world. With DVCSs such as git you can have different remote repositories which you may choose from to push your changes to. By convention, the default name for the remote repository is &#8220;<em>origin</em>&#8220;. In our case <em>origin</em> is the remote repository at the CodePlex server. On the other hand, each project may have several <em>branches</em>. Conceptually a branch is another copy of the same project where other features are developed and tested. For example imagine that at a certain stage of development you may decide to add a new feature to your project. You may create a new branch called &#8220;test&#8221;, develop and test the feature there, and finally merge the changes with the code at the main branch. By convention, the main branch is called &#8220;<em>master</em>&#8220;.</p>
<p>When it comes to <em>push</em>, you need to know which branch of the code you want to push to which remote repository. In our simple case we want to push the <em>master</em> branch to the <em>origin</em> repository. For this purpose, right click somewhere on the Windows explorer that shows the project root folder, and select: <em>TortoiseGit &#62; Push&#8230;</em>. Make sure the name of the branches for local and remote repositories and the name of the remote repository are selected correctly, and press OK. Enter CodePlex user-name and passwords which are prompted. Now check the sources in the project&#8217;s CodePlex site to make sure the changes have been reflected there.</p>
<p>How to update the local repository with the latest changes made by other team members to the remote repository? Well, there are two solutions. The one that I prefer is using git <em>pull</em>. You can easily find this command in the TortoiseGit&#8217;s context menu. The <em>pull</em> command, preserves the history of changes made by different people and makes a final merge afterwards. The other solution is git <em>fetch</em> and <em>rebase</em>. The <em>fetch</em> command only receives the latest changes from the remote repository but does <em>not</em> apply them. The <em>rebase</em> command first applies the remote changes to the repository, then applies your changes. Therefore it always seems that you have made the recent changes, while it may not be true. See this <a href="http://stackoverflow.com/questions/3357122/git-pull-vs-git-fetch-git-rebase">stackoverflow question</a> for a better explanation.</p>
<p>See also:<br />
<a href="http://sinairv.wordpress.com/2012/05/01/how-to-setup-git-for-windows/">How to setup Git for Windows</a><br />
<a href="http://sinairv.wordpress.com/2012/05/05/using-git-with-github-on-windows/">Using Git with Github on Windows</a></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[How to create and delete tags on Github]]></title>
<link>http://panupan.com/2012/05/03/how-to-create-and-delete-tags-on-github/</link>
<pubDate>Thu, 03 May 2012 18:23:36 +0000</pubDate>
<dc:creator>Panupan Sriautharawong</dc:creator>
<guid>http://panupan.com/2012/05/03/how-to-create-and-delete-tags-on-github/</guid>
<description><![CDATA[Creating a tag: $ git tag -a [tag] -m &quot;[tag]&quot; $ git push origin --tags Deleting a tag: $ g]]></description>
<content:encoded><![CDATA[<p>Creating a tag:</p>
<pre class="brush: bash; title: ; notranslate" title="">
$ git tag -a [tag] -m &#34;[tag]&#34;
$ git push origin --tags
</pre>
<p>Deleting a tag:</p>
<pre class="brush: bash; title: ; notranslate" title="">
$ git tag -d [tag]
$ git push origin :tags/[tag]
</pre>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Setting up a Github project]]></title>
<link>http://awaseroot.wordpress.com/2012/05/02/setting-up-a-github-project/</link>
<pubDate>Wed, 02 May 2012 10:32:01 +0000</pubDate>
<dc:creator>Henri Siponen</dc:creator>
<guid>http://awaseroot.wordpress.com/2012/05/02/setting-up-a-github-project/</guid>
<description><![CDATA[So I felt like setting up Github repository for awaseroot. Git is a version control system and with]]></description>
<content:encoded><![CDATA[<p>So I felt like setting up Github repository for awaseroot. Git is a version control system and with <a title="https://github.com" href="https://github.com" target="_blank">Github</a> you can share your git project/repository online. We use Github as a place to share all our awaseroot material. There&#8217;s many good tutorials available (for example: <a title="http://help.github.com/win-set-up-git/" href="http://help.github.com/win-set-up-git/" target="_blank">http://help.github.com/win-set-up-git/</a>) but here&#8217;s the steps I took one by one. Replace awaseroot with whatever you want.</p>
<p>Ubuntu 12.04<br />
Git version 1.7.9.5</p>
<p>The goal is to publish this:<br />
<a href="http://awaseroot.files.wordpress.com/2012/05/terminal1.jpg"><img class="alignnone size-full wp-image-173" title="git" src="http://awaseroot.files.wordpress.com/2012/05/terminal1.jpg?w=391&#038;h=106" alt="" width="391" height="106" /></a></p>
<p>Like this:<!--more--><br />
<a href="http://awaseroot.files.wordpress.com/2012/05/browser1.jpg"><img class="alignnone size-full wp-image-174" title="github" src="http://awaseroot.files.wordpress.com/2012/05/browser1.jpg?w=630&#038;h=424" alt="" width="630" height="424" /></a></p>
<p>First. Create an account to Github:<br />
<a title="https://github.com/signup/free" href="https://github.com/signup/free" target="_blank">https://github.com/signup/free</a></p>
<p>Create a new repository:<br />
<a title="https://github.com/new" href="https://github.com/new" target="_blank">https://github.com/new</a><br />
Repository name: awaseroot<br />
Description: <a href="http://awaseroot.wordpress.com" rel="nofollow">http://awaseroot.wordpress.com</a><br />
Public<br />
Initialize this repository with a README<br />
-&#62; Create repository</p>
<p>Install git:<br />
<code>sudo apt-get -y install git</code></p>
<p>Configure git:<br />
<code>git config --global user.name "Firstname Lastname"</code><br />
<code>git config --global user.email awaseroot@example.com</code><br />
Use the same email you used when creating the github account.</p>
<p>We need SSH key for the Github:<br />
copy contents of ~/.ssh/id_rsa.pub<br />
Or if you don&#8217;t have the key yet, create it with this first:<br />
<code>ssh-keygen</code></p>
<p>Log in to <a title="https://github.com" href="https://github.com" target="_blank">https://github.com</a><br />
Account settings -&#62; SSH keys<br />
-&#62; Add SSH key<br />
paste the contents of the ~/.ssh/id_rsa.pub</p>
<p>Connect to github to authenticate:<br />
<code>ssh -T git@github.com</code></p>
<p>Clone the created Github repository:<br />
<code>git clone git@github.com:awaseroot/awaseroot.git<br />
cd awaseroot</code></p>
<p>Add the github repository as a remote git:<br />
<code>git remote add awase git@github.com:awaseroot/awaseroot.git</code><br />
(You can change awase to whatever you want.)</p>
<p>Create/add content to your project and push it to github:<br />
<code>cp -r ~/puppet/ ~/awaseroot/<br />
git add puppet<br />
git commit -m "First Puppet files added"<br />
git push awase master</code></p>
<p>Your new pushed material should be now available in your github.<br />
<a title="https://github.com/awaseroot/awaseroot" href="https://github.com/awaseroot/awaseroot" target="_blank">https://github.com/awaseroot/awaseroot</a></p>
<p><strong>Becoming a collaborator to an existing github repository</strong></p>
<p>So you have your git already configured, Github account ready with SSH key and now someone adds you as a collaborator. Here&#8217;s what to do:</p>
<p>If the repository is for example git@github.com:awaseroot/awaseroot.git<br />
Clone the repository:<br />
<code>git clone git@github.com:awaseroot/awaseroot.git</code></p>
<p>You should now have the awaseroot directory. Go there:<br />
<code>cd awaseroot/</code></p>
<p>Add the repository as a remote:<br />
<code>git remote add awase git@github.com:awaseroot/awaseroot.git</code></p>
<p>Add your files if you have something to add:<br />
<code>cp ~/puppet/manifests/site.pp ~/awaseroot/puppet/manifests/</code><br />
<code>git add puppet/manifests/site.pp</code></p>
<p>Commit and push your changes:<br />
<code>git commit -m "site.pp added"</code><br />
<code>git push awase master</code></p>
<p><strong>Everyday use</strong></p>
<p>Every time you make changes to your repository you can use these commands to commit changes:<br />
<code>git add my_file</code>         # add a file called my_file to git.<br />
<code>git add .</code>                   # add all modified files to git and remove deleted files.<br />
<code>git commit -m "commit description"</code>  # commit changes.<br />
<code>git push awase master</code>  # push changes to remote git (github).<br />
(change awase with whatever you defined as a remote)</p>
<p>If someone else has made changes to your git repository, pull the changes with this:<br />
<code>git pull awase master</code></p>
<p>You&#8217;ll get an error message if there&#8217;s new changes in your git and you try to commit before pulling<br />
those changes.</p>
<p><strong>Sources</strong><br />
<a title="https://github.com" href="https://github.com" target="_blank">https://github.com</a></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[How to setup Git for Windows]]></title>
<link>http://sinairv.wordpress.com/2012/05/01/how-to-setup-git-for-windows/</link>
<pubDate>Tue, 01 May 2012 15:29:44 +0000</pubDate>
<dc:creator>Sina Iravanian</dc:creator>
<guid>http://sinairv.wordpress.com/2012/05/01/how-to-setup-git-for-windows/</guid>
<description><![CDATA[These are some easy steps required to setup Git for Windows: Download msysGit from: http://code.goog]]></description>
<content:encoded><![CDATA[<p>These are some easy steps required to setup Git for Windows:</p>
<ol>
<li>
<p>Download <code>msysGit</code> from: <a href="http://code.google.com/p/msysgit">http://code.google.com/p/msysgit</a>.<br />
I prefer to use the portable version. At the time of this writing there&#8217;s no difference between 32 bit and 64 bit versions and the filename for the portable version is: <code>PortableGit-1.7.10-preview20120409.7z</code>. Currently it seems that the development of the project has been moved to <a href="http://github.com/msysgit">Github</a>, but the releases are still located in Google Code.</p>
</li>
<li>
<p>Extract the contents in a proper location. I made them into:<br />
<code>D:\PortableProgs\msysGit</code></p>
</li>
<li>
<p>If you intend to use the git command-line for every git operation simply run <code>git-bash.bat</code> in the root folder of <em>msysGit</em>. Yes, this is the old lovely <em>Cygwin</em> command-line.</p>
</li>
<li>
<p>If you don&#8217;t intend to use command-line (like me) install <em>TortoiseGit</em>. It is hosted at Google Code:<br />
<a href="http://code.google.com/p/tortoisegit/">http://code.google.com/p/tortoisegit/</a><br />
Note that it comes with different releases for 32-bit and 64-bit systems. At the time of this writing the latest version is 1.7.8.0. After installing <em>TortoiseGit</em> you may need to restart Windows, or the explorer process, or none.</p>
</li>
<li>
<p>Right click somewhere on a Windows Explorer window, and from the context menu select: <em>TortoiseGit &#62; Settings</em>. There will be a message-box appearing begging for adjusting the path to <em>msysGit</em>. Click on &#8220;Set MSysGit path&#8221; button (If you have ever missed this window, or want to change the path to an already existing <em>msysGit</em>, simply go to: <em>TortoiseGit &#62; Settings &#62;&#62; the General branch</em>).<br />
In the field titled as &#8220;<em>Git.exe path:</em>&#8221; enter the path to the <em>bin</em> folder of the <em>msysGit</em> installation/copy.</p>
</li>
<li>
<p>You don&#8217;t have to, but it is highly recommended that before starting any git operations you set some global settings such as your name, email, and AutoCrlf. To this aim in the Windows explorer&#8217;s context menu go to: <em>TortoiseGit &#62; Settings &#62;&#62; the Git branch</em>. Fill in the fields labeled <em>Name</em> and <em>Email</em> with proper values. Then make sure that <em>AutoCrlf</em> check-box is unchecked, so that you don&#8217;t touch <em>every</em> file in order to change their line-endings. Read more about this kind of problem <a href="http://code52.org/line-endings.html">here</a>, and see <a href="http://stackoverflow.com/questions/4181870/git-on-windows-what-do-the-crlf-settings-mean">here</a> to know more what AutoCrlf and SafeCrlf options do for you.</p>
</li>
<li>
<p><strong>[UPDATED on 3 May 2012]</strong> When performing some git operations, git may complain that it cannot connect through a <em>null</em> proxy. It may happen for some versions if in git settings the value for proxy is assigned to an empty string. If this is the case for you, simply remove proxy settings in the global <code>.gitconfig</code> file. To do this, right click somewhere in Windows explorer, go to: <em>TortoiseGit &#62; Settings &#62;&#62; The Git Branch &#62;&#62; Edit Global .gitconfig button</em>. From there remove the line that assigns proxy, or the whole &#8220;[http]&#8221; section if it only contains proxy settings.</p>
</li>
</ol>
<p>See also:<br />
<a href="http://sinairv.wordpress.com/2012/05/04/using-git-with-codeplex-on-windows/">Using Git with CodePlex on Windows</a><br />
<a href="http://sinairv.wordpress.com/2012/05/05/using-git-with-github-on-windows/">Using Git with Github on Windows</a></p>
]]></content:encoded>
</item>

</channel>
</rss>
