Quickly compile PHP under Linux

Here’s the command line I use for compiling PHP under my system :

./configure --prefix=/opt/php5 --with-mysql=/usr/bin/mysql_config --with-mysqli=/usr/bin/mysql_config --enable-sockets --with-libdir=lib64 --with-apxs2=/usr/sbin/apxs --with-pdo-mysql --enable-mbstring --enable-zipmakemake installcp php.ini-development /opt/php5/bin/php.ini

Don’t forget to reload your webserver after that.

Google Chrome from depot in Fedora

Here’s the depot for Google Chrome (useful if you want it to be updated automatically) :

For 32bits

[google-chrome]name=google-chrome - 32-bitbaseurl=http://dl.google.com/linux/chrome/rpm/stable/i386enabled=1gpgcheck=1gpgkey=https://dl-ssl.google.com/linux/linux_signing_key.pub

For 32bits

[google-chrome]name=google-chrome - 64-bitbaseurl=http://dl.google.com/linux/chrome/rpm/stable/x86_64enabled=1gpgcheck=1gpgkey=https://dl-ssl.google.com/linux/linux_signing_key.pub

Thanks goes for if-not-true-then-false.com

Eclipse as Gnome 3 desktop properties

Here’s a quick post for having Eclipse in the Gnome 3 activities panel.

Just create a .desktop file in /usr/share/applications/eclipse.desktop and put this in it :

[Desktop Entry]Type=ApplicationVersion=4.2Name=EclipseGenericName=Integrated Development EnvironmentGenericName[fr]=Environnement de Développement IntégréComment=A powerful IDEComment[fr]=Un EDI puissantExec={path-to-eclipse}eclipseIcon={path-to-eclipse}icon.xpmTerminal=falseCategories=GTK;Development;IDE;MimeType=text/plain;text/x-chdr;text/x-csrc;text/x-c++hdr;text/x-c++src;text/x-java;text/x-dsrc;text/x-pascal;text/x-perl;text/x-python;application/x-php;application/x-httpd-php3;application/x-httpd-php4;application/x-httpd-php5;application/xml;text/html;text/css;text/x-sql;text/x-diff;StartupNotify=trueX-Desktop-File-Install-Version=0.19

Play! Framework launch script with Plumbr integrated

Hey folks!

I discovered this new project, Plumbr, that helps you track your memory leaks.

The project seems great and very useful, so I decided to give it a try.

And since I’m using Play! Framework mainly for my java project, I wanted a way to simply launch Play! with Plumbr.

At first, Play! is very easy to integrate java options, just take a look at that run command : (supposing your play env is in /opt/play/{version}/ and plubmr at /opt/plubmr/beta/

/opt/play/1.2.4/play run /path/to/play/app/ -agentpath:/opt/plumbr/beta/linux/64/libplumbr.so -javaagent:/opt/plumbr/beta/plumbr.jar -noverify

So I did a little shell script that will perform this command for a better simplicity, here it is :

 

#!/bin/bash## Shell script (BASH) used to launch a PLAY! Framework project with Plumbr
#
# For more information, go to :
# http://www.playframework.org/
# http://www.plumbr.eu/
#
# Installation# Customize the script according to your need. You need to setup :
# - The path to PLAY! Framework service
# - The path to Plumbr
# --------------------------------------------------------------------
# This is a free shell script under GNU GPL version 3.0 or above
# Copyright (C) 2005 ReFlectiv project.
# Feedback/comment/suggestions : http://www.reflectiv.net
# -------------------------------------------------------------------------

PLAY="/opt/play/1.2.4/play"PLUMBR_PATH="/opt/plumbr/"
# -------------------------------------------------------------------------
# Now, don't touch anything, it's for your safety! :)
# -------------------------------------------------------------------------

if [ $1 ==  "" ]; then
        $1 = "."
fi

ARCH_BIT="32"
if [ `uname -m` == "x86_64" ]; then
        ARCH_BIT="64"
fi

ARCH_OS="linux"
if [ `uname -s` == "Darwin" ]; then
        ARCH_OS="mac"
fi

$PLAY run $1 -agentpath:$PLUMBR_PATH/$ARCH_OS/$ARCH_BIT/libplumbr.so -javaagent:$PLUMBR_PATH/plumbr.jar -noverify

Hope this helps!

If you find bugs, don’t hesitate to comment them, I’ll fix it!

Git Quick Start

This post is just a quick reminder on how to start and use git for your project.

First of all, server side (via a private repository) :

cd /path/to/your/git/repositories/mkdir my_project.gitcd my_project.gitgit --bare init

Then, on your computer, do that :

# create your project (we suppose it will be at /home/user/projects/my_project)cd /home/user/projects/my_projectgit initgit add .git commit -a -m "First commit"git remote add origin ssh://user@server.com/path/to/your/git/repositories/my_project.gitgit push origin master

Extra bonus, for Play! Frameworks fans, here’s a nice gitignore file to create :

# create a .gitignore file at the root of your project containing those lines :
bin/
data/
dist/
logs/
test-result/
tmp/
modules/
eclipse/
.settings/
*.swp
.classpath
.project

And voilà !

(thanks to Nicolas about that!)

How I organize my project’s todo list

I often find myself regularly having ideas about a new project and it’s easy to get stuck in a infinite loop of

  1. Starting a project
  2. Thinking about an other new one
  3. starting this new project
  4. etc
There is numerous ways to avoid this trap and one of them I usually do is to NOT think too hard about this new shiny project for at least a week.

If this idea keep returning in my head, that mean I should take a closer look.

But taking a closer look doesn’t mean abandoning the project I’m currently working on to start this new one. It means writing down what this idea should do, maybe with a list of functionality it shall have and that’s it!

Then, I organize all those ideas into three distinct categories :
  • Profitable
  • Probably profitable
  • Free / Open source
By doing this, I have a better view on which idea I should start next.

Moreover, having my idea written down help me forget about it, and bring me back to thinking about my current project. And often, when I go back to that list, I remove some ideas that seems useless after a certain time of thinking (or not thinking ;)).

And you, how do you manage your flow of ideas?

A New Blog!

Hey!

(if you don’t want to read the whole speech, just scroll down to the end)

It’s been a long time since we didn’t added a new post on our blog, and for a specific reason : we wanted to move our architecture to a better, robust blog engine (the previous one was made by ourselves, not so good idea!).

So we moved to Posterous!

The transfert wasn’t so easy since we had to move our database structure to make it compatible to WordPress, to export it after for Posterous. Quite a challenge, but we managed to succeed it!

Since we changed our blog provider, there is some things you need to take in consideration :

The blog is now located at http://blog.reflectiv.net instead of http://www.reflectiv.net/blob/. We setted up a permanent redirect from the old blog to the new, but some links aren’t correct (we are working on fixing this).

We found out that we used 2 different Feed burner URLS (PLUS the one from our blog engine, eurk!) : http://feeds.feedburner.com/ReflectivNews and http://feeds.feedburner.com/ReflectivBlog

We changed these to be in one clean FeedBurner url, the one you will have access via our blog. The new url is : http://feeds.feedburner.com/reflectiv. Easy and clean!

So you need to update your bookmarks :

See you soon for some new refreshing post!

Une nouvelle année pleine d’espoirs

Comme tous les ans, j’écris un article sur l’évolution du projet Reflectiv ainsi qu’une petite réflexion personnelle. Cela fait maintenant 3 ans que c’est le cas (2008, 2009, 2010) et c’est un rite que j’aime prendre, qui permet de voir ce qui a été accomplit et ce qu’il reste à faire.

En commençant par un petit compte rendu sur l’année 2010, l’ensemble est mitigé: Nos trois principaux projets (Skual, GSpanel et le framework Catapult) n’ont pas très bien évolué. Skual et GSpanel toujours au stade de projet et le framework n’a pas vraiment été retravaillé depuis sa première sortie. J’ai tenté de le refaire de fond en comble, mais rien d’officiel n’en est sorti. Mais tout n’est pas perdu, j’ai l’idée de base pour un framework performant et complet, reste plus qu’à lier toutes les briques ensembles.

Durant cette année, nous avons aussi mis en place un nouveau projet, pendant la fuite de pétrole géré par BP. Le projet n’a pas duré très longtemps et n’a pas vraiment eu l’intéressement escompté. Tant pis.

De manière générale, le projet Reflectiv à tourné quelque peu au ralenti, principalement dû à mon stage de fin d’étude qui m’a pris beaucoup de temps et de disponibilité.

Mais tout n’est pas noir, notre projet Black-Frames se porte à merveille, avec plus de 800 visiteurs en moyenne et un pic prometteur à 1003 le 23 décembre!

Media_httpblog1reflec_bwtam

Ensuite, le début de cette année s’annonce original puisque je me suis mis officiellement à mon compte, à temps plein. Cela signifie que je vais pouvoir vraiment m’investir dans nos projets. Mais qu’en est-il ?

Tout d’abord, mon fil rouge n’aura pas vraiment de rapport avec Reflectiv, donc je ne vais pas m’étendre ici, mais c’est LE projet sur lequel je travaillerais en priorité.

En parallèle, voici les 4 projets que nous allons tenter de mettre en place durant l’année 2011 :

  • Une refonte de Reflectiv, avec l’externalisation du blog sur un service dédié
  • Un redesign de Black-Frames, entre autres afin d’accueillir vraiment les images des visiteurs
  • Probablement travailler sur Catapult
  • Avec Antoine, on envisage de faire 1 design par semaine, avec HTML/CSS/JS, qui seront publiés sur ThemeForest (au moins au début). Si la vente marche très bien, pourquoi pas ouvrir une boutique à côté

Voilà pour ce premier article de l’année. Ce sera probablement le dernier sur cette plateforme, avant la migration vers la nouvelle version de Reflectiv. Nous n’avons pas encore de date quant à cette évolution, espérons juste que ce soit rapidement :)

Tous nos vœux de réussite pour cette nouvelle année, dans tous les domaines !

6 techniques pour éviter les blocages

Ce coup-ci, c’est le blog de Zurb qui nous donne 6 conseils pour éviter les “barrages routiers” lors de la réalisation de site web, bien qu’à mon avis, ses conseils s’adressent à tout type de projets.

Dans cette liste, nous avons :

  1. Pas de deadline claire
  2. Perfectionnisme
  3. Objectifs de lancement mal définis
  4. Mauvaise gestion de planning projet
  5. Un manque d’ingénieurie
  6. Aucune interface client

En plus, l’article est bien détaillé et agréable à lire ! :)