Skip to content

Instantly share code, notes, and snippets.

View ImreSamu's full-sized avatar

ImreSamu ImreSamu

View GitHub Profile
# Docker image for PL/Julia.
#
# Build on top of an official Debian-based PostgreSQL image and keep the
# resulting image as close as practical to the upstream postgres image.
# In particular, avoid changing inherited defaults such as the working
# directory unless there is a clear need.
#
# Supported base images:
# https://hub.docker.com/_/postgres
# Example tags: postgres:14 .. postgres:18, and Debian-based variants.
@ImreSamu
ImreSamu / check-sql-headers.sh
Last active September 4, 2025 15:25
Orioledb SQL header check & optional fix. // https://github.com/orioledb/orioledb/pull/552
#!/usr/bin/env bash
set -euo pipefail
# Usage:
# ./check-sql-headers.sh [--fix] [rootdir]
# Examples:
# ./check-sql-headers.sh
# ./check-sql-headers.sh --fix .
# ./check-sql-headers.sh --fix path/to/repo
#!/usr/bin/env bash
set -euo pipefail
# Usage:
# ./check-headers.sh [--fix] [rootdir]
# Examples:
# ./check-headers.sh
# ./check-headers.sh --fix .
# ./check-headers.sh --fix path/to/repo
@ImreSamu
ImreSamu / OSM_community_manifesto_draft.md
Created August 13, 2025 18:33
OpenStreetMap Community Manifesto (Draft )

OpenStreetMap Community Manifesto (Draft)

Status: Draft v2025-08-13
License: CC0

Preamble

OpenStreetMap runs on people and places. "Local communities" are any groups of mappers - online or in person - who build and use OSM. "Local Chapters" are one formal expression of community, not the only one. The OpenStreetMap Foundation (OSMF) supports the project but does not control it. Our goal is to empower all communities to thrive, equally.

We value

@ImreSamu
ImreSamu / Dockerfile
Created November 4, 2023 01:39 — forked from tobwen/Dockerfile
PostGIS Debian OCI
# commits to be built
ARG CGAL55_GIT_COMMIT=tags/v5.6 # https://github.com/CGAL/cgal/tags
ARG SFCGAL_GIT_COMMIT=tags/v1.5.0 # https://github.com/Oslandia/SFCGAL_CI/tags
ARG PROJ_GIT_COMMIT=tags/9.3.0 # https://github.com/OSGeo/PROJ/tags
ARG GEOS_GIT_COMMIT=tags/3.12.0 # https://github.com/libgeos/geos/tags
ARG GDAL_GIT_COMMIT=tags/v3.7.3 # https://github.com/OSGeo/gdal/tags
ARG POSTGIS_GIT_COMMIT=tags/3.4.0 # https://github.com/postgis/postgis/tags
# base container with build-dependencies
FROM docker://postgres:16-bookworm AS build-deps
-----
-----
-- original code: http://web.archive.org/web/20111006010109/http://blog.cleverelephant.ca/2010/07/network-walking-in-postgis.html
----
----
DROP TABLE IF EXISTS network;
DROP TABLE
Time: 5.564 ms
BEGIN;
BEGIN
@ImreSamu
ImreSamu / addcolumns.py
Created November 13, 2022 01:38
extending ne_10m_admin_0_countries.shp
from shapely.geometry import mapping, shape
import fiona
with fiona.open('./10m_cultural/ne_10m_admin_0_countries.shp', 'r', encoding='utf-8' ) as input:
schema = input.schema.copy()
input_crs = input.crs
# add area_sqkm property if not present in the schema add it
if not hasattr( schema['properties'], 'area_sqkm'):
schema['properties']['area_sqkm'] = 'float:22.2'
#!/bin/bash
set -Eeuo pipefail
# bash test_st_astext_precision.bash > test_st_astext_precision.log
# related? https://trac.osgeo.org/postgis/ticket/4947
function postgistest {
dockername="$1"
dockerimages="$2"
echo ""
@ImreSamu
ImreSamu / id_langDups_all.md
Created October 5, 2018 19:58
2018-October-05 - 21:50CET - iD Editor unclear translations - Testing
language nameTransl nameEn presetKey searchable icon tags0 tags1 tags2 tags3 tags4 geometryArea geometryLine geometryPoint geometryVertex geometryRelation
af Begrafplaas Graveyard amenity/grave_yard maki-cemetery amenity=grave_yard area point
af Begrafplaas Cemetery landuse/cemetery maki-cemetery landuse=cemetery area
af Dorpie Hamlet place/hamlet maki-triangle-stroked place=hamlet area point
af Dorpie Village place/village maki-village place=village area point
af Fontein Fountain amenity/fountain temaki-fountain amenity=fountain area point
af Fontein Spring natural/spring maki-water natural=spring point vertex
af Kroeg Bar amenity/bar maki-bar amenity=bar area point
af Kroeg Pub amenity/pub maki-beer amenity=pub area point
@ImreSamu
ImreSamu / check_idpresets.sh
Created September 21, 2018 03:15
check_idpresets.sh [ 2018.Sep.21]
#!/bin/bash
# name: check_idpresets.sh [ 2018.Sep.21]
# check iD Editor Translations
# --- Determine Duplicate Elements,
# --- Export presets to CSV
#
# License: same as iD Editor / available under the WTFPL : http://sam.zoy.org/wtfpl/
# Created by ImreSamu for helping hungarian translations
#
# requirements :