git-lkml for stupid people (like me)
Posted on August 16th, 2007 by Christian in Gentoo
OK, as Stephen recently asked why there is a double inclusion of
But, git ain’t easy for people like me (who are used to the easiness of say - subversion or even cvs). So here’s what I did (thanks to Fernando for the help earlier today):
$ vim kernel/sysctl.c // change something $ git checkout -b sysctl // create a new branch from your changes, based upon the master repository $ git commit -a -s // commit the changes to your newly created branch $ git format-patch master..sysctl // Enter a subject and then a separate description // and you should have a new file in the current working directory starting like 0001-*.patch
Now you should have a mailable patch, ready to be sent upstream that looks like this:
From 839ce261cf688d62bebd9ae3a0101dd672018940 Mon Sep 17 00:00:00 2001 From: Christian Heim <phreak@gentoo.org> Date: Sun, 19 Aug 2007 12:51:52 +0200 Subject: [PATCH] Remove double inclusion of linux/capability.h Remove the second inclusion of linux/capability.h, which has been introduced with "[PATCH] move capable() to capability.h" (or commit c59ede7b78db329949d9cdcd7064e22d357560ef). Signed-off-by: Christian Heim <phreak@gentoo.org> --- kernel/sysctl.c | 1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/kernel/sysctl.c b/kernel/sysctl.c index 8bdb8c0..9029690 100644 --- a/kernel/sysctl.c +++ b/kernel/sysctl.c @@ -27,7 +27,6 @@ #include <linux/capability.h> #include <linux/ctype.h> #include <linux/utsname.h> -#include <linux/capability.h> #include <linux/smp_lock.h> #include <linux/fs.h> #include <linux/init.h> -- 1.5.3.rc4
And if you wanna delete the branch afterwards again, just do this:
$ git checkout master // Switch back to the master branch $ git branch -D sysctl // Delete the old branch named "sysctl"
PacketPro 450 and SSH checks
Posted on August 5th, 2007 by Christian in Life
As apparently the guys at Teamix read my recent blog post about their cluster solution, someone of their technical support called me on friday at work ![]()
And pointed out
- That I’m free to express my thoughts about their product (which I recently did)
- That there is a better way to workaround this issue
He also said, its something which they had asked multiple times. It’s as simple as editing the Virtual Server and changing the service inspection from “Connection” to “None” .. *duh*
Don’t get me wrong, the previous rant simply originated from the logs filling up within three day. I still like the PacketPro.
Praise teh sed
Posted on August 5th, 2007 by Christian in Gentoo, Life
Since my talk with Robin on Thursday regarding the autogenerated userinfo.xml, I finally found some time today to get all the info’s I need out of userinfo.xml.
Since I don’t really want to manually enter all those mail addresses from userinfo into LDAP manually, I figured sed might be my best friend. *BUT* sed ain’t easy .. But thanks to Fabian and Gilles, I learned something new about sed today ..
Basically I searched for a way to transform userinfo.xml into a datafile for ldapedit.
As most of you know, userinfo.xml would look like this:
<user username="phreak"> <realname fullname="Christian Heim"> <firstname>Christian</firstname> <familyname>Heim</familyname> </realname> <pgpkey>0x9A9F68E6</pgpkey> <email role="gentoo">phreak@gentoo.org</email> <joined>06 August 2005</joined> <birthday></birthday> <roles>vserver, openvz, kernel</roles> <location longitude="13.032" latitude="54.251">Germany, Stralsund</location> </user>
So the first step would be to simply use egrep on userinfo.xml to filter only the things I needed ..
celsius roll-call [0] $ egrep "(username=|<email |</user>)" \ userinfo.xml
That looks more like a processable list to me. Now I only needed to convert the
This is what I applied on top of the above filter:
celsius roll-call [0] $ egrep "(username=|<email |</user>)" \ userinfo.xml | \ sed -e "s,.*<user username=\",dn: uid=," \ -e "s,\">$,\,ou=devs\,dc=gentoo\,dc=org\nadd: mail," \ -e 's,.*<email role="\\(gentoo\\|primary\\)">,mail: ,' \ -e "s,</email>,," -e "s, </user>,,"
And that’s it, I just need to check the dn’s for all the users, and when I’m done with that, finito!