View Gemfile.lock for fontawesome issue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GIT | |
remote: git://github.com/ifad/data-confirm-modal.git | |
revision: 931cab3b269c6dab301245be2b2d738b243ba169 | |
specs: | |
data-confirm-modal (1.0.2) | |
railties (>= 3.0) | |
GEM | |
remote: https://rubygems.org/ | |
specs: |
View gist:ac898e53068979b09231
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Gems included by the bundle: | |
* actionmailer (4.2.3) | |
* actionpack (4.2.3) | |
* actionview (4.2.3) | |
* activejob (4.2.3) | |
* activemodel (4.2.3) | |
* activerecord (4.2.3) | |
* activesupport (4.2.3) | |
* acts-as-taggable-on (3.5.0) | |
* acts_as_commentable (4.0.2) |
View Devise confirmation settings.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# in config/initializers/devise.rb | |
if(ENV["RAILS_ENV"]== "development") | |
config.confirm_within = 15.days | |
else | |
config.confirm_within = 0 | |
end |
View heroku_delayed_job.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## /config/initializers/dynamic_job.rb | |
require 'heroku' | |
# base class for all jobs that you wish to automatically scale and go down in Heroku | |
class DynamicJob | |
#set a cap on maximum number of users ever - just in case. | |
MAX_CONCURRENT_WORKERS = 100 | |
def initialize |
View goldbach.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from sympy import sieve | |
def goldbach(): | |
''' | |
For each even number > 2, | |
it finds a pair of two primes that add up to the number | |
''' | |
even = 4 | |
View links_gmail_and_safari.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
require 'rubygems' | |
require 'gmail' | |
require 'nokogiri' | |
# Script to extract and show links from gmail and safari bookmarks | |
def parse_for_links s | |
results = [] | |
url = /( |^)http:\/\/([^\s]*\.[^\s]*)( |$)/ |