Skip to content

Instantly share code, notes, and snippets.

@perifer
perifer / switch_collation.php
Created December 20, 2010 15:32
Script for change the collation of a database's table (utf8)
#!/usr/bin/env php
<?php
/**
* Script for change the collation of a database's table's
*/
if ($argv[1] == '-h') {
echo "Usage:\n\tphp collation_switch.php sql-user sql-password sql-database target-collation target-character\nExample: php collation_switch.php USER PASS DATABASE utf8_swedish_ci utf8\n";
die();
}
<?php
/**
* Returns all the layers in the tile service.
*
* @return array
*/
function simplegeo_tileservice_get_layers() {
static $layers;
$cache_key = 'simplegeo_tileservice:layers';

Apps

#!/bin/sh
repo="`pwd`"
export GIT_DIR="$repo"
wd="`dirname $repo`"
echo "$repo"
echo "$wd"
cd "$wd"
git merge master
git submodule init