<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Format-Patch on BAFM</title><link>https://christian.blog.pakiheim.de/tags/format-patch/</link><description>Recent content in Format-Patch on BAFM</description><generator>Hugo -- 0.160.1</generator><language>en</language><lastBuildDate>Thu, 16 Aug 2007 14:06:43 +0000</lastBuildDate><atom:link href="https://christian.blog.pakiheim.de/tags/format-patch/index.xml" rel="self" type="application/rss+xml"/><item><title>git-lkml for stupid people (like me)</title><link>https://christian.blog.pakiheim.de/posts/2007-08-16_git-lkml-for-stupid-people-like-me/</link><pubDate>Thu, 16 Aug 2007 14:06:43 +0000</pubDate><guid isPermaLink="false">http://blog.barfoo.org/2007/08/16/git-lkml-for-stupid-people-like-me/</guid><description>&lt;p&gt;OK, as &lt;a href="http://www.steev.net/"&gt;Stephen&lt;/a&gt; recently asked why there is a double inclusion of in &lt;a href="http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=blob;f=kernel/sysctl.c;hb=HEAD"&gt;kernel/sysctl.c&lt;/a&gt; (and I asked Greg and Randy); I finally decided to write a patch to the LKML for possible inclusion.&lt;/p&gt;
&lt;p&gt;But, git ain&amp;rsquo;t easy for people like me (who are used to the easiness of say - subversion or even cvs). So here&amp;rsquo;s what I did (thanks to &lt;a href="http://blogs.gentoo.org/ferdy"&gt;Fernando&lt;/a&gt; for the help earlier today):&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;div class="chroma"&gt;
&lt;table class="lntable"&gt;&lt;tr&gt;&lt;td class="lntd"&gt;
&lt;pre tabindex="0" class="chroma"&gt;&lt;code&gt;&lt;span class="lnt" id="hl-0-1"&gt;&lt;a class="lnlinks" href="#hl-0-1"&gt;1&lt;/a&gt;
&lt;/span&gt;&lt;span class="lnt" id="hl-0-2"&gt;&lt;a class="lnlinks" href="#hl-0-2"&gt;2&lt;/a&gt;
&lt;/span&gt;&lt;span class="lnt" id="hl-0-3"&gt;&lt;a class="lnlinks" href="#hl-0-3"&gt;3&lt;/a&gt;
&lt;/span&gt;&lt;span class="lnt" id="hl-0-4"&gt;&lt;a class="lnlinks" href="#hl-0-4"&gt;4&lt;/a&gt;
&lt;/span&gt;&lt;span class="lnt" id="hl-0-5"&gt;&lt;a class="lnlinks" href="#hl-0-5"&gt;5&lt;/a&gt;
&lt;/span&gt;&lt;span class="lnt" id="hl-0-6"&gt;&lt;a class="lnlinks" href="#hl-0-6"&gt;6&lt;/a&gt;
&lt;/span&gt;&lt;span class="lnt" id="hl-0-7"&gt;&lt;a class="lnlinks" href="#hl-0-7"&gt;7&lt;/a&gt;
&lt;/span&gt;&lt;span class="lnt" id="hl-0-8"&gt;&lt;a class="lnlinks" href="#hl-0-8"&gt;8&lt;/a&gt;
&lt;/span&gt;&lt;span class="lnt" id="hl-0-9"&gt;&lt;a class="lnlinks" href="#hl-0-9"&gt;9&lt;/a&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;
&lt;td class="lntd"&gt;
&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-fallback" data-lang="fallback"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;$ vim kernel/sysctl.c
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;// change something
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;$ git checkout -b sysctl
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;// create a new branch from your changes, based upon the master repository
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;$ git commit -a -s
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;// commit the changes to your newly created branch
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;$ git format-patch master..sysctl
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;// Enter a subject and then a separate description
&lt;/span&gt;&lt;/span&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;// and you should have a new file in the current working directory starting like 0001-*.patch
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;
&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;Now you should have a mailable patch, ready to be sent upstream that looks like this:&lt;/p&gt;</description></item></channel></rss>