Virée Vélo Santé pour la Fondation pour la santé du Nord de Lanaudière

mardi 21 avril 2015, catégorisé sous Vélo

Cette année, je participe à l’activité de financement la « Virée Vélo Santé » organisée par la Fondation pour la Santé du Nord de Lanaudière.

Cette sortie vélo de 160 km servira à financer le réaménagement et les équipements de la clinique externe de gynécologie-obstétrique du CHRDL, où ma conjointe pratique depuis 2006.

Je sollicite des dons pour une bonne cause : augmenter l’efficacité et la qualité des soins et ainsi améliorer la santé des femmes!

Soundcloud Stuck on repeat 2014

jeudi 08 janvier 2015, catégorisé sous Musique

Ce que j’ai écouté à plusieurs reprises sur les serveurs de Soundcloud en 2014.

Create a new mail stationary in Apple Mail

vendredi 19 décembre 2014, catégorisé sous Mac OS X
Tags: ,

Steps to create a new stationery with custom HTML and images in Apple Mail (tested on Mavericks)

  1. Create new message in Mail (File > New message)
  2. Add images you need in message
  3. Save as stationery (File > Save as stationery)
  4. With the finder, browse :
    ~/Library/Containers/ Support/Mail/Stationery/Apple/Contents/Resources/Custom/Contents/
  5. Locate your stationery package (file.mailstationery)
  6. Right-click on it, show package content
  7. Browse the .mailstationery to Contents/Resources/
  8. Edit content.html

Apple mail HTML attributes :


Tag content can be edited


main content tag, where the signature will be added by Mail

Hints :

  • To avoid phone numbers or dates in blue, you can style them with css : <span style= »color:#000; »>from December 20th till January 4th 2014</span>
  • You can also add html tags in the numbers/dates (000-<span>555</span>-12345), but they won’t be clickable anymore.

Soundcloud 2013 Stuck on repeat (mon top 40)

mercredi 08 janvier 2014, catégorisé sous Musique

Ce que j’ai écouté à répétition sur les serveurs de Soundcloud en 2013 :

From Snow Leopard (10.6) to Mavericks (10.9) – Clean install

mercredi 20 novembre 2013, catégorisé sous Mac OS X
Tags: ,

Since my iMac had had a lot of OS updates, I’d decided to clean install Mavericks on my new iMac (i5). Without using Migration Assistant, the manual data migration was a bit of a pain, especially Mail and Address Book.

Here is the log :

Installing OSX 10.9 Mavericks (It’s free!)


Installing OSX 10.9 Command Line Tools

Installing Apache2

Copy virtual hosts
Copy /etc/hosts
Apache started, no websites work

  • Change NameVirtualHost IP
  • LogLevel debug

Test the config

  • $ apachectl -S
  • $ sudo apachectl -t
  • $ sudo apachectl configtest

Everything seems OK, bug Console shows:

  • 2013-11-07 13:16:58,354[1]: (org.apache.httpd[5829]) Exited with code: 1

Move all vhosts outside config, apache restart:

  • OK
  • Found an error (error in log path) inside a vhost.

Add « staff » group on apache user « _www »

  • $ sudo dseditgroup -o edit -a _www -t user staff

Testing a Symfony 2 project

$ cd site/
$ rm -rf app/cache/*
$ rm -rf app/logs/*
$ sudo chmod +a « _www allow delete,write,append,file_inherit,directory_inherit » app/cache app/logs
$ sudo chmod +a « `whoami` allow delete,write,append,file_inherit,directory_inherit » app/cache app/logs

Fatal error: Maximum function nesting level of ‘100’ reached, aborting! in /Library/WebServer/SGL/Temps/site/vendor/twig/twig/lib/Twig/Node/Expression/Array.php on line 31

  • $ sudo nano /usr/local/php5/php.d/50-extension-xdebug.ini
    xdebug.max_nesting_level = 1000

Testing a Symfony 1.4 project

Using LIIP PHP 5.5.5, I first got apache segfaults, error_log : [notice] child pid 1432 exit signal Segmentation fault (11).
Looking at the Console, the crash reports showed apcu extension (APC) was crashing.
I had to disable it in /usr/local/php5/php.d/50-extension-apcu.ini
Follow the issue on Github


Could not send email through PHP. Let’s use my ISP SMTP :
$ sudo nano /etc/postfix/

  • relayhost =

Creating/coping original bash profile

$ touch ~/.bash_profile
$ nano ~/.bash_profile

Installing PHP : LIIP OSX PHP


$ nano ~/.bash_profile

  • PATH=/usr/local/php5/bin:$PATH
    export PATH

Library directory hidden

$ chflags nohidden ~/Library/

Installing MySQL 5.6.14

Download from DMG x86, 64-bit
Server version: 5.6.14

$ nano ~/.bash_profile

  • alias mysql /usr/local/mysql/bin/mysql
  • alias mysqladmin /usr/local/mysql/bin/mysqladmin

$ mysqladmin -u root password ‘my-password’


Delete blank user
$ mysql -u root -p

  • use mysql;
  • delete from user where User= »;

$ mysqladmin -u root -p reload

Databases migration

$ sudo /usr/local/mysql/bin/mysqldump --user=root -p --all-database --add-drop-database --skip-comments > all_db.sql
$ sudo /usr/local/mysql/bin/mysqldump --user=root -p --all-databases --add-drop-database --skip-comments > all_db.sql

$ ./mysql < all_db.sql

ERROR 2013 (HY000): Lost connection to MySQL server at ‘sending authentication information’, system error: 32

$ /usr/local/mysql/support-files mysql.server stop

$ sudo cp my-default.cnf /etc/my.cnf

  • bind-address =

$ sudo nano /usr/local/mysql/data/i5Mac.local.err

  • but the required system tables mysql.innodb_table_stats and mysql.innodb_index_stats are not present or have unexpected structure
  • InnoDB: Error: Table « mysql ». »innodb_table_stats » not found

[Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use –explicit_defaults_for_timestamp server option (see documentation for more details).
[ERROR] Can’t open the mysql.plugin table. Please run mysql_upgrade to create it.

Let’s start again…
$ sudo rm -rf mysql data/*
$ sudo ./scripts/mysql_install_db
$ sudo chown -R _mysql:wheel data
$ ./bin/mysqladmin -u root password ‘new password’
$ cd mysql-test
$ perl

Remove ‘mysql’ database from sql-dump to not overwrite Mysql 5.6 « mysql » database.
All databases/tables privileges will have to be granted again.

  • $ sudo /usr/local/mysql/bin/mysql -p < ~/Documents/all_db.sql ### dump without ‘mysql’ table
  • $ sudo /usr/local/mysql/bin/mysql_upgrade -u root -p


$ sudo ln -s /usr/local/mysql/bin/mysql /usr/local/bin/mysql

Copy /Library/WebServer (my http server root)

Connect to old iMac wirelessly

$ cd /Volumes/Macintosh\ HD-1/Library/WebServer
$ sudo cp -p -R some-project /Library/WebServer/some-project

Copy all shell scripts ~/Scripts

Copy iPhoto Library

Copy only ~/Images/iPhoto Library
open iPhoto while holding  <option> key : Choose new library > Convert library

Copy iTunes Library


Copy ~/Music/iTunes
Copy /Users/Shared/Music/iTunes

Copy Documents/

Copy Desktop/

Copy Videos/

Copy Downloads/

Copy Library/Mail

  • $ sudo cp -R * ~/Library/Mail/

Copy Library/Preferences/


  • Mise à niveau des mailbox…
  • Mailbox empty, nothing imported

Close Mail
Move ~/Library/Mail/* > ~/Desktop
Open Mail again
Create new email account
Import all copied mailbox on the Desktop

  • File > Import mailbox

Will have to re-create all email accounts :(

Signatures : now it uses .mailsignature, was .webarchive

  • Open original webarchives files in Safari, copy paste content in a newly created signature

Address book

Had an original bug since I synced my contacts iMac > iPhone, hadn’t had time to fix it: lots of duplicate contacts.

Start again:
Get my original Address Book cleaned
Delete all contacts from (
In Address Book: selected all contacts > Export >  vcards
Browse / import vcards export file
Will have to re-create groups again :(

Import Fonts


Install Evernote

Install BBEdit

Install phpStorm

  • Install Java SE 6 Engine
  • Copy ~/Library/Preferences/WebIde70/*

Install Adium

Install Sequel Pro

  • Import preferences :
    Create one favorite (to activate Import… menu)
    Import favorites (using the « Gear » menu just below the favorites list), you can now select your old .plist file, and it’ll import your favorites from there, adding them to your current list.


Install Git

Install wkhtmltopdf

    Download wkhtmltopdf-0.9.9-OS-X.i368 (latest are buggy)
    $ sudo ln -s /Applications/Utilities/ /usr/local/bin/wkhtmltopdf

Install subversion (well no.)

  • OSX 10.9 native
    See Command Line Tools


  • copy ~/Download/bt
  • Application Support
  • Preferences


  • Application Support
  • Preferences

Photobooth photos

  • Copy original photos to Photo Booth Library > show package contents > Pictures
  • Copy original Recents.plist from ~/Library/Application Support/Photo Booth/Recents.plist to ~/Pictures/Photo Booth Library (show package contents)