Skip to content

Instantly share code, notes, and snippets.

@usr-ein
usr-ein / Dockerfile
Last active August 1, 2025 13:41
Optimal multistaged Dockerfile for poetry
# syntax=docker/dockerfile:1
# Keep this syntax directive! It's used to enable Docker BuildKit
# Based on https://github.com/python-poetry/poetry/discussions/1879?sort=top#discussioncomment-216865
# but I try to keep it updated (see history)
################################
# PYTHON-BASE
# Sets up all our shared environment variables
################################
@Antarix
Antarix / UrlImageParser.java
Created November 29, 2012 08:48
UrlImage Parser for android TextView to load Html Image tag
import java.io.IOException;
import java.io.InputStream;
import java.net.MalformedURLException;
import org.apache.http.HttpResponse;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.impl.client.DefaultHttpClient;
import android.content.Context;
import android.graphics.Canvas;
@thallium205
thallium205 / ranker.java
Created March 22, 2012 15:01
Java Implementation of the Google App Engine Ranklist
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Iterator;
import java.util.LinkedHashSet;
import java.util.Map;
import java.util.Set;
import java.util.Map.Entry;
import org.mortbay.log.Log;