Skip to content

Instantly share code, notes, and snippets.

View castasat's full-sized avatar
❤️
Fast programming methods

Denis Dmitrienko castasat

❤️
Fast programming methods
  • DOO "Lorem Ipsum"
  • Herceg Novi, Montenegro
View GitHub Profile
@anandwana001
anandwana001 / OnButtonClick.java
Last active July 14, 2020 10:26
Save image from network to external storage using Glide
#Step 1
Glide.with(mContext)
.load(images.get(position).getThumbnail())
.asBitmap()
.into(new SimpleTarget<Bitmap>(100,100) {
@Override
public void onResourceReady(Bitmap resource, GlideAnimation glideAnimation) {
saveImage(resource,position);
}
});
@MisterRager
MisterRager / Rx2ServiceBindingFactory.java
Last active July 17, 2019 18:46
Bind to an Android service using RxJava!
import android.app.Service;
import android.content.ComponentName;
import android.content.Context;
import android.content.Intent;
import android.content.ServiceConnection;
import android.os.Binder;
import android.os.IBinder;
import io.reactivex.Observable;
@henriquemenezes
henriquemenezes / android-generate-keystores.md
Last active June 4, 2024 14:58
Android: Generate Release/Debug Keystores

Android: Generate Release/Debug Keystores

Generate Keystores

Debug Keystore

$ keytool -genkey -v -keystore debug.keystore -storepass android -alias androiddebugkey -keypass android -keyalg RSA -keysize 2048 -validity 10000 -dname "C=US, O=Android, CN=Android Debug"
@magnusbae
magnusbae / git-stop-tracking-remote-branch.md
Created April 8, 2014 20:05
How to make Git stop track a remote branch without deleting the remote branch.

You don't have to delete your local branch.

Simply delete your remote tracking branch:

git branch -d -r origin/<remote branch name> (This will not delete the branch on the remote repo!)

See "Having a hard time understanding git-fetch"

there's no such concept of local tracking branches, only remote tracking branches.