Requirements:
- lodash (or underscore, you may need to change your _ functions to suit)
- Meteor email package
Meteor.startup(function () {
var sendEmail = _.bind(Email.send, Email);
| # Download and unzip Alexa Top 1 Million websites | |
| # http://s3.amazonaws.com/alexa-static/top-1m.csv.zip | |
| # Run this script. | |
| from os.path import isfile | |
| from urllib.request import urlopen | |
| import concurrent.futures | |
| import socket | |
| import dns.resolver | |
| import time |
| server { | |
| listen 80; | |
| listen [::]:80; | |
| server_name robertnealan.com; | |
| root /var/www/ghost/system/nginx-root; | |
| location / { | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| proxy_set_header X-Forwarded-Proto $scheme; |
| <?xml version="1.0" encoding="utf-8"?> | |
| <resources> | |
| <color name="material_red50">#ffffebee</color> | |
| <color name="material_red100">#ffffcdd2</color> | |
| <color name="material_red200">#ffef9a9a</color> | |
| <color name="material_red300">#ffe57373</color> | |
| <color name="material_red400">#ffef5350</color> | |
| <color name="material_red500">#fff44336</color> | |
| <color name="material_red600">#ffe53935</color> | |
| <color name="material_red700">#ffd32f2f</color> |
This article has been given a more permanent home on my blog. Also, since it was first written, the development of the Promises/A+ specification has made the original emphasis on Promises/A seem somewhat outdated.
Promises are a software abstraction that makes working with asynchronous operations much more pleasant. In the most basic definition, your code will move from continuation-passing style:
getTweetsFor("domenic", function (err, results) {
// the rest of your code goes here.