Skip to content

Instantly share code, notes, and snippets.

View clintecker's full-sized avatar
🎯
Focusing

Clint Ecker clintecker

🎯
Focusing
View GitHub Profile
### Keybase proof
I hereby claim:
* I am clintecker on github.
* I am clintecker (https://keybase.io/clintecker) on keybase.
* I have a public key whose fingerprint is 4714 EA08 28B1 B3B9 5A4A B1AD 92A5 525E 1DC7 A907
To claim this, I am signing this object:
@clintecker
clintecker / gist:3492816
Created August 27, 2012 22:14 — forked from DrPizza/gist:3492807
Bogus VC++ 2012 error?
from threading import Thread
t = Thread()
t.start()
t.join()

Installation

The Exceptional Rails plugin will work alongside any other exception management solution. Though it would be a good idea to remove them if you decide to use Exceptional to ensure the best possible performance.

You will need an account at getexceptional.com

Rails < 2.1
  1. Install : From the root folder of your Rails application, run the following command to download and install it:

cd vendor/plugins &&\

startup_message off
vbell off
defscrollback 1000
screen -t hq
screen -t macaroni 0 ssh macaroni
screen -t mysql 0 ssh mysql
screen -t mysql 0 ssh mysql
screen -t varnish-1 0 ssh varnish-1
screen -t varnish-2 0 ssh varnish-2
# run with: god -c /var/www/mt/tools/pubqueue_god_script.rb -D
require 'tlsmail'
require 'net/smtp'
require 'openssl'
Net::SMTP.enable_tls(OpenSSL::SSL::VERIFY_NONE)
God::Contacts::Email.defaults do |d|
d.from_email = 'tech@arstechnica.com'
d.from_name = 'The Lᴏʀᴅ'
d.delivery_method = :smtp
production:
persist_in_safe_mode: true
hosts:
- - mongo-1
27017
- - mongo-2
27017
- - mongo-3
27017
read_secondary: true
#!/usr/bin/env ruby
require 'twitter'
require 'erb'
def get_file_as_string(filename)
data = ''
f = File.open(filename, "r")
f.each_line { |line| data += line }
data
end
<?
// Boilerplate goes here
$_resource = new Placeholder();
$_resource->entries_etc = new ResourceList(array('/apple/news/2011/05/apple-has-released-security-update.ars', '/science/news/2011/05/-science-is-also-backing.ars', '/software/news/2011/05/skype-has-released-an-updated.ars', '/tech-policy/news/2011/05/facebook-and-google-are-facing.ars', '/web/news/2011/05/google-released-a-new-flight.ars', '/apple/news/2011/05/ea-has-put-most-of.ars', '/science/news/2011/05/-ars-own-jonathan-gitlin.ars', '/microsoft/news/2011/05/microsoft-has-shipped-internet-explorer.ars', '/science/news/2011/05/-nasa-has-given-up.ars', '/tech-policy/news/2011/05/the-phantom-data-lawsuit-against.ars', '/tech-policy/news/2011/05/comcast-wont-adopt-usage-based-billing.ars', '/gadgets/news/2011/05/verizon-wireless-has-announced-that.ars', '/gadgets/news/2011/05/amazon-has-added-an-ad-supported.ars', '/apple/news/2011/05/macworld-has-a-neat-how-to.ars', '/apple/news/2011/05/samsung-has-been-ordered-to.ars', '/apple/news
<?
// Some boilerplate goes here, loading in all our classes and whatnot...
// If this looks hella janky to you, then you'd be justified in thinking so. But it works quite well.
// This file is auto-generated by MovableType, and as such doesn't look amazingly efficient, but that's
// why things sometimes get defined and then redefined immediately.
$_resource = new Entry();
$_resource->related_urls = 'http://www.archive.org/download/gov.uscourts.cand.239768/gov.uscourts.cand.239768.56.0.pdf Motion to Compel Apple to Produce Reciprocal Expedited Discovery';
$_resource->next = false;
<?
$GLOBALS['published_dir'] = getenv('ARS_PUBLISHED_DIR');
if(!$GLOBALS['published_dir']){
$GLOBALS['published_dir'] = '/var/www/published/';
}
$GLOBALS['app_engine_dir'] = getenv('ARS_APP_ENGINE_DIR');
if(!$GLOBALS['app_engine_dir']){
$GLOBALS['app_engine_dir'] = '/var/www/published/app/';