Skip to content

Instantly share code, notes, and snippets.

View jeaneric's full-sized avatar

jeaneric

  • AECOM
  • Gaspé, Québec, Canada
View GitHub Profile
@jeaneric
jeaneric / postgis_side.sql
Last active December 8, 2023 19:40
PostGIS function to get the side of a point or geometry from a line
-- PostGIS function to get the side of a point or geometry from a line
-- ***** side function
-- ***** does not support m values. Only the digitizing "orientaiton" of the line.
-- -- inspired by: https://gis.stackexchange.com/a/156585
CREATE OR REPLACE FUNCTION st2_side (
geom_line geometry,
geom_other geometry
)
RETURNS text AS
$BODY$
@jeaneric
jeaneric / smtp_relay.py
Last active December 31, 2015 23:29 — forked from TheBHump/smtp_relay.py
"""
SMTP->SES Relay Server
Author: Brian Humphrey, Loku.com
E-mail: bhump@loku.com
Date: August 17, 2011
A Lightweight SMTP server that accepts all messages and relays them to SES
Credit to http://www.doughellmann.com/PyMOTW/smtpd/ for a tutorial on smtpd with asyncore
@jeaneric
jeaneric / gist:4162013
Created November 28, 2012 15:33
ArcGIS create footprint for raster folder
#Inspired by the code present in this answer:
#http://gis.stackexchange.com/a/26944/2043
import arcpy,os
def main():
InFolder = arcpy.GetParameterAsText(0)
Dest=arcpy.GetParameterAsText(1)
arcpy.env.workspace=InFolder