Skip to content

Instantly share code, notes, and snippets.

[user]
name = Jens Kohl
email = jens.kohl@…
signingkey = 8EFDF903
[color]
status = auto
diff = auto
branch = auto
interactive = auto
pager = false
@urschrei
urschrei / basemap_descartes.py
Last active November 6, 2020 02:49
How to plot Shapely Points using Matplotlib, Basemap, and Descartes
"""
required packages:
numpy
matplotlib
basemap: http://matplotlib.org/basemap/users/installing.html
shapely: https://pypi.python.org/pypi/Shapely
descartes: https://pypi.python.org/pypi/descartes
random
@MaZderMind
MaZderMind / guthaben.sh
Created June 5, 2014 16:14
Aktuelles Guthaben via Shell von einem angeschlossenen Prepaid-USB-3G-Stick auslesen. Getestet mit Congstar Prepaid-Stick.
#!/bin/sh
export LANG=C
echo "wait 60 seconds"
{
gammu getussd "*100#" |\
grep reply |\
awk '{print substr($4, 2, length($4)-2)}' |\
sed 's/\([0-9A-F]\{2\}\)/\\\\\\x\1/gI' |\
xargs printf;
} &
server {
listen 80;
server_name www.domain.tld domain.tld;
access_log /var/log/nginx/domain.tld.access_log andre;
error_log /var/log/nginx/domain.tld.error_log warn;
# iTunes podcast does not accept SSL in 2016 :-(
root /var/www/domain.tld/htdocs/;
@lucaswerkmeister
lucaswerkmeister / BerlinRailwayThings.sparql
Created June 25, 2017 09:08
“railway things” in Berlin, as classified by LinkedGeoData.org
#defaultView:Map
PREFIX lgdo: <http://linkedgeodata.org/ontology/>
PREFIX geom: <http://geovocab.org/geometry#>
PREFIX ogc: <http://www.opengis.net/ont/geosparql#>
PREFIX bif: <bif:>
SELECT ?subway ?geometry (SAMPLE(?label) AS ?label) ?layer WHERE {
SERVICE <http://linkedgeodata.org/sparql> {
?railwayThing a lgdo:RailwayThing;
@rwese
rwese / macos_automator_msteams_without_gpu.sh
Created October 28, 2019 08:26
Restart MS Teams with "disable-gpu" to reduce battery consumption.
#!/bin/bash
# Created 2019-04, Author: René Weselowski <rene.weselowski@gmail.com>
#
# This script is entended as an macos automator 'application' run at startup
# to kill the MSTeams process and restart it wiith '--disable-gpu'
#
# Usage:
# Create a new automator task "Run Shell Script"
# Shell: /bin/bash
# Put it into your login/startup items
@FelixHenninger
FelixHenninger / chaos.sql
Created June 25, 2024 21:16
Inventory database proposal
-- Common metadata -------------------------------------------------------------
-- Units
CREATE TABLE units (
id INTEGER PRIMARY KEY NOT NULL,
-- Metadata
name VARCHAR NOT NULL,
note TEXT NOT NULL DEFAULT "",
--