Skip to content

Instantly share code, notes, and snippets.

View jsanz's full-sized avatar
🗺️
Mapping

Jorge Sanz jsanz

🗺️
Mapping
View GitHub Profile
@jsanz
jsanz / mapproxy.yaml
Created March 12, 2012 14:52
Simple proxying of the Spanish PNOA service to get a WMS from their TMS
services:
demo:
kml:
tms:
wmts:
wms:
srs: ['EPSG:900913', 'EPSG:4258']
image_formats: ['image/jpeg', 'image/png']
md:
title: PNOA MapProxy
@jsanz
jsanz / mapproxy.yaml
Created March 30, 2012 08:55 — forked from nachouve/mapproxy.yaml
Simple proxying of the Spanish PNOA service to get a WMS from their TMS
services:
demo:
kml:
tms:
wmts:
wms:
srs: ['EPSG:900913', 'EPSG:4258']
image_formats: ['image/jpeg', 'image/png']
md:
title: PNOA MapProxy
@jsanz
jsanz / gist:2250545
Created March 30, 2012 10:05
mi ttytterc
#TTYtter settings
timestamp=%H:%M
#use ssl
ssl=1
#show replies in timeline
mentions=1
#Open images (with libcaca)
#avatar=gthumb %U&
avatar=wget %U -qO /tmp/avatar && img2txt -f utf8 /tmp/avatar
#Open URLs with default browser
@jsanz
jsanz / linkedin.md
Last active October 2, 2015 23:58
Linkedin reply templates

Linkedin reply templates

English - default reply template

Hi,

Have we met? I do not usually add to my network people I don't know without talking a little, know why you are interested in my profile, etc..

But it happens also I'm terrible with names so if we've met before, please I beg your pardon.

@jsanz
jsanz / brownie-de-chocolate.md
Created May 15, 2012 07:11
Brownie de chocolate, receta de Christophe

A petición popular, la receta del brownie de ayer :-).

  • calentar 1'30'' (micro-ondas) 250g chocolate + 250g mantequilla o margarina
  • a parte, mezclar 3 huevos XL + 300g azúcar
  • añadir la mescla de chocolate/mantequilla fundido
  • añadir 150g harina (+ nueces)
  • poner al horno precalentado 180ºc 25'
  • desmoldar caliente ...

a disfrutar :-D

@jsanz
jsanz / firma-ivan.txt
Created October 19, 2012 08:30
Firma correo al estilo de Iván
Aviso: Este e-mail es confidencial y no debería ser usado por nadie que no sea el destinatario original.
No se permite la reproducción mediante fotocopia, walkie-talkie, emisora de radioaficionado, satélite,
televisión por cable, proyector, señales de humo, código morse, braille, lenguaje de signos, taquigrafía
o cualquier otro medio. Bajo ningún concepto debe traducirse al francés este e-mail. Este e-mail no puede
ser ridiculizado, parodiado, juzgado en una competición, o leído en voz alta con un acento gracioso
llevando un bigote falso y/o cualquier tipo de sombrero, incluyendo pero no limitándose a pañuelos.
No inciten ni provoquen a este e-mail. Si está medicándose, puede experimentar nauseas, desorientación,
histeria, vómitos, pérdida temporal de la memoria a corto plazo y malestar general al leer este e-mail.
Consulte a su médico o farmacéutico antes de leer este e-mail. Todas las modelos descritas en este
e-mail son mayores de 18 años. Este e-mail se reserva el derecho de admisión. Si ha recib
@jsanz
jsanz / heapify.py
Created October 23, 2012 06:59 — forked from jul/heapify.py
Exact translation of an heap obfuscated algorithm (validating python syntax rules)
"""
A heap is a recipie to represent an array as a
binary tree.
A binary tree is a convenient structure for
manipulating ordered data
Said simply:
we implement a binary tree abstraction on top of an array.
this tree as the following properties:
any child value is smaller than its parent's value
left child is greater than right child.
@jsanz
jsanz / numbers.scala
Created October 30, 2012 22:10
Scala collections: mapping letters example
package week6
import scala.io.Source
object collections {
/* read a file of words */
val in = Source.fromURL("http://lamp.epfl.ch/files/content/sites/lamp/files/teaching/progfun/linuxwords.txt")
/* create a list and filter all words where *all* their characters are not letters (like dashes) */
val words = in.getLines.toList filter (word => word forall (chr => chr.isLetter))
@jsanz
jsanz / receta-pasta-anis.md
Last active July 24, 2021 09:23
Receta navidad

Receta para pasta de anís

Esta receta sirve para hacer cocas finas, rollos de anís y pastelitos de boniato.

Ingredientes

  • 1kg de harina
  • 4 vasos de cortado de aceite
@jsanz
jsanz / gist:5141420
Created March 12, 2013 09:15
From CartoDB to DXF, with all my love to CAD users
# With the GeoJSON OGR driver one can use the CartoDB SQL API to create any OGR supported format output
# OGR Formats: http://gdal.org/ogr/ogr_formats.html
# CartoDB SQL API: http://developers.cartodb.com/documentation/sql-api.html
# This sample creates a DXF making a "select the_geom from meteo" from my account at CartoDB
ogr2ogr -skipfailures -f DXF out.dxf "http://xurxosanz.cartodb.com/api/v2/sql?q=select%20the_geom%20from%20meteo&format=GeoJSON" OGRGeoJSON