Merge pull request #17 from simeonwillbanks/refactor

Refactoring
Every tag should have a slug
Fixes #18

 * Alter tags table to ensure name and slug can not be NULL
 * Validate presence of tag name and slug
 * Overload FriendlyId::Slugged#normalize_friendly_id to ensure a slug is set
 * If a generated slug is empty, use FriendlyId sequence separator as a default
Merge pull request #19 from simeonwillbanks/generate-slugs-for-all-tags

Every tag should have a slug
Gist links open a new window, so returning to My Gists does not require the back button
Alert users when gists are being fetched
Fixes #20

 * Add unicorn gem
 * Add foreman gem
 * Add a Profile with web process which uses unicorn
 * Add unicorn config
 * Force all logging through STDOUT for unicorn
 * Remove ProfileController before_filter which fetchs gists
 * Add route for TagsController#index
 * Implement TagsController#index to list the signed in users tags
   * Only respond to JavaScript requests
   * Before the index action, refresh the signed in users gists
  TagsController#index does not render the layout
 * When rendering ProfileController#show, only render a info alert telling the user their gists are being fetched from GitHub
 * When ProfileController#show DOM fully loaded, get the signed in users tags from TagsController#index and inject the tags into the DOM
   * Add ajax spinner to visually indicate gists are still being fetched
 * Add ProfileController CoffeeScript file
 * Add spec for profile fetching notice
 * Add poltergeist gem and downgrade capybara for poltergeist
 * In spec helper, set poltergeist as Capybara javascript driver
 * Remove before each from auth github spec
 * Remove ProfileController spec which tests for list of tags
 * Add spec feature to test JavaScript loading of tags
 * Upgrading rails to 3.2.10
 * Link profile username back to profile
Merge pull request #21 from simeonwillbanks/alert-users-gists-are-being-fetched

Alert users when gists are being fetched
Add Google Analytics and New Relic Monitoring

 * Add google-analytics-rails gem
 * Set GA.tracker from environment variable in production environment
 * Render GA tracking code in head of all pages via application layout. Move app JavaScripts to the end of the page.
 * Add new_relic gem
 * Add downloaded newrelic.yml
 * Update newrelic.yml from heroku example
Merge pull request #22 from simeonwillbanks/analytics-and-monitoring

Add Google Analytics and New Relic Monitoring
Update humans.txt with My Gists info
Update robots.txt to allow bots to see homepage, but disallow authentication paths
Add Help Tooltip and Refactor AJAX Loading Indicators

 * Add Bootstrap Tooltip to profile tags header
  * Tooltip contains #hashtag help text
  * Style tooltip text
  * Increase tooltip font size
 * Move application.js to a coffeescript file
 * Refactor AJAX fetching indicator to be less obtrusive
 * Refactor showing gist fetching message to be less obtrusive
 * On README, add thank you message to early adopters and link to contributors
 * In OmniauthCallbacksController#github, set flash to indicate redirect was from OmniAuth callback
 * Add ApplicationHelper#render_fetching_info? to inspect flash and look for from omniauth callback key
 * Rewrite fetching messages to be more descriptive
Merge pull request #23 from simeonwillbanks/add-help-tooltip-and-refactor-ajax-loading-indicators

Add help tooltip and refactor ajax loading indicators
Remove Rails.application.config.secret_token from version control, and use an environment variable to set it
Update application.example.yml with examples of all environment variables required by MyGists
Secure OAuth Token
Fixes #24

 * In Production, force ssl
 * Add MyGists::Secure with .encrypt and .decrypt class methods
   * Encoded token should be utf8 for PostgreSQL
 * Add profiles.token to persist OAuth token from GitHub
 * After authenticating with GitHub, save the passed back token
 * Only set GitHub avatar into users session
 * Overload Profile#token to respond with decrypted token
 * Remove ProfileDecorator#token, so Profile model can respond to the message
Make sure to save profile on each OmniAuth callback
Always save users profile
Merge pull request #25 from simeonwillbanks/secure-token

Secure OAuth Token
Refactor and reorganize
Follow GitHub Styleguide

 * Reorganize SCSS files into appropriate directories
 * Use ids for elements which exist a single time
 * Move CoffeeScript files into appropriate directories
 * Add MyGists::GithubSession.set_auth to extract logic from Warden initializer into a testable class
 * In case the user has no gists, kindly encourage them to create and tag some gists
 * Add Github model as a data container for GitHub urls
 * Expose Github model to views via ApplicationHelper.github
 * Refactor user tags AJAX loading by extracting logic into a namespaced JavaScript object
 * Add konacha, sinon-rails and sinon-chai-rails gems for JavaScript specs
 * Add sinon fake servers to mock AJAX responses
 * Add spec helper for JavaScript specs
 * Add specs for MyGists.Fetch.tags success and failure paths
 * Use def self.method to define singleton methods. This makes the methods more resistant to refactoring changes.
 * Leave one blank line above protected and private
 * Use spaces around { and before }
 * Break up a method into logical paragraphs
 * Refactor ProfileDecorator#gists by replacing method chaining with the scope Gist.find_page_by_tag_name_and_profile
 * Use spaces around the = operator when assigning default values to method parameters
 * Prefer %w to the literal array syntax when you need an array of strings
 * Use symbols instead of strings as hash keys
 * Prefer double-quoted strings
Merge pull request #26 from simeonwillbanks/github-styleguide

Refactor and reorganize