This file contains 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
/Users/zacmcc/.vim/ | |
▸ autoload/ | |
▸ backup/ | |
▸ bundle/ | |
▸ colors/ | |
▸ tmp/ |
This file contains 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
" | |
" Author: Zac McCormick | |
" https://github.com/zhm/macvimhax | |
" https://github.com/brentd/vimfiles | |
" | |
call pathogen#helptags() | |
call pathogen#runtime_append_all_bundles() | |
set nocompatible |
This file contains 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
" | |
" Author: Zac McCormick | |
" https://github.com/zhm/macvimhax | |
" https://github.com/brentd/vimfiles | |
" | |
call pathogen#helptags() | |
call pathogen#runtime_append_all_bundles() | |
set nocompatible |
This file contains 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
function long2tileX(lon, zoom) { | |
return Math.floor((lon + 180.0) / 360.0 * Math.pow(2.0, zoom)); | |
} | |
function lat2tileY(lat, zoom) { | |
var googleY = Math.floor((1.0 - Math.log(Math.tan(lat * Math.PI/180.0) + 1.0 / Math.cos(lat * Math.PI/180.0)) / Math.PI) / 2.0 * Math.pow(2.0, zoom)); | |
var tmsY = Math.pow(2.0, zoom) - googleY - 1; | |
return tmsY; | |
} |
This file contains 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
# This makefile generates 4 Ruby extensions - one each for | |
# gdal, ogr, osr, and gdalconstants. There are two important | |
# things to note: | |
# | |
# * It makes multiple calls to Ruby to discover the Ruby version, | |
# location of header files, libraries, etc. Thus Ruby must | |
# be on your path. | |
# | |
# * By convention Ruby method names are lower case with underscores, | |
# thus methods such as "GetFieldName" need to be mapped to |
This file contains 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
# This makefile generates 4 Ruby extensions - one each for | |
# gdal, ogr, osr, and gdalconstants. There are two important | |
# things to note: | |
# | |
# * It makes multiple calls to Ruby to discover the Ruby version, | |
# location of header files, libraries, etc. Thus Ruby must | |
# be on your path. | |
# | |
# * By convention Ruby method names are lower case with underscores, | |
# thus methods such as "GetFieldName" need to be mapped to |
This file contains 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
/* | |
* $Id$ | |
* | |
* ruby specific code for gdal bindings. | |
*/ | |
/* | |
* $Log$ | |
* Revision 1.2 2005/09/26 08:18:55 cfis | |
* Copied over code from the Python version of gdal_ruby.i. Will have to port the code to Ruby. |
This file contains 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
/****************************************************************************** | |
* $Id$ | |
* | |
* Name: typemaps_ruby.i | |
* Project: GDAL Ruby Interface | |
* Purpose: GDAL Core SWIG Interface declarations. | |
* Author: Charles F. I. Savage | |
* |
This file contains 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 fs = require('fs'); | |
var files = process.argv.slice(2); | |
var output = { type: 'LineString', coordinates: [ ] }; | |
for (var i = 0; i < files.length; ++i) { | |
output.coordinates.append(JSON.parse(fs.readFileSync(files[i])).coordinates); | |
} | |
fs.writeFileSync('output.json', JSON.stringify(output, null, '\t')); |
This file contains 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
for file in ~/postgres_backups/* | |
do | |
dbname=$(basename $file | sed s/\.gz//g) | |
createdb $dbname | |
gunzip -c $file | sed 's/Library\/PostgreSQL\/9.0\/lib\/postgis-1.5/usr\/local\/Cellar\/postgresql\/9.1.3\/lib\/postgis-1.5/g' | psql $dbname | |
done |
OlderNewer