Archive for August, 2009

WordPress: How-to add a meta-box in the post page

Monday, August 31st, 2009

Typically, I had to do this to modify the DZone plug-in which had some ugly configuration to modify the post subpanel in the WordPress administration page.

Then, here the few things you need to do to create a beautiful meta-box within any WordPress post page :)

This code will works for any version of WordPress 2.x. Since wordpress 2.5, a new API has been defined to allow easily to add admin meta-box but if you want to create a plug-in compatible with older version of wordpress, here is the way…

(more…)

Distributed OSGi, an elegant way to distribute software

Sunday, August 30th, 2009

Before talking about distribution, I will talk a little about OSGi.

This platform was primarily intended to work on mobile device. Therefore, it has been design to be light and focusing on the principal (KISS Principle).

Every developer who had used Java programming more than just some Hello World tests, will understand the Jar Hell and the fun with the Class-path.
OSGi has too primary goals, first its modular system which allow to manage module (they call it Bundle) life-cycle, module version management and module dependencies. It’s particularly important for applications who need to run with small memory to only load what is necessary.
The second important goal of the core of OSGi is its service registry, once again focus on the minimum and just allow a module to register its services on the registry in a really purely manner. (more…)

DRY or SOFT ?

Sunday, August 30th, 2009

The dry principle, Don’t Repeat yourself is the second principles in my series of architecture principle I will write on.

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

I’m often talking about “meaning”, every piece of software should have only one meaning, other says responsibility. Therefore, if we have applying correctly this pattern, every times we have to made a change into our software, we don’t have to re-factor the whole stack. Exception of the cross-cutting concern (i18n, security, logging, …), modifying a module should not impact another module.

I’m not fan of code generator (someday i will write an article on that :) ), but for the sake of this principle, I think i would prefer having some code generation than having to copy/paste code. As long as the code generated is NEVER modified, it’s fine.

(more…)

Apple Buying guide

Wednesday, August 26th, 2009

MacRumorsAs all Apple user, you fill frustrated because you don’t know when you will buy your new equiment if a new one will come :( . Hopefully, macrumors has created a guide for you : http://buyersguide.macrumors.com/. It’s time to buy a MacBook pro with Snow Leopard on It :)

The KISS Principle

Tuesday, August 25th, 2009

I will write a series of article around architecture principles I follow.

Often, in the software industry, it’s hard to say “STOP, this software doesn’t need more”. We have a tendency as human to  wants more and we apply this pattern (Yes, I have said the word “pattern” :) ) to our software.

Therefore, following the KISS principle could be against nature. Every times I starting to design a component, writing some code, creating a information system architecture, I keep saying to myself, “do we really need this ?”, “Is that is not too much complicated ?”, “Is there something simpler to do the same job ?”…

I will become evangelist here. I see this principle as the prime principle :) . Before thinking of DRY or SOLID principles which are very important, as a whole, we should always keep modesty and try to add only what is really needed to our software. When i mean “add”, I mean, features, 3rd Parties libraries, source codes , commentaries…

By the way, I like this quote on the wiki link :

The principle most likely finds its origins in similar concepts, such as Occam’s razor, and Albert Einstein‘s maxim that “everything should be made as simple as possible, but no simpler”.[2] Leonardo Da Vinci‘s “Simplicity is the ultimate sophistication”, or Antoine de Saint Exupéry‘s “It seems that perfection is reached not when there is nothing left to add, but when there is nothing left to take away”.

Mac OS X on a Core I7

Sunday, August 23rd, 2009

Here the results of Mac OS X installed on my core I7 920:

Mac OS X on core i7

Pretty amazing how it works fast and how stable the system is :)

Installation iAtKOS 7 on Gigabyte EX58-UD4P

Saturday, August 22nd, 2009

Hi All,

here my first HOW-TO : How to install mac os X under a bare PC :

Step 1 : Follow this guide here :

  • Don’t pick up any VGA card (it might cause blue screen),
  • Neither pick ACPI Driver, it works without it and it cause me trouble with my graphic card.
  • Pick Voodoo kernel 9.5.0, the one suggested could make vmware to crash.

Step 2 : reboot and type “busratio=20 -x -v” when the chameleon appears

You should be able to boot without any vga card kernel extension set

You might be able to found pkg files corresponding to your graphical card and you can install them afterwards (works for me with ATI Radeon HD 3650 PCIe, here is the link you should use)

Modify the file /Library/Preferences/SystemConfiguration/com.apple.Boot.plist

<?xml version=”1.0″ encoding=”UTF-8″?>
<!DOCTYPE plist PUBLIC “-//Apple Computer//DTD PLIST 1.0//EN” “http://www.apple.com/DTDs/PropertyList-1.0.dtd”>
<plist version=”1.0″>
<dict>
<key>Kernel</key>
<string>custom</string>
<key>Kernel Flags</key>
<string>busratio=20</string>
<key>Boot Graphics</key>
<string>Yes</string>
<key>Quiet Boot</key>
<string>No</string>
<key>Timeout</key>
<string>5</string>
</dict>
</plist>

If you see only one CPU on the Monitor, it’s normal, it doesn’t manage correctly yet core i7, you could verify using the About mac to verify the number of processor

Warning : DON’T Update to 10.5.8.

** Update : If like me, VMWare fusion is making a “kernel panic”, try to install generic voodoo kernel found here.

Source :

- http://www.insanelymac.com/forum/lofiversion/index.php/t172097.html

- http://www.insanelymac.com/forum/index.php?showtopic=107526&pid=1226120&mode=threaded&start=2000#entry1226120

- http://code.google.com/p/xnu-dev/