Skip to content

Instantly share code, notes, and snippets.

Avatar

Gilbert Wat gilbertwat

View GitHub Profile
@alanho
alanho / gist:51ea9161ace791da6d3e
Last active Oct 17, 2016
101 Ways to Convert HK1980 <> WGS84
View gist:51ea9161ace791da6d3e
Note:
HK1980: SRID 2326 http://spatialreference.org/ref/epsg/hong-kong-1980-grid-system/
WGS84: SRID 4326
Example:
Journey time indicators by Transport Department
https://data.gov.hk/en-data/dataset/hk-td-tis-journey-time-indicators
Location: H1 – JTI at Gloucester Road eastbound near the Revenue Tower (835776.133E, 815604.834N)
View tmp_npm.sh
#!/bin/bash
BASE_DIR=${TMPDIR:-/var/tmp}
ORIG_DIR=$PWD
HASH_CMD="md5sum"
DIR_NAME=`echo $PWD | $HASH_CMD | cut -f1 -d " "`
TMP_DIR=$BASE_DIR/$DIR_NAME
mkdir -p $TMP_DIR