See how a minor change to your commit message style can make you a better programmer.
Format: <type>(<scope>): <subject>
<scope>
is optional
public class NewIntentProcessor extends AbstractProcessor { | |
private static final String METHOD_PREFIX = "start"; | |
private static final ClassName classIntent = ClassName.get("android.content", "Intent"); | |
private static final ClassName classContext = ClassName.get("android.content", "Context"); | |
private Filer filer; | |
private Messager messager; | |
private Elements elements; | |
private Map<String, String> activitiesWithPackage; |
public class MyBehavior : MonoBehaviour { | |
// This will store the string value | |
[StringInList("Cat", "Dog")] public string Animal; | |
// This will store the index of the array value | |
[StringInList("John", "Jack", "Jim")] public int PersonID; | |
// Showing a list of loaded scenes | |
[StringInList(typeof(PropertyDrawersHelper), "AllSceneNames")] public string SceneName; | |
} |
import android.content.Context; | |
import android.os.Debug; | |
import java.io.File; | |
public class OomExceptionHandler implements Thread.UncaughtExceptionHandler { | |
private static final String FILENAME = "out-of-memory.hprof"; | |
public static void install(Context context) { | |
Thread.UncaughtExceptionHandler defaultHandler = Thread.getDefaultUncaughtExceptionHandler(); |
#=============================================================================== | |
# Filename: boost.sh | |
# Author: Pete Goodliffe | |
# Copyright: (c) Copyright 2009 Pete Goodliffe | |
# Licence: Please feel free to use this, with attribution | |
# Modified version | |
#=============================================================================== | |
# | |
# Builds a Boost framework for the iPhone. | |
# Creates a set of universal libraries that can be used on an iPhone and in the |
// | |
// PSPDFThreadSafeMutableDictionary.m | |
// | |
// Copyright (c) 2013 Peter Steinberger, PSPDFKit GmbH. All rights reserved. | |
// | |
// Permission is hereby granted, free of charge, to any person obtaining a copy | |
// of this software and associated documentation files (the "Software"), to deal | |
// in the Software without restriction, including without limitation the rights | |
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
// copies of the Software, and to permit persons to whom the Software is |
import com.android.volley.toolbox.HurlStack; | |
import com.squareup.okhttp.OkHttpClient; | |
import java.io.IOException; | |
import java.net.HttpURLConnection; | |
import java.net.URL; | |
/** | |
* An {@link com.android.volley.toolbox.HttpStack HttpStack} implementation which | |
* uses OkHttp as its transport. | |
*/ |
Generate the list yourself:
$ cd /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS*.sdk/System/Library/Frameworks/UIKit.framework/Headers
$ grep UI_APPEARANCE_SELECTOR ./* | \
sed 's/NS_AVAILABLE_IOS(.*)//g' | \
sed 's/NS_DEPRECATED_IOS(.*)//g' | \
sed 's/API_AVAILABLE(.*)//g' | \
sed 's/API_UNAVAILABLE(.*)//g' | \
sed 's/UI_APPEARANCE_SELECTOR//g' | \
<!-- Highlight syntax for Mou.app, insert at the bottom of the markdown document --> | |
<script src="http://yandex.st/highlightjs/7.3/highlight.min.js"></script> | |
<link rel="stylesheet" href="http://yandex.st/highlightjs/7.3/styles/github.min.css"> | |
<script> | |
hljs.initHighlightingOnLoad(); | |
</script> |
#include <stdio.h> | |
#include <string.h> | |
#include <sys/system_properties.h> | |
/* Get device name | |
-- | |
1/ Compile with the Android NDK Toolchain: | |
arm-linux-androideabi-gcc -static pname.c -o pname | |
2/ Transfer on device: |