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/env ruby | |
require "fileutils" | |
indir, outdir = ARGV | |
unless indir && !indir.empty? && outdir && !outdir.empty? | |
puts "Usage: glyphish-convert.rb <indir> <outdir>" | |
exit | |
end |
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
# This task can be used reindex Solr without dropping your index first. | |
# This is ideal for production environments where a live, working index is critical. | |
# | |
# Put this in lib/tasks/sunspot_tasks.rake | |
namespace :sunspot do | |
task reindex_gracefully: :environment do | |
Dir.glob(Rails.root.join('app/models/**/*.rb')).each { |path| require path } | |
sunspot_models = Sunspot.searchable |
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
# This will move all images and other Dragonfly assets from your local server file system to Amazon S3. | |
namespace :dragonfly do | |
task :migrate_to_s3 => :environment do | |
# Adjust this line to meet your needs: | |
{ Product => [:image_uid, :other_uid], Page => :image_uid }.each do |klass, col| | |
puts "Migrating #{klass.table_name}..." | |
Array(col).each do |col| | |
klass.where("#{col} != ''").find_each do |instance| | |
begin |
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
// Objective-C | |
- (NSMutableArray *)products { | |
if (_products == nil) { | |
_products = [[NSMutableArray alloc] init]; | |
} | |
return _products; | |
} |
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
/Users/lassebunk/.rvm/gems/ruby-2.0.0-p0/gems/ethon-0.6.1/lib/ethon/multi/operations.rb:171: [BUG] Segmentation fault | |
ruby 2.0.0p0 (2013-02-24 revision 39474) [x86_64-darwin13.0.0] | |
-- Crash Report log information -------------------------------------------- | |
See Crash Report log file under the one of following: | |
* ~/Library/Logs/CrashReporter | |
* /Library/Logs/CrashReporter | |
* ~/Library/Logs/DiagnosticReports | |
* /Library/Logs/DiagnosticReports | |
the more detail of. |
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
➜ ~ sudo rvm install 1.9.2 | |
Password: | |
Fetching yaml-0.1.4.tar.gz to /Users/lassebunk/.rvm/archives | |
Extracting yaml-0.1.4.tar.gz to /Users/lassebunk/.rvm/src | |
Configuring yaml in /Users/lassebunk/.rvm/src/yaml-0.1.4. | |
Compiling yaml in /Users/lassebunk/.rvm/src/yaml-0.1.4. | |
Installing yaml to /Users/lassebunk/.rvm/usr | |
gcc-4.2: error trying to exec '/usr/bin/i686-apple-darwin11-gcc-4.2.1': execvp: No such file or directory | |
Installing Ruby from source to: /Users/lassebunk/.rvm/rubies/ruby-1.9.2-p318, this may take a while depending on your cpu(s)... |
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
Invalid gemspec in [/Library/Ruby/Gems/1.8/specifications/authlogic-3.1.0.gemspec]: invalid date format in specification: "2011-10-19 00:00:00.000000000Z" | |
Invalid gemspec in [/Library/Ruby/Gems/1.8/specifications/coffee-rails-3.1.0.gemspec]: invalid date format in specification: "2011-08-31 00:00:00.000000000Z" | |
Invalid gemspec in [/Library/Ruby/Gems/1.8/specifications/execjs-1.2.4.gemspec]: invalid date format in specification: "2011-08-03 00:00:00.000000000Z" | |
Invalid gemspec in [/Library/Ruby/Gems/1.8/specifications/jquery-rails-1.0.19.gemspec]: invalid date format in specification: "2011-11-26 00:00:00.000000000Z" | |
Invalid gemspec in [/Library/Ruby/Gems/1.8/specifications/jquery-rails-2.0.1.gemspec]: invalid date format in specification: "2012-02-28 00:00:00.000000000Z" | |
Invalid gemspec in [/Library/Ruby/Gems/1.8/specifications/json-1.5.4.gemspec]: invalid date format in specification: "2011-08-31 00:00:00.000000000Z" | |
Invalid gemspec in [/Library/Ruby/Gems/1.8/specifications/libv8-3.3.10.4-x86_64-darwin-11.ge |