This shows the locations that have > 200k people within 20min.
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
# Change YOUR_TOKEN to your prerender token and uncomment that line if you want to cache urls and view crawl stats | |
# Change example.com (server_name and in the rewrite rule) to your website url | |
# Change /path/to/your/root to the correct value | |
server { | |
listen 80; | |
server_name example.com; | |
root /path/to/your/root; | |
index index.html; |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 apt-get install vim | |
sudo apt-get install git-core | |
sudo apt-get -y install nodejs | |
update-alternatives --set editor /usr/bin/vim.tiny |
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 Foo | |
def bar | |
22 | |
end | |
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
CREATE OR REPLACE FUNCTION bulk_rename_column(old_name text, new_name text) RETURNS SETOF text AS $$ | |
DECLARE | |
r RECORD; | |
BEGIN | |
FOR r IN SELECT table_schema, table_name, column_name | |
FROM information_schema.columns As c | |
WHERE c.table_schema NOT IN('information_schema', 'pg_catalog') | |
AND c.column_name = old_name | |
ORDER BY c.table_schema, c.table_name, c.column_name | |
LOOP |
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
__lunchy() { | |
COMPREPLY=() | |
local current=${COMP_WORDS[COMP_CWORD]} | |
if [[ $COMP_CWORD == 1 ]] | |
then | |
COMPREPLY=(start stop restart ls list status install show edit) | |
else | |
COMPREPLY=($(compgen -W '$(lunchy list)' -- $current)) | |
fi | |
} |
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
# usage: | |
# it "should return a result of 5" do | |
# eventually { long_running_thing.result.should eq(5) } | |
# end | |
module AsyncHelper | |
def eventually(:options = {}) | |
timeout = options[:timeout] || 2 | |
interval = options[:interval] || 0.1 | |
time_limit = Time.now + timeout | |
loop do |
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 coffee | |
crypto = require 'crypto' | |
url = require 'url' | |
http = require 'http' | |
stream = require 'stream' | |
util = require 'util' | |
argv = require('optimist') | |
.usage('Usage $0') | |
.default('p', 80) |