radar/forem — pull request #347 by sfcgeorge (2012-12-01 16:22:54+00:00)
Title: Fix Gemoji with latest gem

The latest Gemoji gem's recommended usage is to serve the images from Public rather than Assets because the hundreds of images slow down asset precompilation.

This commit updates the gem, and changes the helper to use the public path.

* I have hardcoded the `/images/emoji` bit of the path, I'm not sure if this is the best way or if there is a rails helper to do it. Would the public directory ever move? Would people ever put images in a folder other than images? I've only used the asset pipeline before so I'm not sure if there are any gotchas here to be aware of.
* There is a rake task that needs adding to the app's rakefile and running to copy the images from Gemoji to public/images. See the [Gemoji readme](https://github.com/github/gemoji) for info. It may be worthwhile making the rake task run automatically on Forem install, not sure how that would work. Currently having to edit the `Rakefile` and run a task doesn't seem ideal, but it might not be the end of the world.
* I had to add a require for Gemoji and change the class slightly as Rails wasn't finding it, I'm not sure why, perhaps the gem changed its structure slightly or I'm missing something. What I've done works, I'm just not certain it's the Best Way.