Open ~/.bash_profile
in your favorite editor and add the following content to the bottom.
# Git branch in prompt.
parse_git_branch() {
import android.util.Log; | |
import com.google.gson.Gson; | |
import com.google.gson.annotations.SerializedName; | |
import java.io.IOException; | |
import retrofit.Callback; | |
import retrofit.Response; | |
import retrofit.Retrofit; |
public class FragmentUtils { | |
public static FragmentTransaction ensureTransaction(final FragmentManager fragmentManager) { | |
FragmentTransaction fragmentTransaction = fragmentManager.beginTransaction(); | |
fragmentTransaction.setCustomAnimations(R.anim.slide_in_right, R.anim.slide_out_left, R.anim.slide_in_right, R.anim.slide_out_left); | |
return fragmentTransaction; | |
} | |
public static Fragment getFragment(final FragmentManager fragmentManager, final String tag) { | |
return fragmentManager.findFragmentByTag(tag); |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.