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
# Setup Script for BENVGSC4 Database Virtual Machine | |
# -- CENTOS VM Setup | |
# -- Machine Specs | |
# -- Author: Steven Gray, Jan 2015 | |
# -- Version: 1.0 | |
# Do not run this file -- this will not install all features, manually install these | |
# Setup System | |
yum -y install htop |
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
# Process PixelStick Images in a folder | |
find "$@" -name "*.jpg" | while read file; do | |
echo "-------------------------------------------------------------------------------------" | |
echo "Rotating Image: $file" | |
convert "$file" -geometry x200 "$file"_resized.jpg | |
convert "$file"_resized.jpg -rotate 270 "$file"_rotated.jpg | |
echo "Creating 24bit bmp: "$file"_24.bmp" | |
convert "$file"_rotated.jpg -type truecolor "$file"_24.bmp | |
rm "$file"_rotated.jpg | |
rm "$file"_resized.jpg |
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] |
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
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
<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
<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
<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
<!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
#!/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; |