This file contains hidden or 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
#include <stdio.h> | |
#define RESET 0 | |
#define BRIGHT 1 | |
#define DIM 2 | |
#define UNDERLINE 3 | |
#define BLINK 4 | |
#define REVERSE 7 | |
#define HIDDEN 8 |
This file contains hidden or 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 node | |
// Before running install | |
// -- npm install -g optimist oauth step colors express | |
var serverPort = 8008; | |
var argv = require('optimist') | |
.usage('Usage: --key=[consumer key] -secret=[consumer secret]') | |
.demand(['key', 'secret']) |
This file contains hidden or 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 node | |
var OAuth = require('oauth').OAuth; | |
var colors = require('colors'); | |
var access_token = null; | |
var access_token_secret = null; | |
var key = null; | |
var secret = null; |
This file contains hidden or 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 PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html> | |
<meta http-equiv="content-type" content="text/html; charset=utf-8" /> | |
<head> | |
<title>Google Earth - Get LatLng</title> | |
<script src="http://www.google.com/jsapi?key=APIKEY"></script> | |
<script> | |
google.load("earth", "1"); | |
var ge = null; |
This file contains hidden or 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
<html> | |
<head> | |
<style> | |
#map{ | |
background-color: red; | |
height:100%; | |
width: 100%; | |
} | |
</style> |
This file contains hidden or 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
<html> | |
<head> | |
<script src="http://code.jquery.com/jquery-2.0.1.min.js"></script> | |
</head> | |
<body> | |
<script src="http://www.stevenjamesgray.com:9090/socket.io/socket.io.js"></script> | |
<script> |
This file contains hidden or 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
<script> | |
var mapOptions = { | |
center: new google.maps.LatLng(51.5, -0.11), | |
zoom: 10, | |
mapTypeId: google.maps.MapTypeId.TERRAIN | |
} | |
var getTweets; | |
$(function() { |
This file contains hidden or 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
NSString* const api_forecast_layers_cap = @"http://datapoint.metoffice.gov.uk/public/data/layer/wxfcs/all/json/capabilities?key=%@"; | |
NSString* const api_obs_layers_cap = @"http://datapoint.metoffice.gov.uk/public/data/layer/wxobs/all/json/capabilities?key=%@"; |
This file contains hidden or 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
var imagesnap = require('imagesnap'); | |
var fs = require('fs'); | |
function grabImage(){ | |
var imageStream = fs.createWriteStream('capture.jpg'); | |
imagesnap().pipe(imageStream); | |
} | |
setInterval(function(){ | |
grabImage(); |
This file contains hidden or 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
""" | |
Pull Greater London Authority boundary definition (geojson) and derive the outer bounding box | |
""" | |
from operator import itemgetter | |
import json | |
import requests | |
r = requests.get('http://mapit.mysociety.org/area/2247.geojson') | |
coords = r.json()['coordinates'][0] |
OlderNewer