Skip to content

Instantly share code, notes, and snippets.

View iamcxa's full-sized avatar
🎯
Focusing

Kent Chen iamcxa

🎯
Focusing
View GitHub Profile
@iamcxa
iamcxa / pr.md
Created May 26, 2018 19:38 — forked from piscisaureus/pr.md
Checkout github pull requests locally

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

@iamcxa
iamcxa / SoftKeyboard.java
Created December 21, 2017 05:04 — forked from felHR85/SoftKeyboard.java
A solution to catch show/hide soft keyboard events in Android http://felhr85.net/2014/05/04/catch-soft-keyboard-showhidden-events-in-android/
/*
* Author: Felipe Herranz (felhr85@gmail.com)
* Contributors:Francesco Verheye (verheye.francesco@gmail.com)
* Israel Dominguez (dominguez.israel@gmail.com)
*/
import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.atomic.AtomicBoolean;
import android.os.Handler;
@iamcxa
iamcxa / 0_reuse_code.js
Created December 25, 2015 07:26
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console