Uncategorized Archive

Speed up PHP linting with xargs

Most of us use Jenkins to continuously integrate our projects with every commit to the repository, but when it comes with PHP most of the time is spent “linting“.

This action is badly slow and if your project has a lot of files this will take a good percentage of your build time. A really good approach could be executing this task with different files in parallel. For this you can use the powerful xargs command with -P0, which allows xargs to run as many processes as possible at a time.

find codefolder/ -name "*.php" -print0 | xargs -0 -n1 -P0 php -l

So the final snippet for your Ant based project will be:

<target name="lint">
  <exec executable="sh" failonerror="true">
      <arg value="-c" />
      <arg value="find ${project.paths.php.space-separated} -name *.php -print0 | xargs -0 -n1 -P0 php -l"/>
  </exec>
</target>

Setting up Hubot with a gTalk account for fun

This article should be called like something like “Be happy: put a robot in your life”, deep down in order to represent better what I will explain here I’ve changed the title to a more technical point of view.

Since I’ve started to work in Openhost I always thought that for creating a good product our developers (and me between them) should have a great atmosphere, in order to do that I would rather have a pleasant workflow than a strict one. So I’m a firmly believer of Gamification of work. We  were using Jenkins for doing Continuous integration and quickly integrated the Jenkins Continuous Integration Game, a tool which allowed us to create contests for improving our code base without even thinking about it, just thinking on getting a high rate in the contests. But, this is something to another post.

As we are continuously telecommuting, we use groupware chats as our main way of communication. This week I came across to something called Hubot, it’s some sort of chat bot with incredible scriptable capabilities. In a brief description, it is a program that can connect to your groupware chat and it can accept orders, run them in the server and get some response to them in return.

GNOME Launch Party en Galiza, España


O pasado xoves 28 de abril foi un día maravilloso para toda a comunidade GNOME de Galicia. Xa que celebramos a Festa de Lanzamento de GNOME 3. O evento foi organizado maxistralmente pola asociación Ghandalf en colaboración coas asociaciónsGpulTrasno, e co apoio económico da Xunta de Galiza.

As nosas espectatívas de asistencia vironse sobrepasadas. Fomos perto de 50 persoas desfrutando da festa, todos moi ilusionados xa que tanto desenvolvedores que alí estaban presentes, moitos deles da empresa Igalia, como tradutores do GNOME ao galego traballamos moi duramente nos últimos meses para poder ter un GNOME 3 resplandecente.

Unha mistura dun evento totalmente planificado coa expontaneidade xeral dunha festa, o trascurso da mesma foi ameno e moi bó. Todo estaba no seu lugar namentres os poñentes e os asistentes dialogaban segundo avanzaba. Foi unha alegría ver de novo xa grandes amigos meus do Software Libre, e non me cansei de darlles as grazas pola súa asistencia xa que coido que para todos era un momento especial logo do inmenso traballo que levou chegar a onde chegamos.

Group photo of GUADEC-ES

Feelings at Guadec-ES 7 (A Coruña)

Last  Thursday and Friday I was in Coruña attending to the GUADEC-ES, the most important event of GNOME and “hispanic version” of GNOME Users and Developers Conference.
It was my first event focused in GNOME and was simply amazing. I met a lot of GNOME Hackers and get the feeling that I’m in a collaborate with great community.

I enjoy all the talks but I have to highlight some of them.

  • Git it done! by Mario Sánchez. I use git for more than 2 years but Mario gave us a glorifious crash course about it. You can find the slides [ES] in the next link: http://tinyurl.com/2wzqy6d
  • Other of the talks that I prefer is “GNOME 3 para desarrolladores” (GNOME 3 for developers). Carlos Garcia Campos explain us the main differences between last GNOME libraries and what was done to achieve GNOME 3. Clean up !!
  • The great discovery talk was “Vala, un lenguaje para Gnome 3.0” by Roberto Majadas. I heared just a little about Vala but Roberto with a lot of examples explain us the posibilities that Vala has to develop with a high-level language but with the benefits of optimization and speed of C language.
  • And finally  “cómo estudiar y participar en software libre sin morir en el intento” (How to study and participate in Free Software without die trying). Diego Escalante, developer of Epiphany, IMHO is the best speaker I have the pleasure to attend. The talk had a funny tone mixed with real experiences. Again you can find the slides here: http://people.gnome.org/~diegoe/slides/20100723_Coru%25C3%25B1a_Estudiar-y-participar.pdf

GPUL, coorganizers of this GUADEC, promised to make accesible all the videos recorded there. When this happen I’ll update this post to link them.

Conclusion: I recommend all to go this type of conferences cause you can learn a lot in just some hours and you’ll meet a lot of amazing people.

rect3644

3 ways of get memcached status

If you use memcached to cache contents among different servers and apps, and you want to get statistics for what is happening inside the memcached-sever you can use one of the available interfaces for programming languages but there are simpler ways to do that. The best way is use the command line because the simple protocol that memcached has.

Page 1 of 13