Skip to content

Instantly share code, notes, and snippets.

View tnightingale's full-sized avatar

Tom Nightingale tnightingale

  • Test Double
  • Vancouver, Canada
View GitHub Profile
/**
* Route processor to handle authentication.
*
* @param checkAuth function () => boolean
* Return value indicates whether or not user is authenticated.
*
* @param logout function () => undefined
* Callback to log user out of system.
*
* @param rotues <Route>
<VirtualHost *:80>
DocumentRoot "/Users/tnightingale/workspace/affinity/ies/ies/web"
ServerName ies.dev
<Directory "/Users/tnightingale/workspace/affinity/ies/ies/web">
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
Allow from all
</Directory>
_getFieldMetadataCb(field) {
let type = field.getSchemaAttribute('type'),
format = field.getSchemaAttribute('format');
// Prepare metadata for geo widgets.
if (type === 'object' && format === 'geojson' && !this.state.basemaps.isEmpty()) {
let orgId = this.getParams().organization,
basemaps = this.state.basemaps.getIn(['basemaps', orgId]);
return Immutable.Map({ basemaps });

Twilio

API only.

Mailchimp Gather.

Built on Twilio. No API. Specifically for event organization/management.

var Immutable = require("immutable"),
Map = Immutable.Map,
is = Immutable.is;
var getValue = function () {
return { foo: 'bar' };
},
getValue2 = function () {
return { foo: 'bar' };
};
var isEqual = require("lodash").isEqual,
Immutable = require("immutable"),
Map = Immutable.Map,
is = Immutable.is;
var getValue = function () {
return { foo: 'bar' };
},
getValue2 = function () {
return { foo: 'bar' };
var isEqual = require("lodash").isEqual;
var Immutable = require("immutable");
var getValue = function () {
return { foo: 'bar' };
},
id = 'record:1',
record = Immutable.Map({
data: getValue()
});
@tnightingale
tnightingale / settings.php
Last active August 29, 2015 14:03
Every dev should have these set in their settings.php.
<?php
// Disable css & js aggregation.
$conf['preprocess_js'] = 0;
$conf['preprocess_css'] = 0;
// Turn on error reporting.
$conf['error_level'] = 2;
// Set mail redirect to email is not set from local
$conf['mail_redirect_domain'] = 'affinitybridge.com';
var auth = username + ':' + password,
uri = url.format({
protocol: 'http',
host: host,
pathname: database,
auth: auth
}),
r = hyperquest(uri);
r.pipe(concat(function (data) {

Keybase proof

I hereby claim:

  • I am tnightingale on github.
  • I am tnightingale (https://keybase.io/tnightingale) on keybase.
  • I have a public key whose fingerprint is 98D1 CDC8 BA58 994A AC1A 3675 52F1 ECAF 3F80 6919

To claim this, I am signing this object: