<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"
 xmlns:dc="http://purl.org/dc/elements/1.1/"
 xmlns:content="http://purl.org/rss/1.0/modules/content/">
<channel>
	<title><![CDATA[Clément Delafargue // Divarvel]]></title>
	<description><![CDATA[Flux RSS des articles]]></description>
	<pubDate>Thu, 02 Sep 2010 15:07:15 +0200</pubDate>
	<link>http://www.divarvel.fr</link>
	<language>fr</language>
	<generator>http://www.eklablog.com</generator>
	
	<item>
		<title><![CDATA[Tab Candy: They're (poorly) reinventing the Wheel]]></title>
		<link>http://www.divarvel.fr/tab-candy-they-re-poorly-reinventing-the-wheel-a1482303</link>
		<description><![CDATA[It's a fact, more and more applications are web-based, and the tabbed browsing shows its limits. Tabs are now like real applications and need to be managed more precisely and with less hassle. That's why the firefox folks created Tab Candy. This is stupid. There are tons of good window managers out...]]></description>
		<content:encoded><![CDATA[<p>It's a fact, more and more applications are web-based, and the tabbed browsing shows its limits. Tabs are now like real applications and need to be managed more precisely and with less hassle. That's why the firefox folks created Tab Candy.</p>
<p>This is stupid. There are tons of good window managers out there. Why do anybody need to spend time on reinventing one, which won't be as good as existing ones, in addition to create a strong separation between web apps and the regular ones ?</p>
<p>If you want to have several groups of tabs, use several windows. If you want to have a quick access to a web app, give it its own window (with uzbl or jumanji for instance). This way, all your applications (web or regular) behave consistently, and you can use the full power of your WM instead of beeing forced to use a stoneage WM inside your browser.</p>
<p>Problem solved.</p> http://data0.eklablog.com/divarvel/mod_article1482303_1.jpg<br /><br /><strong>Partager cet article :</strong> <a href="javascript:;" onclick="window.open('http://ek.la/twitter?blog=7&amp;path=tab-candy-they-re-poorly-reinventing-the-wheel-a1482303&amp;title=Tab+Candy%3A+They%27re+%28poorly%29+reinventing+the+Wheel');" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Diffuser sur Twitter&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/retweet.png" alt="Retweet" class="icon" /></a> <a href="http://www.wikio.fr/vote?url=http%3A%2F%2Fwww.divarvel.fr%2Ftab-candy-they-re-poorly-reinventing-the-wheel-a1482303" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Voter sur wikio&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/wikio.gif" alt="Wikio" class="icon" /></a> <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.divarvel.fr%2Ftab-candy-they-re-poorly-reinventing-the-wheel-a1482303&amp;layout=button_count&amp;show_faces=false&amp;width=110&amp;action=like&amp;colorscheme=light&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:110px; height:20px;" class="icon" allowTransparency="true"></iframe><br />]]></content:encoded>
		<pubDate>Thu, 29 Jul 2010 08:09:16 +0200</pubDate>
		<guid isPermaLink="true">http://www.divarvel.fr/tab-candy-they-re-poorly-reinventing-the-wheel-a1482303</guid>
		<dc:creator>divarvel</dc:creator>
		<dc:date>2010-07-29T08:09:16+02:00</dc:date>
	</item>
	<item>
		<title><![CDATA[Environnement de développement Android - Sans Eclipse]]></title>
		<link>http://www.divarvel.fr/environnement-de-developpement-android-sans-eclipse-a1291837</link>
		<description><![CDATA[Je viens de faire l'acquisisition d'un Nexus One (j'&eacute;tais lass&eacute; des restrictions &agrave; la Apple ), et bien &eacute;videmment la premi&egrave;re envie que j'ai c'est de d&eacute;velopper des applis Android pour faire un peu joujou avec la b&ecirc;te. J'ai trouv&eacute; pas mal de ressources pour d&eacute;buter, mais toute ont pour...]]></description>
		<content:encoded><![CDATA[<a href="http://www.flickr.com/photos/toasty/3538820892/"><img style="float: left; padding-right: 5px;" src="http://data0.eklablog.com/divarvel/mod_article1291837_1.jpg?3561" alt="Android"/></a>
<p>Je viens de faire l'acquisisition d'un <strong>Nexus One</strong> (j'&eacute;tais lass&eacute; des <a href="http://www.divarvel.fr/iphone-ou-l-emprisonnement-numerique-a324755">restrictions &agrave; la Apple</a>), et bien &eacute;videmment la premi&egrave;re envie que j'ai c'est de d&eacute;velopper des applis Android pour faire un peu joujou avec la b&ecirc;te.</p>
<p>J'ai trouv&eacute; pas mal de ressources pour d&eacute;buter, mais toute ont pour point commun l'installation d'un CPU / Memory Hog : le tristement c&eacute;l&egrave;bre Eclipse.</p>
<p>Voici donc une petite compilation de ce que j'ai pu trouver pour <strong>d&eacute;ployer et utiliser un environnement de d&eacute;veloppement Android</strong> sous Ubuntu (#<em>Insert troll here</em>#), <strong>qui ne fasse pas appel &agrave; Eclipse</strong>.</p><br /><br /><a href="http://www.divarvel.fr/environnement-de-developpement-android-sans-eclipse-a1291837">Lire la suite...</a><br /><br /><strong>Partager cet article :</strong> <a href="javascript:;" onclick="window.open('http://ek.la/twitter?blog=7&amp;path=environnement-de-developpement-android-sans-eclipse-a1291837&amp;title=Environnement+de+d%C3%A9veloppement+Android+-+Sans+Eclipse');" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Diffuser sur Twitter&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/retweet.png" alt="Retweet" class="icon" /></a> <a href="http://www.wikio.fr/vote?url=http%3A%2F%2Fwww.divarvel.fr%2Fenvironnement-de-developpement-android-sans-eclipse-a1291837" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Voter sur wikio&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/wikio.gif" alt="Wikio" class="icon" /></a> <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.divarvel.fr%2Fenvironnement-de-developpement-android-sans-eclipse-a1291837&amp;layout=button_count&amp;show_faces=false&amp;width=110&amp;action=like&amp;colorscheme=light&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:110px; height:20px;" class="icon" allowTransparency="true"></iframe><br />]]></content:encoded>
		<pubDate>Mon, 31 May 2010 19:59:17 +0200</pubDate>
		<guid isPermaLink="true">http://www.divarvel.fr/environnement-de-developpement-android-sans-eclipse-a1291837</guid>
		<dc:creator>divarvel</dc:creator>
		<dc:date>2010-05-31T19:59:17+02:00</dc:date>
	</item>
	<item>
		<title><![CDATA[Partager sa musique]]></title>
		<link>http://www.divarvel.fr/partager-sa-musique-a1258244</link>
		<description><![CDATA[Je viens d'avoir une id&eacute;e toute b&ecirc;te, un moyen de partager sa musique et de socialiser. Socialiser dans la vraie vie, en plus. ( IRL pour les pros) &Eacute;norm&eacute;ment de monde se balade avec des &eacute;couteurs sur les oreilles. Pourquoi ne pas de temps en temps, prendre deux minutes et &eacute;changer les...]]></description>
		<content:encoded><![CDATA[<p><a href="http://www.flickr.com/photos/eriatarka31/3647727697/"><img style="float: left; padding-right: 5px;" src="http://data0.eklablog.com/divarvel/mod_article1258244_2.jpg?170" alt="Guitare"/></a>Je viens d'avoir une id&eacute;e toute b&ecirc;te, un moyen de partager sa musique et de socialiser.</p>
<p>Socialiser dans la vraie vie, en plus. (<abbr title="In Real Life">IRL</abbr> pour les pros)</p>
<p>&Eacute;norm&eacute;ment de monde se balade avec des &eacute;couteurs sur les oreilles. Pourquoi ne pas de temps en temps, prendre deux minutes et &eacute;changer les &eacute;couteurs, pour d&eacute;couvrir ce que les autres &eacute;coutent, et faire d&eacute;couvrir ce qu'on &eacute;coute ?</p>
<p>Il suffirait d'avoir un petit signe distinctif <ins>(Par exemple un morceau d'adh&eacute;sif rouge autour du c&acirc;ble)</ins> sur ses &eacute;couteurs pour signaler qu'on est pr&ecirc;t &agrave; s'arr&ecirc;ter deux minutes pour partager sa musique. &Ccedil;a pourrait &ecirc;tre cool de s'arr&ecirc;ter deux minutes et de discuter musique avec d'autres gens, non ?</p>
<p><em>Vous en pensez quoi ?</em></p>
<p>&nbsp;</p>
<p><em>Cr&eacute;dit Photo :<a href="http://www.flickr.com/photos/eriatarka31/"> Gr&eacute;gory Thonon</a> <a href="http://creativecommons.org/licenses/by-sa/2.0/deed.fr">(CC-BY-SA 2.0 Deed)</a><br /></em></p><br /><br /><strong>Partager cet article :</strong> <a href="javascript:;" onclick="window.open('http://ek.la/twitter?blog=7&amp;path=partager-sa-musique-a1258244&amp;title=Partager+sa+musique');" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Diffuser sur Twitter&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/retweet.png" alt="Retweet" class="icon" /></a> <a href="http://www.wikio.fr/vote?url=http%3A%2F%2Fwww.divarvel.fr%2Fpartager-sa-musique-a1258244" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Voter sur wikio&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/wikio.gif" alt="Wikio" class="icon" /></a> <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.divarvel.fr%2Fpartager-sa-musique-a1258244&amp;layout=button_count&amp;show_faces=false&amp;width=110&amp;action=like&amp;colorscheme=light&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:110px; height:20px;" class="icon" allowTransparency="true"></iframe><br />]]></content:encoded>
		<pubDate>Thu, 20 May 2010 05:10:47 +0200</pubDate>
		<guid isPermaLink="true">http://www.divarvel.fr/partager-sa-musique-a1258244</guid>
		<dc:creator>divarvel</dc:creator>
		<dc:date>2010-05-20T05:10:47+02:00</dc:date>
	</item>
	<item>
		<title><![CDATA[Cowon S9]]></title>
		<link>http://www.divarvel.fr/cowon-s9-a1234661</link>
		<description><![CDATA[J'ai re&ccedil;u hier un Cowon S9 , en remplacement de la solution mixte Archos 604 (batterie explos&eacute;e) / iPhone (j'en peux plus de cette bouse)

 Le Cowon S9 est un petit PMP de fabrication Cor&eacute;enne.

J'ai choisi ce mod&egrave;le principalement pour ses qualit&eacute;s audio et pour son support du format OGG...]]></description>
		<content:encoded><![CDATA[<a href="http://www.flickr.com/photos/divarvel/4603429608/"><img style="float: left; padding-right: 5px;" src="http://farm4.static.flickr.com/3554/4603429608_d5e83cc509_m.jpg" alt="Cowon S9"/></a>J'ai re&ccedil;u hier un <strong>Cowon S9</strong>, en remplacement de la solution mixte Archos 604 (batterie explos&eacute;e) / iPhone (j'en peux plus de cette bouse)<br /><br /> Le Cowon S9 est un petit PMP de fabrication Cor&eacute;enne.<br /><br />J'ai choisi ce mod&egrave;le principalement pour ses qualit&eacute;s audio et pour son <a href="http://www.fsf.org/campaigns/playogg/">support du format OGG</a>, mais la b&ecirc;te a d'autres caract&eacute;ristiques sympa.<br /><br /><br /><a href="http://www.divarvel.fr/cowon-s9-a1234661">Lire la suite...</a><br /><br /><strong>Partager cet article :</strong> <a href="javascript:;" onclick="window.open('http://ek.la/twitter?blog=7&amp;path=cowon-s9-a1234661&amp;title=Cowon+S9');" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Diffuser sur Twitter&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/retweet.png" alt="Retweet" class="icon" /></a> <a href="http://www.wikio.fr/vote?url=http%3A%2F%2Fwww.divarvel.fr%2Fcowon-s9-a1234661" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Voter sur wikio&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/wikio.gif" alt="Wikio" class="icon" /></a> <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.divarvel.fr%2Fcowon-s9-a1234661&amp;layout=button_count&amp;show_faces=false&amp;width=110&amp;action=like&amp;colorscheme=light&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:110px; height:20px;" class="icon" allowTransparency="true"></iframe><br />]]></content:encoded>
		<pubDate>Wed, 12 May 2010 03:35:10 +0200</pubDate>
		<guid isPermaLink="true">http://www.divarvel.fr/cowon-s9-a1234661</guid>
		<dc:creator>divarvel</dc:creator>
		<dc:date>2010-05-12T03:35:10+02:00</dc:date>
	</item>
	<item>
		<title><![CDATA[Journée Mondiale contre les DRM]]></title>
		<link>http://www.divarvel.fr/journee-mondiale-contre-les-drm-a1210436</link>
		<description><![CDATA[Aujourd'hui, c'est la Journ&eacute;e Mondiale contre les DRM .
L'op&eacute;ration, initi&eacute;e par la FSF , est relay&eacute;e en France par l' April .
C'est l'occasion de sensibiliser les gens autour de vous aux menaces que font peser les DRM sur les utilisateurs, et sur les d&eacute;veloppeurs de logiciels libres....]]></description>
		<content:encoded><![CDATA[<img style="float: left;" src="http://data0.eklablog.com/divarvel/mod_article1210436_1.jpg?7574" alt="Day Against DRM"/>Aujourd'hui, c'est la Journ&eacute;e Mondiale contre les <abbr title="Digital Restriction Management">DRM</abbr>.<br />L'op&eacute;ration, initi&eacute;e par la <a href="http://www.fsf.org"><abbr title="Free Software Foundation">FSF</abbr></a>, est relay&eacute;e en France par l'<a href="http://www.april.org/">April</a>.<br />C'est l'occasion de sensibiliser les gens autour de vous aux menaces que font peser les <abbr title="Digital Restriction Management">DRM</abbr> sur les utilisateurs, et sur les d&eacute;veloppeurs de logiciels libres.<br /><br />M&ecirc;me si en apparence, les <abbr title="Digital Restriction Management">DRM</abbr> ont battu en retraite du domaine de la musique (d&eacute;montrant par l&agrave; m&ecirc;me la vacuit&eacute; des lois type DADVSI, r&eacute;clam&eacute;es par l'industrie pour &ecirc;tre jet&eacute;es aux orties deux ans plus tard), elles n'en sont pas moins pr&eacute;sentes dans le domaine des eBooks. (J'ai re&ccedil;u un Cahier des Charges pour un reader sur iPhone, c'&eacute;tait vraiment dingue : interdiction du copier/coller, d&eacute;cryptage &agrave; la vol&eacute;e, impossibilit&eacute; d'imprimer...) et dans le domaine des applications mobiles. Je pense bien &eacute;videmment &agrave; l'Apple Store, parmi autres.<br /><br />En ce jour international de Star Wars, il est important d'essayer de sensibiliser ses proches aux dangers que repr&eacute;sentent les <abbr title="Digital Restriction Management">DRM</abbr>, et d'agir au maximum pour obtenir leur abandon.<br /><br />Un peu de lecture : <br /> 
<ul>
<li><a href="http://www.april.org/fr/drm">L'article de l'April sur les <abbr title="Digital Restriction Management">DRM</abbr></a></li>
<li><a href="http://www.defectivebydesign.org/">Defective by Design <br /></a></li>
</ul><br /><br /><strong>Partager cet article :</strong> <a href="javascript:;" onclick="window.open('http://ek.la/twitter?blog=7&amp;path=journee-mondiale-contre-les-drm-a1210436&amp;title=Journ%C3%A9e+Mondiale+contre+les+DRM');" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Diffuser sur Twitter&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/retweet.png" alt="Retweet" class="icon" /></a> <a href="http://www.wikio.fr/vote?url=http%3A%2F%2Fwww.divarvel.fr%2Fjournee-mondiale-contre-les-drm-a1210436" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Voter sur wikio&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/wikio.gif" alt="Wikio" class="icon" /></a> <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.divarvel.fr%2Fjournee-mondiale-contre-les-drm-a1210436&amp;layout=button_count&amp;show_faces=false&amp;width=110&amp;action=like&amp;colorscheme=light&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:110px; height:20px;" class="icon" allowTransparency="true"></iframe><br />]]></content:encoded>
		<pubDate>Tue, 04 May 2010 05:14:22 +0200</pubDate>
		<guid isPermaLink="true">http://www.divarvel.fr/journee-mondiale-contre-les-drm-a1210436</guid>
		<dc:creator>divarvel</dc:creator>
		<dc:date>2010-05-04T05:14:22+02:00</dc:date>
	</item>
	<item>
		<title><![CDATA[MPD + Quelques tweaks sous Ubuntu]]></title>
		<link>http://www.divarvel.fr/mpd-quelques-tweaks-sous-ubuntu-a1197124</link>
		<description><![CDATA[MPD est, comme son nom s'indique, un daemon qui lit de la musique. L'int&eacute;r&ecirc;t, est que la partie qui lit la musique est d&eacute;coupl&eacute;e de l'IHM qui permet de g&eacute;rer &ccedil;a.

Cette structure apporte plusieurs avantages :
 L&eacute;g&egrave;ret&eacute; (pas besoin d'occuper des ressources en permanence pour l'interface)...]]></description>
		<content:encoded><![CDATA[<abbr title="Media Player Daemon">MPD</abbr> est, comme son nom s'indique, un daemon qui lit de la musique. L'int&eacute;r&ecirc;t, est que la partie qui lit la musique est <strong>d&eacute;coupl&eacute;e</strong> de l'IHM qui permet de g&eacute;rer &ccedil;a.<br /><br />Cette structure apporte plusieurs avantages :<br /> 
<ul>
<li><strong>L&eacute;g&egrave;ret&eacute;</strong> (pas besoin d'occuper des ressources en permanence pour l'interface)</li>
</ul>
<ul>
<li><strong>Choix</strong> du nombre d'interfaces (il y en a vraiment pour tous les go&ucirc;ts, du <a href="http://linux.die.net/man/1/mpc">plus simple</a> au <a href="http://sonata.berlios.de/">plus sophistiqu&eacute;</a>, en passant par le <a href="http://unkart.ovh.org/ncmpcpp/">sobre et efficace</a>)</li>
</ul>
<ul>
<li>Possibilit&eacute; de commander <strong>par le r&eacute;seau</strong></li>
<li><strong>Interfa&ccedil;age rapide</strong> avec tout et n'importe quoi (<a href="http://www.divarvel.fr/un-peu-de-conky-a513079">conky</a>, par exemple)</li>
</ul>
J'ai donc install&eacute; et configur&eacute; <abbr title="Media Player Daemon">MPD</abbr>. (&Agrave; l'aide de la doc d'ubuntu-fr).<br /><br />J'ai eu ensuite &agrave; faire quelques petits tweaks pour int&eacute;grer &ccedil;a correctement &agrave; mon syst&egrave;me.<br />
<h3>Touches multim&eacute;dia</h3>
Comme <abbr title="Media Player Daemon">MPD</abbr> tourne en t&acirc;che de fond, si aucune interface n'est lanc&eacute;e, les touches multim&eacute;dia ne seront pas g&eacute;r&eacute;es.<br />Le plus simple est d'utiliser mpc, qui permet d'envoyer des commandes &agrave; <abbr title="Media Player Daemon">MPD</abbr>.<br />J'ai ainsi associ&eacute; la commande mpc toggle &agrave; la touche <em>XF86Play</em>, mpc stop &agrave; la touche <em>XF86Stop</em>, et ainsi de suite.<br /><br />Pour le fun, j'ai fait un petit script qui permet d'afficher les informations sur le morceau en cours &agrave; l'aide de libnotify.<br /><br /><div class="code"><span style="color: #666666; font-style: italic;">#!/bin/sh</span><br />
DISPLAY<span style="color: #339933;">=:</span><span style="color: #cc66cc;">0</span><br />
notify<span style="color: #339933;">-</span>send <span style="color: #0000ff;">&quot;`mpc --format &quot;</span><span style="color: #339933;">%</span>title<span style="color: #339933;">%</span><span style="color: #0000ff;">&quot;|head -n1`&quot;</span> <span style="color: #0000ff;">&quot;`mpc --format &quot;</span><span style="color: #339933;">%</span>artist<span style="color: #339933;">%</span> <span style="color: #339933;">-</span> <span style="color: #339933;">%</span>album<span style="color: #339933;">%</span><span style="color: #0000ff;">&quot;| head -n1`&quot;</span><div style="display:none;">[code=php]<br />#!/bin/sh<br />DISPLAY=:0<br />notify-send "`mpc --format "%title%"|head -n1`" "`mpc --format "%artist% - %album%"| head -n1`"<br />[/code]</div></div><br /><br />Rien de bien m&eacute;chant, mais &ccedil;a peut &ecirc;tre utile quand on veut savoir le nom du morceau en cours sans perdre trop de temps.<br /><br />
<h3>Scrobbling</h3>
Les clients <abbr title="Media Player Daemon">MPD</abbr> sophistiqu&eacute;s g&egrave;rent le scrobbling, mais, comme je l'ai dit, on n'a pas besoin d'avoir une interface en permanence.<br /><br />J'ai trouv&eacute; <a href="http://codingteam.net/project/scrobd">scrobd</a>, un petit script python qui permet de scrobbler sur libre.fm. (Saymieux que last.fm, et on a moins de risques de voir son nom refil&eacute; &agrave; la RIAA)<br /><br />&Eacute;tant donn&eacute; que tous les clients communiquent avec <abbr title="Media Player Daemon">MPD</abbr> par une interface TCP, il n'y a pas de difficult&eacute;s particuli&egrave;res pour que la musique soit jou&eacute;e sur un ordinateur distant, avec autant de facilit&eacute; que si c'&eacute;tait sur son propre PC.<br /><br />Pour plus d'informations :<br /> 
<ul>
<li><a href="http://mpd.wikia.com/wiki/Music_Player_Daemon_Wiki">Le Wiki de <abbr title="Media Player Daemon">MPD</abbr></a></li>
<li><a href="http://doc.ubuntu-fr.org/mpd">La page Ubuntu-fr d&eacute;di&eacute;e &agrave; <abbr title="Media Player Daemon">MPD</abbr></a></li>
</ul>
<br />Et merci &agrave; <a href="http://www.twitter.com/keruspe">@Keruspe</a> et <a href="http://www.twitter.com/efyx">@Efyx</a> pour m'avoir aid&eacute; &agrave; faire mes premiers pas avec <abbr title="Media Player Daemon">MPD</abbr><br /><br /><strong>Partager cet article :</strong> <a href="javascript:;" onclick="window.open('http://ek.la/twitter?blog=7&amp;path=mpd-quelques-tweaks-sous-ubuntu-a1197124&amp;title=MPD+%2B+Quelques+tweaks+sous+Ubuntu');" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Diffuser sur Twitter&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/retweet.png" alt="Retweet" class="icon" /></a> <a href="http://www.wikio.fr/vote?url=http%3A%2F%2Fwww.divarvel.fr%2Fmpd-quelques-tweaks-sous-ubuntu-a1197124" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Voter sur wikio&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/wikio.gif" alt="Wikio" class="icon" /></a> <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.divarvel.fr%2Fmpd-quelques-tweaks-sous-ubuntu-a1197124&amp;layout=button_count&amp;show_faces=false&amp;width=110&amp;action=like&amp;colorscheme=light&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:110px; height:20px;" class="icon" allowTransparency="true"></iframe><br />]]></content:encoded>
		<pubDate>Thu, 29 Apr 2010 06:03:09 +0200</pubDate>
		<guid isPermaLink="true">http://www.divarvel.fr/mpd-quelques-tweaks-sous-ubuntu-a1197124</guid>
		<dc:creator>divarvel</dc:creator>
		<dc:date>2010-04-29T06:03:09+02:00</dc:date>
	</item>
	<item>
		<title><![CDATA[Installer PHP 5.3 en gardant PHP 5.2 sous Ubuntu]]></title>
		<link>http://www.divarvel.fr/installer-php-5-3-en-gardant-php-5-2-sous-ubuntu-a1168969</link>
		<description><![CDATA[Dans le cadre de mon stage, je bosse sur un site cod&eacute; pour PHP 5.3, et j'ai donc eu &agrave; installer PHP5.3 sur ma b&eacute;cane.

Cette version de PHP n'&eacute;tant pas encore dans les d&eacute;p&ocirc;ts, et les paquets disponibles ayant des probl&egrave;mes de d&eacute;pendances non r&eacute;solues, le plus simple c'est de compiler. Le...]]></description>
		<content:encoded><![CDATA[Dans le cadre de mon stage, je bosse sur un site cod&eacute; pour PHP 5.3, et j'ai donc eu &agrave; installer PHP5.3 sur ma b&eacute;cane.<br /><br />Cette version de PHP n'&eacute;tant pas encore dans les d&eacute;p&ocirc;ts, et les paquets disponibles ayant des probl&egrave;mes de d&eacute;pendances non r&eacute;solues, le plus simple c'est de compiler. Le probl&egrave;me c'est qu'on perd la souplesse de la gestion modulaire de PHP.<br /><br />Ce que j'ai donc fait, c'est installer PHP5.3 en tant que binaire CGI, sans toucher &agrave; ma version de PHP 5.2 install&eacute;e en tant que module apache.<br /><br /><strong>Warning :</strong> Je mets cette m&eacute;thode &agrave; titre exp&eacute;rimental, pour faire du<strong> dev</strong> et du test. Ne vous amusez pas &agrave; mettre &ccedil;a sur un serveur de prod sans plus d'infos. Il y a pas mal de diff&eacute;rences avec le fonctionnement sous forme de module.<br /><br /><a href="http://www.divarvel.fr/installer-php-5-3-en-gardant-php-5-2-sous-ubuntu-a1168969">Lire la suite...</a><br /><br /><strong>Partager cet article :</strong> <a href="javascript:;" onclick="window.open('http://ek.la/twitter?blog=7&amp;path=installer-php-5-3-en-gardant-php-5-2-sous-ubuntu-a1168969&amp;title=Installer+PHP+5.3+en+gardant+PHP+5.2+sous+Ubuntu');" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Diffuser sur Twitter&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/retweet.png" alt="Retweet" class="icon" /></a> <a href="http://www.wikio.fr/vote?url=http%3A%2F%2Fwww.divarvel.fr%2Finstaller-php-5-3-en-gardant-php-5-2-sous-ubuntu-a1168969" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Voter sur wikio&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/wikio.gif" alt="Wikio" class="icon" /></a> <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.divarvel.fr%2Finstaller-php-5-3-en-gardant-php-5-2-sous-ubuntu-a1168969&amp;layout=button_count&amp;show_faces=false&amp;width=110&amp;action=like&amp;colorscheme=light&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:110px; height:20px;" class="icon" allowTransparency="true"></iframe><br />]]></content:encoded>
		<pubDate>Sun, 18 Apr 2010 22:23:32 +0200</pubDate>
		<guid isPermaLink="true">http://www.divarvel.fr/installer-php-5-3-en-gardant-php-5-2-sous-ubuntu-a1168969</guid>
		<dc:creator>divarvel</dc:creator>
		<dc:date>2010-04-18T22:23:32+02:00</dc:date>
	</item>
	<item>
		<title><![CDATA[La veille du départ]]></title>
		<link>http://www.divarvel.fr/la-veille-du-depart-a1114172</link>
		<description><![CDATA[&Ccedil;a y est, tous mes bagages sont faits, j'ai mon visa, j'ai pu dire au revoir &agrave; presque tout le monde avant de partir.

L'avion d&eacute;colle demain &agrave; 11H40 de CDG pour Philadelphie, puis Philadelphie / San Francisco.

I'll keep you posted ;-) 

 Partager cet article :]]></description>
		<content:encoded><![CDATA[<div style="text-align: justify;">&Ccedil;a y est, tous mes bagages sont faits, j'ai mon visa, j'ai pu dire au revoir &agrave; presque tout le monde avant de partir.<br /><br />L'avion d&eacute;colle demain &agrave; 11H40 de CDG pour Philadelphie, puis Philadelphie / San Francisco.<br /><br />I'll keep you posted ;-)</div><br /><br /><strong>Partager cet article :</strong> <a href="javascript:;" onclick="window.open('http://ek.la/twitter?blog=7&amp;path=la-veille-du-depart-a1114172&amp;title=La+veille+du+d%C3%A9part');" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Diffuser sur Twitter&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/retweet.png" alt="Retweet" class="icon" /></a> <a href="http://www.wikio.fr/vote?url=http%3A%2F%2Fwww.divarvel.fr%2Fla-veille-du-depart-a1114172" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Voter sur wikio&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/wikio.gif" alt="Wikio" class="icon" /></a> <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.divarvel.fr%2Fla-veille-du-depart-a1114172&amp;layout=button_count&amp;show_faces=false&amp;width=110&amp;action=like&amp;colorscheme=light&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:110px; height:20px;" class="icon" allowTransparency="true"></iframe><br />]]></content:encoded>
		<pubDate>Mon, 29 Mar 2010 00:57:58 +0200</pubDate>
		<guid isPermaLink="true">http://www.divarvel.fr/la-veille-du-depart-a1114172</guid>
		<dc:creator>divarvel</dc:creator>
		<dc:date>2010-03-29T00:57:58+02:00</dc:date>
	</item>
	<item>
		<title><![CDATA[Passer de SVN à Git + Gitosis]]></title>
		<link>http://www.divarvel.fr/passer-de-svn-a-git-gitosis-a1008783</link>
		<description><![CDATA[J'ai r&eacute;cemment r&eacute;alis&eacute; la migration de tous les projets EklaWeb de Subversion vers Git.
 
 Si vous voulez savoir pourquoi, je vous conseille cet excellent article de Scott Chacon 
 Pour r&eacute;sumer,
 Git est plus rapide Git est plus puissant Git est plus flexible J'ai ainsi migr&eacute; 3 d&eacute;p&ocirc;ts...]]></description>
		<content:encoded><![CDATA[<img style="float: left; padding-right: 5px;" src="http://data0.eklablog.com/divarvel/mod_article1008783_2.jpg?2447" alt="Git Logo"/>J'ai r&eacute;cemment r&eacute;alis&eacute; la migration de tous les projets EklaWeb de Subversion vers Git.<br /> <br /> Si vous voulez savoir pourquoi, je vous conseille cet <a hreflang="en" href="http://carsonified.com/blog/web-apps/why-you-should-switch-from-subversion-to-git/">excellent article de Scott Chacon</a><br /> Pour r&eacute;sumer,<br /> 
<ul>
<li>Git est plus rapide</li>
<li>Git est plus puissant</li>
<li>Git est plus flexible</li>
</ul>
J'ai ainsi migr&eacute; 3 d&eacute;p&ocirc;ts SVN vers Git tr&egrave;s simplement<br /><br /><a href="http://www.divarvel.fr/passer-de-svn-a-git-gitosis-a1008783">Lire la suite...</a><br /><br /><strong>Partager cet article :</strong> <a href="javascript:;" onclick="window.open('http://ek.la/twitter?blog=7&amp;path=passer-de-svn-a-git-gitosis-a1008783&amp;title=Passer+de+SVN+%C3%A0+Git+%2B+Gitosis');" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Diffuser sur Twitter&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/retweet.png" alt="Retweet" class="icon" /></a> <a href="http://www.wikio.fr/vote?url=http%3A%2F%2Fwww.divarvel.fr%2Fpasser-de-svn-a-git-gitosis-a1008783" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Voter sur wikio&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/wikio.gif" alt="Wikio" class="icon" /></a> <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.divarvel.fr%2Fpasser-de-svn-a-git-gitosis-a1008783&amp;layout=button_count&amp;show_faces=false&amp;width=110&amp;action=like&amp;colorscheme=light&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:110px; height:20px;" class="icon" allowTransparency="true"></iframe><br />]]></content:encoded>
		<pubDate>Fri, 12 Feb 2010 21:39:01 +0100</pubDate>
		<guid isPermaLink="true">http://www.divarvel.fr/passer-de-svn-a-git-gitosis-a1008783</guid>
		<dc:creator>divarvel</dc:creator>
		<dc:date>2010-02-12T21:39:01+01:00</dc:date>
	</item>
	<item>
		<title><![CDATA[Un petit script pour faire du Benchmark]]></title>
		<link>http://www.divarvel.fr/un-petit-script-pour-faire-du-benchmark-a513093</link>
		<description><![CDATA[Dans le cadre d'un travail demand&eacute; en cours de Th&eacute;orie des Graphes, je devais regarder l' &eacute;volution du temps d'ex&eacute;cution d'un programme en fonction d'un param&egrave;tre. (Pour les curieux, c'est la k-Coloration d'un Graphe &agrave; n Sommets)

Je me suis bricol&eacute; un petit script qui fait &ccedil;a tout seul,...]]></description>
		<content:encoded><![CDATA[<img style="float: left; padding-right: 5px;" src="http://data0.eklablog.com/divarvel/mod_article513093_4.png" alt="Un petit script pour faire du Benchmark" width="500"/>Dans le cadre d'un travail demand&eacute; en cours de Th&eacute;orie des Graphes, je devais regarder l'<strong>&eacute;volution du temps d'ex&eacute;cution d'un programme</strong> en fonction d'un param&egrave;tre. (Pour les curieux, c'est la k-Coloration d'un Graphe &agrave; n Sommets)<br /><br />Je me suis bricol&eacute; un petit script qui fait &ccedil;a tout seul, et g&eacute;n&egrave;re un graphe (via l'excellent <a href="http://www.gnuplot.info/">GnuPlot</a>) (ou affiche les temps d'ex&eacute;cution)<br /><br />C'est la premi&egrave;re fois que je fais un vrai script en Bash (<em>ie</em> un script qui n'est pas 3 commandes mises &agrave; la suite), du coup, pour la structure, je me suis inspir&eacute; d'un petit script de <a href="http://p4bl0.net/">P4bl0</a>.<br /><br />Le nom du programme &agrave; tester est <em>hard coded</em>, mais ce n'est pas tr&egrave;s dur &agrave; modifier.<br /><br />N'h&eacute;sitez pas &agrave; vous en servir si &ccedil;a vous est utile ;-), de m&ecirc;me que toutes les critiques sont les bienvenues (je n'y connais pas grand chose (pour ne pas dire que dalle) en scripts Bash)<br /><br />L'usage, c'est $[...]:~&gt; <strong>./bench.sh [-i n] p n1 n2 itv graphe.png</strong><br /><em><strong>n1</strong></em> <em>valeur de d&eacute;part</em> du param&egrave;tre<br /><strong><em>n2</em></strong><em> valeur finale</em> du param&egrave;tre<br /><strong><em>itv</em></strong> <em>variation du param&egrave;tre</em> &agrave; chaque pas<br /><strong><em>graphe.png</em></strong> nom du fichier g&eacute;n&eacute;r&eacute;<br />Pour le<strong> -i n</strong>, n est le nombre d'ex&eacute;cutions du programme pour chaque point (par d&eacute;faut, 10)<br /><br /><div class="code"><span style="color: #666666; font-style: italic;">#!/bin/sh</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;$1&quot;</span> = <span style="color: #ff0000;">&quot;-i&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span><br />
  <span style="color: #007800;">ITER</span>=<span style="color: #ff0000;">&quot;$2&quot;</span><br />
  <span style="color: #7a0874; font-weight: bold;">shift</span><br />
  <span style="color: #7a0874; font-weight: bold;">shift</span><br />
<span style="color: #000000; font-weight: bold;">else</span><br />
  <span style="color: #007800;">ITER</span>=<span style="color: #ff0000;">&quot;10&quot;</span><br />
<span style="color: #000000; font-weight: bold;">fi</span><br />
<br />
_bench_usage<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span><br />
  <span style="color: #c20cb9; font-weight: bold;">cat</span> <span style="color: #cc0000; font-style: italic;">&lt;&lt;USAGE<br />
Usage: bench disp n1 n2 interval : Affiche le temps pris pour traiter des graphes de n sommets, n variant de n1 à n2 par pas de interval.<br />
       bench plot n1 n2 interval file: Crée le fichier file, un graphique PNG affichant le temps pris pour traiter des graphes de n sommets,<br />
                                   n variant de n1 à n2 par pas de interval.<br />
       bench help: Affiche cette page d'aide.<br />
  La première lettre de chaque commande peut être utilisée<br />
  Le flag -i permet de spécifier combien de fois un graphe à n sommets doit être calculé.<br />
  Valeur par défaut : 10<br />
USAGE</span><br />
<span style="color: #7a0874; font-weight: bold;">&#125;</span><br />
<br />
_bench_disp<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span><br />
  <span style="color: #007800;">i</span>=$<span style="color: #000000;">1</span><br />
  <span style="color: #000000; font-weight: bold;">while</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #007800;">$i</span> <span style="color: #660033;">-le</span> $<span style="color: #000000;">2</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">do</span><br />
    <span style="color: #007800;">START</span>=$<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #c20cb9; font-weight: bold;">date</span> +<span style="color: #000000; font-weight: bold;">%</span>s<span style="color: #7a0874; font-weight: bold;">&#41;</span><br />
    _bench_run<br />
    <span style="color: #007800;">STOP</span>=$<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #c20cb9; font-weight: bold;">date</span> +<span style="color: #000000; font-weight: bold;">%</span>s<span style="color: #7a0874; font-weight: bold;">&#41;</span><br />
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Graphe à&quot;</span> <span style="color: #007800;">$i</span> <span style="color: #ff0000;">&quot;sommets :&quot;</span> $<span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #007800;">$STOP</span>-<span style="color: #007800;">$START</span><span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #ff0000;">&quot;secondes&quot;</span><br />
    <span style="color: #007800;">i</span>=$<span style="color: #7a0874; font-weight: bold;">&#91;</span>i + $<span style="color: #000000;">3</span><span style="color: #7a0874; font-weight: bold;">&#93;</span><br />
  <span style="color: #000000; font-weight: bold;">done</span><br />
<span style="color: #7a0874; font-weight: bold;">&#125;</span><br />
<br />
_bench_plot<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span><br />
  <span style="color: #666666; font-style: italic;"># Création d'un fichier temporaire contenant les données à afficher</span><br />
  <span style="color: #007800;">i</span>=$<span style="color: #000000;">1</span><br />
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;# Temps de calcul pour des graphes de &quot;</span>$<span style="color: #000000;">1</span><span style="color: #ff0000;">&quot; à &quot;</span>$<span style="color: #000000;">2</span><span style="color: #ff0000;">&quot; sommets (par pas de &quot;</span>$<span style="color: #000000;">3</span><span style="color: #ff0000;">&quot;)&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;</span> plot.dat<br />
  <span style="color: #000000; font-weight: bold;">while</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #007800;">$i</span> <span style="color: #660033;">-lt</span> $<span style="color: #000000;">2</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">do</span><br />
    <span style="color: #007800;">START</span>=$<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #c20cb9; font-weight: bold;">date</span> +<span style="color: #000000; font-weight: bold;">%</span>s<span style="color: #7a0874; font-weight: bold;">&#41;</span><br />
    _bench_run<br />
    <span style="color: #007800;">STOP</span>=$<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #c20cb9; font-weight: bold;">date</span> +<span style="color: #000000; font-weight: bold;">%</span>s<span style="color: #7a0874; font-weight: bold;">&#41;</span><br />
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #007800;">$i</span> $<span style="color: #7a0874; font-weight: bold;">&#91;</span><span style="color: #007800;">$STOP</span>-<span style="color: #007800;">$START</span><span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> plot.dat<br />
    <span style="color: #007800;">i</span>=$<span style="color: #7a0874; font-weight: bold;">&#91;</span>i + $<span style="color: #000000;">3</span><span style="color: #7a0874; font-weight: bold;">&#93;</span><br />
  <span style="color: #000000; font-weight: bold;">done</span><br />
<br />
  <span style="color: #666666; font-style: italic;"># Génération du graphe</span><br />
  gnuplot<span style="color: #cc0000; font-style: italic;">&lt;&lt;EOF<br />
set xlabel 'Nombre de Sommets du graphe'<br />
set ylabel 'Temps de calcul (s)'<br />
set xrange [*:*]<br />
set yrange [*:*]<br />
set grid<br />
set nokey<br />
set output &quot;${4}&quot;<br />
set terminal png small<br />
plot &quot;plot.dat&quot; with linespoints<br />
EOF</span><br />
<br />
  <span style="color: #666666; font-style: italic;"># Suppression du fichier temporaire</span><br />
  <span style="color: #c20cb9; font-weight: bold;">rm</span> <span style="color: #660033;">-f</span> plot.dat<br />
<span style="color: #7a0874; font-weight: bold;">&#125;</span><br />
<br />
_bench_run<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span><br />
  <span style="color: #007800;">j</span>=<span style="color: #ff0000;">&quot;0&quot;</span><br />
  <span style="color: #000000; font-weight: bold;">while</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #007800;">$j</span> <span style="color: #660033;">-lt</span> <span style="color: #007800;">$ITER</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">do</span><br />
    ..<span style="color: #000000; font-weight: bold;">/</span><span style="color: #7a0874; font-weight: bold;">source</span><span style="color: #000000; font-weight: bold;">/</span>coloration <span style="color: #660033;">-r</span> <span style="color: #007800;">$i</span> <span style="color: #660033;">-v</span> <span style="color: #000000;">1</span><span style="color: #000000; font-weight: bold;">&gt;&gt;</span>coloration.log <span style="color: #000000;">2</span><span style="color: #000000; font-weight: bold;">&gt;&gt;</span> error.log<br />
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;&quot;</span><span style="color: #000000; font-weight: bold;">&gt;&gt;</span>coloration.log<br />
    <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;&quot;</span><span style="color: #000000; font-weight: bold;">&gt;&gt;</span>error.log<br />
    <span style="color: #007800;">j</span>=$<span style="color: #7a0874; font-weight: bold;">&#91;</span>j + <span style="color: #000000;">1</span><span style="color: #7a0874; font-weight: bold;">&#93;</span><br />
  <span style="color: #000000; font-weight: bold;">done</span><br />
<span style="color: #7a0874; font-weight: bold;">&#125;</span><br />
<br />
_bench<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span><br />
  <span style="color: #7a0874; font-weight: bold;">local</span> <span style="color: #007800;">ACTION</span>=<span style="color: #ff0000;">&quot;$1&quot;</span><br />
  <span style="color: #7a0874; font-weight: bold;">shift</span><br />
  <span style="color: #000000; font-weight: bold;">case</span> <span style="color: #007800;">$ACTION</span> <span style="color: #000000; font-weight: bold;">in</span><br />
    d<span style="color: #000000; font-weight: bold;">|</span>disp<span style="color: #7a0874; font-weight: bold;">&#41;</span> _bench_disp <span style="color: #ff0000;">&quot;$@&quot;</span> <span style="color: #000000; font-weight: bold;">;;</span><br />
    p<span style="color: #000000; font-weight: bold;">|</span>plot<span style="color: #7a0874; font-weight: bold;">&#41;</span> _bench_plot <span style="color: #ff0000;">&quot;$@&quot;</span> <span style="color: #000000; font-weight: bold;">;;</span><br />
    h<span style="color: #000000; font-weight: bold;">|</span><span style="color: #7a0874; font-weight: bold;">help</span><span style="color: #000000; font-weight: bold;">|*</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> _bench_usage <span style="color: #000000; font-weight: bold;">&gt;&amp;</span><span style="color: #000000;">2</span> <span style="color: #000000; font-weight: bold;">;;</span><br />
  <span style="color: #000000; font-weight: bold;">esac</span><br />
<span style="color: #7a0874; font-weight: bold;">&#125;</span><br />
<br />
_bench <span style="color: #ff0000;">&quot;$@&quot;</span><br />
<br />
<span style="color: #7a0874; font-weight: bold;">echo</span><br />
<span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span><div style="display:none;">[code=bash]<br />#!/bin/sh<br />if [ "$1" = "-i" ]; then<br />&nbsp; ITER="$2"<br />&nbsp; shift<br />&nbsp; shift<br />else<br />&nbsp; ITER="10"<br />fi<br /><br />_bench_usage() {<br />&nbsp; cat &lt;&lt;USAGE<br />Usage: bench disp n1 n2 interval : Affiche le temps pris pour traiter des graphes de n sommets, n variant de n1 &agrave; n2 par pas de interval.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; bench plot n1 n2 interval file: Cr&eacute;e le fichier file, un graphique PNG affichant le temps pris pour traiter des graphes de n sommets,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; n variant de n1 &agrave; n2 par pas de interval.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; bench help: Affiche cette page d'aide.<br />&nbsp; La premi&egrave;re lettre de chaque commande peut &ecirc;tre utilis&eacute;e<br />&nbsp; Le flag -i permet de sp&eacute;cifier combien de fois un graphe &agrave; n sommets doit &ecirc;tre calcul&eacute;.<br />&nbsp; Valeur par d&eacute;faut : 10<br />USAGE<br />}<br /><br />_bench_disp() {<br />&nbsp; i=$1<br />&nbsp; while [ $i -le $2 ]; do<br />&nbsp;&nbsp;&nbsp; START=$(date +%s)<br />&nbsp;&nbsp;&nbsp; _bench_run<br />&nbsp;&nbsp;&nbsp; STOP=$(date +%s)<br />&nbsp;&nbsp;&nbsp; echo "Graphe &agrave;" $i "sommets :" $[$STOP-$START] "secondes"<br />&nbsp;&nbsp;&nbsp; i=$[i + $3]<br />&nbsp; done<br />}<br /><br />_bench_plot() {<br />&nbsp; # Cr&eacute;ation d'un fichier temporaire contenant les donn&eacute;es &agrave; afficher<br />&nbsp; i=$1<br />&nbsp; echo "# Temps de calcul pour des graphes de "$1" &agrave; "$2" sommets (par pas de "$3")" &gt; plot.dat<br />&nbsp; while [ $i -lt $2 ]; do<br />&nbsp;&nbsp;&nbsp; START=$(date +%s)<br />&nbsp;&nbsp;&nbsp; _bench_run<br />&nbsp;&nbsp;&nbsp; STOP=$(date +%s)<br />&nbsp;&nbsp;&nbsp; echo $i $[$STOP-$START] &gt;&gt; plot.dat<br />&nbsp;&nbsp;&nbsp; i=$[i + $3]<br />&nbsp; done<br /><br />&nbsp; # G&eacute;n&eacute;ration du graphe<br />&nbsp; gnuplot&lt;&lt;EOF<br />set xlabel 'Nombre de Sommets du graphe'<br />set ylabel 'Temps de calcul (s)'<br />set xrange [*:*]<br />set yrange [*:*]<br />set grid<br />set nokey<br />set output "${4}"<br />set terminal png small<br />plot "plot.dat" with linespoints<br />EOF<br /><br />&nbsp; # Suppression du fichier temporaire<br />&nbsp; rm -f plot.dat<br />}<br /><br />_bench_run() {<br />&nbsp; j="0"<br />&nbsp; while [ $j -lt $ITER ]; do<br />&nbsp;&nbsp;&nbsp; ../source/coloration -r $i -v 1&gt;&gt;coloration.log 2&gt;&gt; error.log<br />&nbsp;&nbsp;&nbsp; echo ""&gt;&gt;coloration.log<br />&nbsp;&nbsp;&nbsp; echo ""&gt;&gt;error.log<br />&nbsp;&nbsp;&nbsp; j=$[j + 1]<br />&nbsp; done<br />}<br /><br />_bench() {<br />&nbsp; local ACTION="$1"<br />&nbsp; shift<br />&nbsp; case $ACTION in<br />&nbsp;&nbsp;&nbsp; d|disp) _bench_disp "$@" ;;<br />&nbsp;&nbsp;&nbsp; p|plot) _bench_plot "$@" ;;<br />&nbsp;&nbsp;&nbsp; h|help|*) _bench_usage &gt;&amp;2 ;;<br />&nbsp; esac<br />}<br /><br />_bench "$@"<br /><br />echo<br />exit 0<br />[/code]</div></div><br /><br />C'est facilement modifiable pour faire un <strong>comparatif entre deux programmes</strong>, &agrave; condition de regarder un peu la doc de GnuPlot.<br /><br /><strong>Partager cet article :</strong> <a href="javascript:;" onclick="window.open('http://ek.la/twitter?blog=7&amp;path=un-petit-script-pour-faire-du-benchmark-a513093&amp;title=Un+petit+script+pour+faire+du+Benchmark');" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Diffuser sur Twitter&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/retweet.png" alt="Retweet" class="icon" /></a> <a href="http://www.wikio.fr/vote?url=http%3A%2F%2Fwww.divarvel.fr%2Fun-petit-script-pour-faire-du-benchmark-a513093" onmouseover="if(Help.bubble) Help.bubble(this, &quot;Voter sur wikio&quot;);"><img src="http://www.divarvel.fr//images/bookmarks/wikio.gif" alt="Wikio" class="icon" /></a> <iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.divarvel.fr%2Fun-petit-script-pour-faire-du-benchmark-a513093&amp;layout=button_count&amp;show_faces=false&amp;width=110&amp;action=like&amp;colorscheme=light&amp;height=20" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:110px; height:20px;" class="icon" allowTransparency="true"></iframe><br />]]></content:encoded>
		<pubDate>Mon, 01 Jun 2009 16:38:34 +0200</pubDate>
		<guid isPermaLink="true">http://www.divarvel.fr/un-petit-script-pour-faire-du-benchmark-a513093</guid>
		<dc:creator>divarvel</dc:creator>
		<dc:date>2009-06-01T16:38:34+02:00</dc:date>
	</item>
</channel>
</rss><!--mdp=-->