Posty

Wyświetlanie postów z czerwiec, 2012

Native system notifications in rails applications (development mode)

Obraz
Let's just say that from time to time you would like to display a notification on your screen of some event that occurred. As an example let's display a request time. The problem occurs when you work in heterogeneous environment and your friends use either linux or mac. In that case you might be tempted to define Gemfile as:


That is not going to work correctly and will lead to problems. Every time you run bundle install on different platform it will resolve dependencies differently and cause problems for your coworkers that are in the second operating system camp. And in worst scenario you will be hit when last Gemfile.lock is committed from Mac but you try to deploy to linux production server using bundle --deployment which is not allowed to recalculate dependencies. You can recognize it by the message "You have modified your Gemfile in development but did not check the resulting snapshot (Gemfile.lock) into version control".

What we basically want to achive is des…