Skip to content

Instantly share code, notes, and snippets.

@jerrellmardis
jerrellmardis / DisplayTimeoutTileService.java
Created June 3, 2016 22:10
A quick example demonstrating how to create a Quick Settings Tile using the new Quick Settings Tile API introduced in Android N.
import android.provider.Settings;
import android.service.quicksettings.Tile;
import android.service.quicksettings.TileService;
import android.widget.Toast;
import java.util.concurrent.TimeUnit;
import static android.provider.Settings.System.SCREEN_OFF_TIMEOUT;
/**
# Script to add back comments removed from source code
# Example use case: comments stripped out of HTC kernel releases
#
# Copyright (C) 2016 Sultan Qasim Khan
#
# Usage:
# 1. Find the closest upstream source release with comments (eg. CAF)
# 2. After checking out the closest upstream release, create a git
# commit overlaying the OEM modifications. Do this by replacing
# all files with the OEM versions and committing the change.
@emkay
emkay / build-grub-osx.sh
Last active January 25, 2024 04:25
Build Grub on OSX
#!/bin/sh
set -e
# First we are going to make sure that you understand this is sort of experimental and we will be compiling stuff.
# by default CONTINUE will be false
CONTINUE=false
echo ""
echo "You are about to download, compile, and install stuff on your computer."