Skip to content

Instantly share code, notes, and snippets.

@zhuowei
zhuowei / kernel_changelog_tidbits.md
Last active December 19, 2015 10:59
Glass Kernel Changelog Tidbits

Kernel Changelog Tidbits for Glass

I've always enjoyed teardowns of of the software in new products. As you can expect, I loved the detailed writeup of the secrets found in Google Glass's kernel source at http://thecodeartist.blogspot.ca/2013/05/sensors-on-google-glass.html . However, when that article is written, the source code of the kernel was just served without the changelog (provided by their version control system, Git). Since then, Google had released the kernel with full change information on AOSP.

If you want to dig around the logs yourself: https://android.googlesource.com/kernel/omap/+log/glass-omap-xrr88/ with highlights at https://android.googlesource.com/kernel/omap/+log/glass-omap-xrr88/arch/arm/mach-omap2/board-notle.c and https://android.googlesource.com/kernel/omap/+log/glass-omap-xrr88/arch/arm/mach-omap2/notle-usb-mux.c . More eyes will probably uncover more secrets.

@grantslatton
grantslatton / hngen.py
Last active September 27, 2021 11:07
A program that uses Markov chains to generate probabilistic Hacker News titles.
import urllib2
import re
import sys
from collections import defaultdict
from random import random
"""
PLEASE DO NOT RUN THIS QUOTED CODE FOR THE SAKE OF daemonology's SERVER, IT IS
NOT MY SERVER AND I FEEL BAD FOR ABUSING IT. JUST GET THE RESULTS OF THE
CRAWL HERE: http://pastebin.com/raw.php?i=nqpsnTtW AND SAVE THEM TO "archive.txt"
@JakeWharton
JakeWharton / AutoGson.java
Last active November 28, 2021 12:32
A Gson TypeAdapterFactory which allows serialization of @autovalue types. Apache 2 licensed.
import com.google.auto.value.AutoValue;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
import static java.lang.annotation.ElementType.TYPE;
import static java.lang.annotation.RetentionPolicy.RUNTIME;
/**
* Marks an {@link AutoValue @AutoValue}-annotated type for proper Gson serialization.
* <p>