Get gdal development libraries:
$ sudo apt-add-repository ppa:ubuntugis/ubuntugis-unstable
$ sudo apt-get update
$ sudo apt-get install libgdal-dev
Create and activate a virtual environment:
# Credit http://stackoverflow.com/a/2514279 | |
for branch in `git branch -r | grep -v HEAD`;do echo -e `git show --format="%ci %cr" $branch | head -n 1` \\t$branch; done | sort -r |
var install_hook_to = function(obj) { | |
if (obj.hook || obj.unhook) { | |
throw new Error('Object already has properties hook and/or unhook'); | |
} | |
obj.hook = function(_meth_name, _fn, _is_async) { | |
var self = this, | |
meth_ref; | |
# -*- coding: utf-8 -*- | |
import Image | |
def resize_and_crop(img_path, modified_path, size, crop_type='top'): | |
""" | |
Resize and crop an image to fit the specified size. | |
args: | |
img_path: path for the image to resize. |
git diff HEAD --ignore-space-at-eol |
<?php | |
/* from http://lists.osgeo.org/pipermail/openlayers-users/2010-June/017976.html */ | |
$conn_string = "host=localhost port=5432 | |
dbname=mydatabase_with_postgis_activated user=my_user password=my_password"; | |
$link = pg_connect($conn_string) or die("Could not connect"); | |
$start_epsg = 'Proj4js.defs["EPSG:'; | |
$end_epsg_start_proj4js = '"] = "'; | |
$end_proj4js ='";'; |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
#!/bin/sh | |
# Based on instructions found here: http://wiki.razuna.com/display/ecp/FFMpeg+Installation+on+CentOS+and+RedHat#FFMpegInstallationonCentOSandRedHat-InstallX264 | |
if [ "`/usr/bin/whoami`" != "root" ]; then | |
echo "You need to execute this script as root." | |
exit 1 | |
fi | |
cat > /etc/yum.repos.d/centos.repo<<EOF |
# -*- coding: utf8 -*- | |
import json | |
import urllib2 | |
import urllib | |
import sys | |
import os | |
from argparse import ArgumentParser | |
from collections import defaultdict |
To remove a submodule you need to: