<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/css" href="http://openwetware.org/skins/common/feed.css?164"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
	<channel>
		<title>User:Timothee Flutre/Notebook/Postdoc/2012/08/14 - Revision history</title>
		<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;action=history</link>
		<description>Revision history for this page on the wiki</description>
		<language>en</language>
		<generator>MediaWiki 1.13.2</generator>
		<lastBuildDate>Thu, 23 May 2013 23:34:39 GMT</lastBuildDate>
		<item>
			<title>Timothee Flutre: /* About Git */ add tips about ssh tunnel and local branch which tracks remote one</title>
			<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;diff=690476&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;About Git:&amp;#32;&lt;/span&gt; add tips about ssh tunnel and local branch which tracks remote one&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr valign='top'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 02:16, 11 April 2013&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 26:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 26:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** undo uncommitted changes: &amp;lt;code&amp;gt;git checkout myfile.txt&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** undo uncommitted changes: &amp;lt;code&amp;gt;git checkout myfile.txt&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** split a big commit in several smaller commits: &amp;lt;code&amp;gt;git add -p myfile.txt&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** split a big commit in several smaller commits: &amp;lt;code&amp;gt;git add -p myfile.txt&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** usual config: &amp;lt;code&amp;gt;git config --global user.name 'Timothée Flutre'; git config --global user.email 'timflutre@gmail.com'; git config --global i18n.commitEncoding 'utf8'; git config --global i18n.logOutputEncoding 'utf8'&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** usual config: &amp;lt;code&amp;gt;git config --global user.name 'Timothée Flutre'; git config --global user.email 'timflutre@gmail.com'&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;; git config --global core.editor emacs&lt;/ins&gt;; git config --global i18n.commitEncoding 'utf8'; git config --global i18n.logOutputEncoding 'utf8'&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;&amp;lt;/code&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;** remote via ssh tunnel: first open the tunnel &amp;lt;code&amp;gt;ssh gateway.foo.bar -l tflutre -Nf -L 20400:maincluster:22&amp;lt;/code&amp;gt;, then add the remote &amp;lt;code&amp;gt;git remote add mcl ssh://tflutre@localhost:20400/home/tflutre/myproject/.git&lt;/ins&gt;&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 68:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 69:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;	rm -f *~ *.aux *.dvi *.log *.pdf *.bbl *.blg *.toc&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;	rm -f *~ *.aux *.dvi *.log *.pdf *.bbl *.blg *.toc&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;/nowiki&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;/nowiki&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;* '''Two remotes''': let's imagine that on cluster1 I have 2 branches, &amp;quot;master&amp;quot; and &amp;quot;dev&amp;quot;, on github I only have &amp;quot;master&amp;quot;, and I want to work with &amp;quot;dev&amp;quot; on cluster2.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;** first I log on cluster2 and I clone the repo from github: &amp;lt;code&amp;gt;git clone https://github.com/timflutre/myproject.git&amp;lt;/code&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;** then I add my repo from cluster1 as a remote: &amp;lt;code&amp;gt;cd myproject/; git remote add cluster1 ssh://tflutre@cluster1:/home/tflutre/myproject/.git&amp;lt;/code&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;** finally I fetch the remotes and create a &amp;quot;dev&amp;quot; branch which tracks the one on cluster1: &amp;lt;code&amp;gt;git remote update; git checkout -b dev cluster1/dev&amp;lt;/code&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;!-- ##### DO NOT edit below this line unless you know what you are doing. ##### --&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;!-- ##### DO NOT edit below this line unless you know what you are doing. ##### --&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff generator: internal 2013-05-23 23:34:39 --&gt;
&lt;/table&gt;</description>
			<pubDate>Thu, 11 Apr 2013 02:16:35 GMT</pubDate>			<dc:creator>Timothee Flutre</dc:creator>			<comments>http://openwetware.org/wiki/User_talk:Timothee_Flutre/Notebook/Postdoc/2012/08/14</comments>		</item>
		<item>
			<title>Timothee Flutre: /* About Git */ add tip</title>
			<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;diff=680997&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;About Git:&amp;#32;&lt;/span&gt; add tip&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr valign='top'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 21:26, 5 March 2013&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 25:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 25:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Tips''':&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Tips''':&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** undo uncommitted changes: &amp;lt;code&amp;gt;git checkout myfile.txt&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** undo uncommitted changes: &amp;lt;code&amp;gt;git checkout myfile.txt&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;** split a big commit in several smaller commits: &amp;lt;code&amp;gt;git add -p myfile.txt&amp;lt;/code&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** usual config: &amp;lt;code&amp;gt;git config --global user.name 'Timothée Flutre'; git config --global user.email 'timflutre@gmail.com'; git config --global i18n.commitEncoding 'utf8'; git config --global i18n.logOutputEncoding 'utf8'&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** usual config: &amp;lt;code&amp;gt;git config --global user.name 'Timothée Flutre'; git config --global user.email 'timflutre@gmail.com'; git config --global i18n.commitEncoding 'utf8'; git config --global i18n.logOutputEncoding 'utf8'&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff generator: internal 2013-05-23 23:34:39 --&gt;
&lt;/table&gt;</description>
			<pubDate>Tue, 05 Mar 2013 21:26:31 GMT</pubDate>			<dc:creator>Timothee Flutre</dc:creator>			<comments>http://openwetware.org/wiki/User_talk:Timothee_Flutre/Notebook/Postdoc/2012/08/14</comments>		</item>
		<item>
			<title>Timothee Flutre: /* About Git */ add link to example of conflict solving</title>
			<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;diff=666433&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;About Git:&amp;#32;&lt;/span&gt; add link to example of conflict solving&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr valign='top'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 23:33, 9 January 2013&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 17:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 17:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Conflicts''': when updating one branch with the content of another one (&amp;lt;code&amp;gt;git checkout branch1; git merge branch2&amp;lt;/code&amp;gt;), some conflicts can happen, and it is usually hard to know how to solve them properly. In the following, branch1 can be master and branch2 can be origin/master, or branch1 can be master and branch2 can be dev.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Conflicts''': when updating one branch with the content of another one (&amp;lt;code&amp;gt;git checkout branch1; git merge branch2&amp;lt;/code&amp;gt;), some conflicts can happen, and it is usually hard to know how to solve them properly &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;(but see a concrete example [http://git-scm.com/book/en/Git-Branching-Basic-Branching-and-Merging here])&lt;/ins&gt;. In the following, branch1 can be master and branch2 can be origin/master, or branch1 can be master and branch2 can be dev.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** The first solution is to edit each conflicted files by hand, then run &amp;lt;code&amp;gt;git add fileX.txt&amp;lt;/code&amp;gt; (staging indicates to git that the conflict is resolved) and finally run &amp;lt;code&amp;gt;git commit -m &amp;quot;merge branch2 and solve conflicts&amp;quot; fileX.txt&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** The first solution is to edit each conflicted files by hand, then run &amp;lt;code&amp;gt;git add fileX.txt&amp;lt;/code&amp;gt; (staging indicates to git that the conflict is resolved) and finally run &amp;lt;code&amp;gt;git commit -m &amp;quot;merge branch2 and solve conflicts&amp;quot; fileX.txt&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** The second solution is to ignore the conflicts and overwrite the files of branch1 with the content of branch2, one file at a time: &amp;lt;code&amp;gt;git checkout --patch branch2 fileX.txt&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** The second solution is to ignore the conflicts and overwrite the files of branch1 with the content of branch2, one file at a time: &amp;lt;code&amp;gt;git checkout --patch branch2 fileX.txt&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff generator: internal 2013-05-23 20:41:28 --&gt;
&lt;!-- diff cache key owwdb:diff:version:1.11a:oldid:666332:newid:666433 --&gt;
&lt;/table&gt;</description>
			<pubDate>Wed, 09 Jan 2013 23:33:17 GMT</pubDate>			<dc:creator>Timothee Flutre</dc:creator>			<comments>http://openwetware.org/wiki/User_talk:Timothee_Flutre/Notebook/Postdoc/2012/08/14</comments>		</item>
		<item>
			<title>Timothee Flutre: /* About Git */ improve conflicts section</title>
			<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;diff=666332&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;About Git:&amp;#32;&lt;/span&gt; improve conflicts section&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr valign='top'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 22:34, 8 January 2013&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 17:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 17:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Conflicts''': when updating one branch with the content of another one (&amp;lt;code&amp;gt;git checkout branch1; git merge branch2&amp;lt;/code&amp;gt;), some conflicts can happen, and it is usually hard to know how to solve them properly. In the following, branch1 can be master and branch2 can be origin/master, or branch1 can be &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;tim &lt;/del&gt;and branch2 can be &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;master&lt;/del&gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Conflicts''': when updating one branch with the content of another one (&amp;lt;code&amp;gt;git checkout branch1; git merge branch2&amp;lt;/code&amp;gt;), some conflicts can happen, and it is usually hard to know how to solve them properly. In the following, branch1 can be master and branch2 can be origin/master, or branch1 can be &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;master &lt;/ins&gt;and branch2 can be &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;dev&lt;/ins&gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** The first solution is to edit &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;the &lt;/del&gt;files by hand &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;and choose which version we want &lt;/del&gt;to &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;keep for each &lt;/del&gt;conflict.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** The first solution is to edit &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;each conflicted &lt;/ins&gt;files by hand&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;, then run &amp;lt;code&amp;gt;git add fileX.txt&amp;lt;/code&amp;gt; (staging indicates &lt;/ins&gt;to &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;git that the &lt;/ins&gt;conflict &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;is resolved) and finally run &amp;lt;code&amp;gt;git commit -m &amp;quot;merge branch2 and solve conflicts&amp;quot; fileX.txt&amp;lt;/code&amp;gt;&lt;/ins&gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** The second solution is to ignore the conflicts and overwrite the files of branch1 with the content of branch2, one file at a time: &amp;lt;code&amp;gt;git checkout --patch branch2 fileX.txt&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** The second solution is to ignore the conflicts and overwrite the files of branch1 with the content of branch2, one file at a time: &amp;lt;code&amp;gt;git checkout --patch branch2 fileX.txt&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** The third solution, even more radical, is to &amp;quot;overwrite&amp;quot; all of branch1 with the content of the branch2, all files at once: &amp;lt;code&amp;gt;git reset --hard branch2&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** The third solution, even more radical, is to &amp;quot;overwrite&amp;quot; all of branch1 with the content of the branch2, all files at once: &amp;lt;code&amp;gt;git reset --hard branch2&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff generator: internal 2013-05-23 23:34:39 --&gt;
&lt;/table&gt;</description>
			<pubDate>Tue, 08 Jan 2013 22:34:05 GMT</pubDate>			<dc:creator>Timothee Flutre</dc:creator>			<comments>http://openwetware.org/wiki/User_talk:Timothee_Flutre/Notebook/Postdoc/2012/08/14</comments>		</item>
		<item>
			<title>Timothee Flutre: /* About Git */ add Makefile for pdf</title>
			<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;diff=664212&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;About Git:&amp;#32;&lt;/span&gt; add Makefile for pdf&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr valign='top'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 16:53, 18 December 2012&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 15:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 15:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Need some help''': the learning curve for git is quite steep at the beginning, so it's always worth browsing [https://help.github.com/ help pages], reading [http://gitref.org/ Git Reference], and searching for questions and answers on [http://stackoverflow.com/ stackoverflow].&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Need some help''': the learning curve for git is quite steep at the beginning, so it's always worth browsing [https://help.github.com/ help pages], reading [http://gitref.org/ Git Reference], and searching for questions and answers on [http://stackoverflow.com/ stackoverflow].&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;* '''Conflicts''': when updating one branch with the content of another one (&amp;lt;code&amp;gt;git checkout branch1; git merge branch2&amp;lt;/code&amp;gt;), some conflicts can happen, and it is usually hard to know how to solve them properly. In the following, branch1 can be master and branch2 can be origin/master, or branch1 can be tim and branch2 can be master.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;** The first solution is to edit the files by hand and choose which version we want to keep for each conflict.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;** The second solution is to ignore the conflicts and overwrite the files of branch1 with the content of branch2, one file at a time: &amp;lt;code&amp;gt;git checkout --patch branch2 fileX.txt&amp;lt;/code&amp;gt;.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;** The third solution, even more radical, is to &amp;quot;overwrite&amp;quot; all of branch1 with the content of the branch2, all files at once: &amp;lt;code&amp;gt;git reset --hard branch2&amp;lt;/code&amp;gt;.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 39:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 45:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;*** One can look at the differences file by file: &amp;lt;code&amp;gt;git diff --color-words colleague1:paper_main.tex master:paper_main.tex&amp;lt;/code&amp;gt;. The options &amp;quot;--color-words&amp;quot; is especially useful in LaTeX.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;*** One can look at the differences file by file: &amp;lt;code&amp;gt;git diff --color-words colleague1:paper_main.tex master:paper_main.tex&amp;lt;/code&amp;gt;. The options &amp;quot;--color-words&amp;quot; is especially useful in LaTeX.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;*** To merge the content of the recently-updated local &amp;quot;master&amp;quot; into his own local branch, we do: &amp;lt;code&amp;gt;git merge master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;*** To merge the content of the recently-updated local &amp;quot;master&amp;quot; into his own local branch, we do: &amp;lt;code&amp;gt;git merge master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;** Tips: don't version the output pdf in the repository because, as it is binary, git can't merge it properly. But you can add a Makefile (see below) and, by entering &amp;lt;code&amp;gt;make main -i&amp;lt;/code&amp;gt; on the command-line, it will compile your pdf document when you need it&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt; &amp;lt;nowiki&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;all: main supp&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;* '''Conflicts'''&lt;/del&gt;: &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;when updating one branch with the content of another one (&amp;lt;code&amp;gt;git checkout branch1; git merge branch2&amp;lt;/code&amp;gt;), some conflicts can happen, and it is usually hard to know how to solve them properly&lt;/del&gt;. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;In the following, branch1 can be master and branch2 can be origin/master, or branch1 can be tim and branch2 can be master&lt;/del&gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;main&lt;/ins&gt;:&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;The first solution is to edit the files by hand and choose which version we want to keep for each conflict&lt;/del&gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	latex paper_main&lt;/ins&gt;.&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;tex&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;The second solution is to ignore the conflicts and overwrite the files of branch1 with the content of branch2, one file at a time: &amp;lt;code&amp;gt;git checkout --patch branch2 fileX&lt;/del&gt;.&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;txt&amp;lt;/code&amp;gt;&lt;/del&gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	bibtex paper_main&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;The third solution, even more radical, is to &amp;quot;overwrite&amp;quot; all of branch1 with the content of the branch2, all files at once: &amp;lt;code&amp;gt;git reset --hard branch2&lt;/del&gt;&amp;lt;/&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;code&lt;/del&gt;&amp;gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;.&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	latex paper_main&lt;/ins&gt;.&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;tex&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	latex paper_main.tex&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	pdflatex paper_main&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;supp:&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	latex paper_supplements.tex&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	bibtex paper_supplements&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	latex paper_supplements.tex&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	latex paper_supplements.tex&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	pdflatex paper_supplements&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;clean:&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;	rm -f &lt;/ins&gt;*&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;~ &lt;/ins&gt;*.&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;aux &lt;/ins&gt;*&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;.dvi &lt;/ins&gt;*.&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;log *&lt;/ins&gt;.&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;pdf &lt;/ins&gt;*&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;.bbl &lt;/ins&gt;*&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;.blg *.toc&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;/&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;nowiki&lt;/ins&gt;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;!-- ##### DO NOT edit below this line unless you know what you are doing. ##### --&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;!-- ##### DO NOT edit below this line unless you know what you are doing. ##### --&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff generator: internal 2013-05-23 20:09:15 --&gt;
&lt;!-- diff cache key owwdb:diff:version:1.11a:oldid:663957:newid:664212 --&gt;
&lt;/table&gt;</description>
			<pubDate>Tue, 18 Dec 2012 16:53:38 GMT</pubDate>			<dc:creator>Timothee Flutre</dc:creator>			<comments>http://openwetware.org/wiki/User_talk:Timothee_Flutre/Notebook/Postdoc/2012/08/14</comments>		</item>
		<item>
			<title>Timothee Flutre: /* About Git */ put &quot;conflicts&quot; in a separate section</title>
			<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;diff=663957&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;About Git:&amp;#32;&lt;/span&gt; put &amp;quot;conflicts&amp;quot; in a separate section&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr valign='top'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 14:53, 17 December 2012&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 39:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 39:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;*** One can look at the differences file by file: &amp;lt;code&amp;gt;git diff --color-words colleague1:paper_main.tex master:paper_main.tex&amp;lt;/code&amp;gt;. The options &amp;quot;--color-words&amp;quot; is especially useful in LaTeX.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;*** One can look at the differences file by file: &amp;lt;code&amp;gt;git diff --color-words colleague1:paper_main.tex master:paper_main.tex&amp;lt;/code&amp;gt;. The options &amp;quot;--color-words&amp;quot; is especially useful in LaTeX.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;*** To merge the content of the recently-updated local &amp;quot;master&amp;quot; into his own local branch, we do: &amp;lt;code&amp;gt;git merge master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;*** To merge the content of the recently-updated local &amp;quot;master&amp;quot; into his own local branch, we do: &amp;lt;code&amp;gt;git merge master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;*&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;** In case &lt;/del&gt;of conflicts, &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;we have &lt;/del&gt;to edit &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;our own &lt;/del&gt;files by hand&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;. Or we can also &lt;/del&gt;choose to ignore the conflicts and overwrite &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;our local &lt;/del&gt;files with the content of &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;&amp;quot;master&amp;quot; &lt;/del&gt;one file at a time: &amp;lt;code&amp;gt;git checkout --patch &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;master paper_main&lt;/del&gt;.&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;tex&lt;/del&gt;&amp;lt;/code&amp;gt;. &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;Even &lt;/del&gt;more radical, &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;we can decide &lt;/del&gt;to &amp;quot;overwrite&amp;quot; &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;our personal local branch &lt;/del&gt;with &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;our local&lt;/del&gt;, &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;recently-updated &amp;quot;master&amp;quot; branch (&lt;/del&gt;all files at once&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;)&lt;/del&gt;: &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;&amp;lt;code&amp;gt;git checkout colleague1&amp;lt;/code&amp;gt; followed by &lt;/del&gt;&amp;lt;code&amp;gt;git reset --hard &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;master&lt;/del&gt;&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;'''Conflicts''': when updating one branch with the content &lt;/ins&gt;of &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;another one (&amp;lt;code&amp;gt;git checkout branch1; git merge branch2&amp;lt;/code&amp;gt;), some &lt;/ins&gt;conflicts &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;can happen&lt;/ins&gt;, &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;and it is usually hard to know how to solve them properly. In the following, branch1 can be master and branch2 can be origin/master, or branch1 can be tim and branch2 can be master.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;** The first solution is &lt;/ins&gt;to edit &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;the &lt;/ins&gt;files by hand &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;and &lt;/ins&gt;choose &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;which version we want to keep for each conflict.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;** The second solution is &lt;/ins&gt;to ignore the conflicts and overwrite &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;the &lt;/ins&gt;files &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;of branch1 &lt;/ins&gt;with the content of &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;branch2, &lt;/ins&gt;one file at a time: &amp;lt;code&amp;gt;git checkout --patch &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;branch2 fileX&lt;/ins&gt;.&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;txt&lt;/ins&gt;&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;** The third solution, even &lt;/ins&gt;more radical, &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;is &lt;/ins&gt;to &amp;quot;overwrite&amp;quot; &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;all of branch1 &lt;/ins&gt;with &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;the content of the branch2&lt;/ins&gt;, all files at once: &amp;lt;code&amp;gt;git reset --hard &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;branch2&lt;/ins&gt;&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;!-- ##### DO NOT edit below this line unless you know what you are doing. ##### --&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;!-- ##### DO NOT edit below this line unless you know what you are doing. ##### --&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff generator: internal 2013-05-23 23:34:40 --&gt;
&lt;/table&gt;</description>
			<pubDate>Mon, 17 Dec 2012 14:53:15 GMT</pubDate>			<dc:creator>Timothee Flutre</dc:creator>			<comments>http://openwetware.org/wiki/User_talk:Timothee_Flutre/Notebook/Postdoc/2012/08/14</comments>		</item>
		<item>
			<title>Timothee Flutre: /* About Git */ add tip on config</title>
			<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;diff=662466&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;About Git:&amp;#32;&lt;/span&gt; add tip on config&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr valign='top'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 01:48, 6 December 2012&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 19:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 19:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Tips''':&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Tips''':&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** undo uncommitted changes: &amp;lt;code&amp;gt;git checkout myfile.txt&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** undo uncommitted changes: &amp;lt;code&amp;gt;git checkout myfile.txt&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;** usual config: &amp;lt;code&amp;gt;git config --global user.name 'Timothée Flutre'; git config --global user.email 'timflutre@gmail.com'; git config --global i18n.commitEncoding 'utf8'; git config --global i18n.logOutputEncoding 'utf8'&amp;lt;/code&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff generator: internal 2013-05-23 23:34:40 --&gt;
&lt;/table&gt;</description>
			<pubDate>Thu, 06 Dec 2012 01:48:53 GMT</pubDate>			<dc:creator>Timothee Flutre</dc:creator>			<comments>http://openwetware.org/wiki/User_talk:Timothee_Flutre/Notebook/Postdoc/2012/08/14</comments>		</item>
		<item>
			<title>Timothee Flutre: /* About Git */ add tip</title>
			<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;diff=656133&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;About Git:&amp;#32;&lt;/span&gt; add tip&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr valign='top'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 14:32, 15 November 2012&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 15:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 15:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Need some help''': the learning curve for git is quite steep at the beginning, so it's always worth browsing [https://help.github.com/ help pages], reading [http://gitref.org/ Git Reference], and searching for questions and answers on [http://stackoverflow.com/ stackoverflow].&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Need some help''': the learning curve for git is quite steep at the beginning, so it's always worth browsing [https://help.github.com/ help pages], reading [http://gitref.org/ Git Reference], and searching for questions and answers on [http://stackoverflow.com/ stackoverflow].&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;* '''Tips''':&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;color: red; font-weight: bold; text-decoration: none;&quot;&gt;** undo uncommitted changes: &amp;lt;code&amp;gt;git checkout myfile.txt&amp;lt;/code&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff generator: internal 2013-05-23 23:34:40 --&gt;
&lt;/table&gt;</description>
			<pubDate>Thu, 15 Nov 2012 14:32:10 GMT</pubDate>			<dc:creator>Timothee Flutre</dc:creator>			<comments>http://openwetware.org/wiki/User_talk:Timothee_Flutre/Notebook/Postdoc/2012/08/14</comments>		</item>
		<item>
			<title>Timothee Flutre: /* About Git */ improve readability</title>
			<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;diff=650535&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;About Git:&amp;#32;&lt;/span&gt; improve readability&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr valign='top'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 22:48, 1 November 2012&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 18:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 18:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Writing a paper''': in this example, I am writing a paper with two colleagues. We decide to do it as a [http://git-scm.com/book/en/Distributed-Git-Distributed-Workflows centralized workflow], the shared repository being hosted by [https://github.com/ github].&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;* '''Writing a paper''': in this example, I am writing a paper with two colleagues. We decide to do it as a [http://git-scm.com/book/en/Distributed-Git-Distributed-Workflows centralized workflow], the shared repository being hosted by [https://github.com/ github].&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** Each of us needs to [https://github.com/signup/free create a free account].&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;** Setting up the infrastructure:&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** I need to upgrade my account in order to have the right to manage private repositories ([https://github.com/plans/ $7/month]).&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** Each of us needs to [https://github.com/signup/free create a free account].&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** I create a private repository named &amp;quot;paper&amp;quot; and add my colleagues as collaborators to it.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** I need to upgrade my account in order to have the right to manage private repositories ([https://github.com/plans/ $7/month]).&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** I retrieve the repository on my local machine: &amp;lt;code&amp;gt;git clone git://github.com/timflutre/paper.git&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** I create a private repository named &amp;quot;paper&amp;quot; and add my colleagues as collaborators to it.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** I create my first file, for instance &amp;quot;paper_main.tex&amp;quot;, and add it to git in my local repository: &amp;lt;code&amp;gt;git add paper_main.tex&amp;lt;/code&amp;gt; followed by &amp;lt;code&amp;gt;git commit -m &amp;quot;first commit&amp;quot; paper_main.tex&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** I retrieve the repository on my local machine: &amp;lt;code&amp;gt;git clone git://github.com/timflutre/paper.git&amp;lt;/code&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** I create one branch per collaborator (the default branch being &amp;quot;master&amp;quot;): &amp;lt;code&amp;gt;git branch tim&amp;lt;/code&amp;gt;, then &amp;lt;code&amp;gt;git branch colleague1&amp;lt;/code&amp;gt; and finally &amp;lt;code&amp;gt;git branch colleague2&amp;lt;/code&amp;gt;. I can list the local branches with &amp;lt;code&amp;gt;git branch&amp;lt;/code&amp;gt; and I can switch to my branch with &amp;lt;code&amp;gt;git checkout tim&amp;lt;/code&amp;gt; for instance.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** I create my first file, for instance &amp;quot;paper_main.tex&amp;quot;, and add it to git in my local repository: &amp;lt;code&amp;gt;git add paper_main.tex&amp;lt;/code&amp;gt; followed by &amp;lt;code&amp;gt;git commit -m &amp;quot;first commit&amp;quot; paper_main.tex&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** I push the changes I made from my local repo onto github: &amp;lt;code&amp;gt;git push origin master&amp;lt;/code&amp;gt;, this for each branch I created.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** I create one branch per collaborator (the default branch being &amp;quot;master&amp;quot;): &amp;lt;code&amp;gt;git branch tim&amp;lt;/code&amp;gt;, then &amp;lt;code&amp;gt;git branch colleague1&amp;lt;/code&amp;gt; and finally &amp;lt;code&amp;gt;git branch colleague2&amp;lt;/code&amp;gt;. I can list the local branches with &amp;lt;code&amp;gt;git branch&amp;lt;/code&amp;gt; and I can switch to my branch with &amp;lt;code&amp;gt;git checkout tim&amp;lt;/code&amp;gt; for instance.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** I send an email to my colleagues telling them that they can retrieve the content of the repository from github into their local machine(s): &amp;lt;code&amp;gt;git clone https://github.com/timflutre/paper.git&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** I push the changes I made from my local repo onto github: &amp;lt;code&amp;gt;git push origin master&amp;lt;/code&amp;gt;, this for each branch I created.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** Each of us can make modifications on its own branch, and push them on github in order to allow the others to access the changes: &amp;lt;code&amp;gt;git push origin colleague1&amp;lt;/code&amp;gt; for instance.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** I send an email to my colleagues telling them that they can retrieve the content of the repository from github into their local machine(s): &amp;lt;code&amp;gt;git clone https://github.com/timflutre/paper.git&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** From time to time, one of us has the responsibility to merge the changes and update the &amp;quot;master&amp;quot; branch with the latest version.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;** Typical working cycle:&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** Once this is done, the others need to retrieve the new content of &amp;quot;master&amp;quot; in their local repo: &amp;lt;code&amp;gt;git checkout master&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;git fetch origin&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;git diff master origin/master&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;git merge origin/master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** Each of us can make modifications on its own branch, and push them on github in order to allow the others to access the changes: &amp;lt;code&amp;gt;git push origin colleague1&amp;lt;/code&amp;gt; for instance.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** Then, they need to update their local branch with the new content of &amp;quot;master&amp;quot;: &amp;lt;code&amp;gt;git checkout colleague1&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;git diff --name-status colleague1..master&amp;lt;/code&amp;gt;. This will list the files having differences between their local branch and the new content of &amp;quot;master&amp;quot;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** From time to time, one of us has the responsibility to merge the changes and update the &amp;quot;master&amp;quot; branch with the latest version.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** One can look at the differences file by file: &amp;lt;code&amp;gt;git diff --color-words colleague1:paper_main.tex master:paper_main.tex&amp;lt;/code&amp;gt;. The options &amp;quot;--color-words&amp;quot; is especially useful in LaTeX.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** Once this is done, the others need to retrieve the new content of &amp;quot;master&amp;quot; in their local repo: &amp;lt;code&amp;gt;git checkout master&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;git fetch origin&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;git diff master origin/master&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;git merge origin/master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** To merge the content of &amp;quot;master&amp;quot; into his own branch, we do: &amp;lt;code&amp;gt;git merge master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** Then, they need to update their local branch with the new content of &amp;quot;master&amp;quot;: &amp;lt;code&amp;gt;git checkout colleague1&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;git diff --name-status colleague1..master&amp;lt;/code&amp;gt;. This will list the files having differences between their local branch and the new content of &amp;quot;master&amp;quot;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** In case of conflicts, we have to edit our own files by hand. Or we can also choose to ignore the conflicts and overwrite our local files with the content of &amp;quot;master&amp;quot; one file at a time: &amp;lt;code&amp;gt;git checkout --patch master paper_main.tex&amp;lt;/code&amp;gt;. Even more radical, we can decide to &amp;quot;overwrite&amp;quot; our personal local branch with our local, recently-updated &amp;quot;master&amp;quot; branch (all files at once): &amp;lt;code&amp;gt;git checkout colleague1&amp;lt;/code&amp;gt; followed by &amp;lt;code&amp;gt;git reset --hard master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** One can look at the differences file by file: &amp;lt;code&amp;gt;git diff --color-words colleague1:paper_main.tex master:paper_main.tex&amp;lt;/code&amp;gt;. The options &amp;quot;--color-words&amp;quot; is especially useful in LaTeX.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** To merge the content of &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;the recently-updated local &lt;/ins&gt;&amp;quot;master&amp;quot; into his own &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;local &lt;/ins&gt;branch, we do: &amp;lt;code&amp;gt;git merge master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;*&lt;/ins&gt;** In case of conflicts, we have to edit our own files by hand. Or we can also choose to ignore the conflicts and overwrite our local files with the content of &amp;quot;master&amp;quot; one file at a time: &amp;lt;code&amp;gt;git checkout --patch master paper_main.tex&amp;lt;/code&amp;gt;. Even more radical, we can decide to &amp;quot;overwrite&amp;quot; our personal local branch with our local, recently-updated &amp;quot;master&amp;quot; branch (all files at once): &amp;lt;code&amp;gt;git checkout colleague1&amp;lt;/code&amp;gt; followed by &amp;lt;code&amp;gt;git reset --hard master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;!-- ##### DO NOT edit below this line unless you know what you are doing. ##### --&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;!-- ##### DO NOT edit below this line unless you know what you are doing. ##### --&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff generator: internal 2013-05-23 23:34:40 --&gt;
&lt;/table&gt;</description>
			<pubDate>Thu, 01 Nov 2012 22:48:34 GMT</pubDate>			<dc:creator>Timothee Flutre</dc:creator>			<comments>http://openwetware.org/wiki/User_talk:Timothee_Flutre/Notebook/Postdoc/2012/08/14</comments>		</item>
		<item>
			<title>Timothee Flutre: /* About Git */ add git reset</title>
			<link>http://openwetware.org/index.php?title=User:Timothee_Flutre/Notebook/Postdoc/2012/08/14&amp;diff=641709&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;About Git:&amp;#32;&lt;/span&gt; add git reset&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr valign='top'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 16:39, 25 October 2012&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 32:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 32:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** One can look at the differences file by file: &amp;lt;code&amp;gt;git diff --color-words colleague1:paper_main.tex master:paper_main.tex&amp;lt;/code&amp;gt;. The options &amp;quot;--color-words&amp;quot; is especially useful in LaTeX.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** One can look at the differences file by file: &amp;lt;code&amp;gt;git diff --color-words colleague1:paper_main.tex master:paper_main.tex&amp;lt;/code&amp;gt;. The options &amp;quot;--color-words&amp;quot; is especially useful in LaTeX.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** To merge the content of &amp;quot;master&amp;quot; into his own branch, we do: &amp;lt;code&amp;gt;git merge master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** To merge the content of &amp;quot;master&amp;quot; into his own branch, we do: &amp;lt;code&amp;gt;git merge master&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** In case of conflicts, we have to edit our own files by hand. Or we can also choose to ignore the conflicts and overwrite our local files with the content of &amp;quot;master&amp;quot;: &amp;lt;code&amp;gt;git checkout --patch master paper_main.tex&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;** In case of conflicts, we have to edit our own files by hand. Or we can also choose to ignore the conflicts and overwrite our local files with the content of &amp;quot;master&amp;quot; &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;one file at a time&lt;/ins&gt;: &amp;lt;code&amp;gt;git checkout --patch master paper_main.tex&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;&amp;lt;/code&amp;gt;. Even more radical, we can decide to &amp;quot;overwrite&amp;quot; our personal local branch with our local, recently-updated &amp;quot;master&amp;quot; branch (all files at once): &amp;lt;code&amp;gt;git checkout colleague1&amp;lt;/code&amp;gt; followed by &amp;lt;code&amp;gt;git reset --hard master&lt;/ins&gt;&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;!-- ##### DO NOT edit below this line unless you know what you are doing. ##### --&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;!-- ##### DO NOT edit below this line unless you know what you are doing. ##### --&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;!-- diff generator: internal 2013-05-23 23:34:40 --&gt;
&lt;/table&gt;</description>
			<pubDate>Thu, 25 Oct 2012 16:39:00 GMT</pubDate>			<dc:creator>Timothee Flutre</dc:creator>			<comments>http://openwetware.org/wiki/User_talk:Timothee_Flutre/Notebook/Postdoc/2012/08/14</comments>		</item>
	</channel>
</rss>
