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
set :application, "appname" | |
set :deploy_to, "/var/www" | |
set :scm, :git | |
set :repository, "git@github.com:user/app.git" | |
default_run_options[:pty] = true | |
set :user, "www-data" | |
set :domain, "foo.tld" | |
set :normalize_asset_timestamps, false |
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
https://en.wikipedia.org/wiki/List_of_kings_of_Sparta | |
http://sparta-dion.herokuapp.com/ |
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
irb(main):003:0> reload!; puts MerchantDirectory::Activity.fully_provisionable.count | |
Reloading... | |
Creating scope :published. Overwriting existing method MerchantDirectory::Activity.published. | |
Creating scope :published. Overwriting existing method MerchantDirectory::Profile.published. | |
(143.1ms) SELECT DISTINCT COUNT(DISTINCT `merchant_directory_activities`.`id`) FROM `merchant_directory_activities` INNER JOIN merchant_directory_variants ON merchant_directory_variants.merchant_activity_id = merchant_directory_activities.id INNER JOIN merchant_directory_availability_rules ON merchant_directory_availability_rules.merchant_variant_id = merchant_directory_variants.id WHERE (merchant_directory_activities.confero_id IS NOT NULL) AND (merchant_directory_variants.advance_product_id is null) AND (merchant_directory_variants.price IS NOT NULL) AND (merchant_directory_variants.duration < 86400) AND (merchant_directory_availability_rules.start_date is not NULL) AND (merchant_directory_availability_rules.end_date is not |
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
irb(main):004:0> reload!; puts MerchantDirectory::Activity.fully_provisionable.count | |
Reloading... | |
(265.5ms) SELECT DISTINCT COUNT(DISTINCT `merchant_directory_activities`.`id`) FROM `merchant_directory_activities` INNER JOIN merchant_directory_variants ON merchant_directory_variants.merchant_activity_id = merchant_directory_activities.id INNER JOIN merchant_directory_availability_rules ON merchant_directory_availability_rules.merchant_variant_id = merchant_directory_variants.id WHERE (merchant_directory_activities.confero_id IS NOT NULL) AND (merchant_directory_variants.price IS NOT NULL) AND (merchant_directory_variants.duration < 86400) AND (merchant_directory_availability_rules.start_date is not NULL) AND (merchant_directory_availability_rules.end_date is not NULL) AND (merchant_directory_availability_rules.valid_days != '[]') AND (merchant_directory_availability_rules.start_time is not null) | |
9655 | |
irb(main):005:0> MerchantDirectory::Variant.where('merchant_directory_variants.duration > 86400').update_ |
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
[2015-11-29 02:46:27 +0000] Starting | |
[2015-11-29 02:46:28 +0000] Error! | |
[2015-11-29 02:46:28 +0000] error message: --- &1 !ruby/object:Faraday::Response | |
on_complete_callbacks: [] | |
env: !ruby/struct:Faraday::Env | |
method: :put | |
body: !ruby/hash:Hashie::Mash | |
error: !ruby/hash:Hashie::Mash | |
booking_rule: false | |
message: |
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
source 'https://rubygems.org' | |
gem 'vcr' | |
gem 'fakeweb' | |
gem 'PageRankr' |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Demo Overherd</title> | |
<script type="text/javascript" src="http://stampede-corporate-2012.tb.nonwebdev.com/javascripts/jquery-1.5.1.min.js"></script> | |
</head> | |
<body> | |
<link href="http://ymssz4ew.frozencdn.net/stylesheets/live.css" rel="stylesheet" type="text/css" media="screen" /> | |
<script type="text/javascript" src="/jquery.overherd.js"></script> | |
<script type="text/javascript"> |
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
class Comment < ActiveRecord::Base | |
default_scope :order => 'created_at DESC' | |
belongs_to :marked_entry | |
belongs_to :user | |
has_many :participants, :through => :marked_entry | |
def self.reply_copy | |
'## Reply above this line in order to comment via email ##' | |
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
jQuery -> | |
getFeeds = -> | |
keywordId = $("#keyword").attr("data-id") | |
$.get("/keywords/#{keywordId}/feeds.html", (data)-> | |
if jQuery.isEmptyObject(data) | |
setTimeout(getFeeds, 5000) | |
else | |
$('#feeds').html(data) | |
) | |
$ -> setTimeout(getFeeds, 1000) |
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
class Widget | |
attr_accessor :circumference | |
attr_accessor :colour | |
attr_accessor :mass | |
def initialize(attributes) | |
attributes.each do |key, value| | |
m = "#{key}=".to_sym | |
self.send(m, value) if self.respond_to?(m) | |
end |
NewerOlder