Skip to content

Instantly share code, notes, and snippets.

View marchold's full-sized avatar

Marc Holder Kluver marchold

  • Central Coast Calaforina
View GitHub Profile
#prefix history
bind '"\eOA": history-search-backward'
bind '"\e[A": history-search-backward'
bind '"\eOB": history-search-forward'
bind '"\e[B": history-search-forward'
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
alias gitundo='git reset --soft HEAD~1'Ã\203Â\203Ã\202Â\203Ã\203Â\202Ã\202Â\203Ã\203Â\203Ã\202Â\202Ã\203Â\202Ã\202¢Ã\203Â\203Ã\202Â\203Ã\203Â\202Ã\202Â\202Ã\203Â\203Ã\202Â\20\
2Ã\203Â\202Ã\202Â\200Ã\203Â\203Ã\202Â\203Ã\203Â\202Ã\202Â\202Ã\203Â\203Ã\202Â\202Ã\203Â\202Ã\202Â\202Ã\203Â\203Ã\202Â\203Ã\203Â\202Ã\202Â\203Ã\203Â\203Ã\202Â\202Ã\203Â\202Ã\20\
2¢Ã\203Â\203Ã\202Â\203Ã\203Â\202Ã\202Â\202Ã\203Â\203Ã\202Â\202Ã\203Â\202Ã\202Â\200Ã\203Â\203Ã\202Â\203Ã\203Â\202Ã\202Â\202Ã\203Â\203Ã\202Â\202Ã\203Â\202Ã\202Â\2
@marchold
marchold / Android Message Dialog
Created January 15, 2015 22:21
A simple dialog box for android
import android.app.AlertDialog;
import android.app.Dialog;
import android.app.DialogFragment;
import android.app.FragmentManager;
import android.content.DialogInterface;
import android.os.Bundle;
/**
* Generic message dialog
@marchold
marchold / Android Email Autocomplete
Last active August 1, 2021 05:53
Autocomplete for email addresses in android.
import android.accounts.Account;
import android.accounts.AccountManager;
import android.content.Context;
import android.text.Editable;
import android.text.InputType;
import android.text.TextWatcher;
import android.util.AttributeSet;
import android.util.Patterns;
import android.widget.ArrayAdapter;
@marchold
marchold / Android SwitchPlusClickPreference
Last active November 20, 2022 09:38
extension of SwitchPreference that allows you to add a click handler to the preference area as well as the switch. For making switch preferences that work like Android WiFi settings.
import android.content.Context;
import android.preference.SwitchPreference;
import android.util.AttributeSet;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Switch;
/**
* Custom preference for handling a switch with a clickable preference area as well
@marchold
marchold / CGAffineTransform_Additions.h
Created November 3, 2014 18:25
A resizable image view, never fully worked but the affine transform stuff in it is solid
#import <UIKit/UIKit.h>
CGFloat CGAffineTransformGetScaleX(CGAffineTransform t);
CGFloat CGAffineTransformGetScaleY(CGAffineTransform t);
CGFloat CGAffineTransformGetRotation(CGAffineTransform t);
CGFloat CGAffineTransformGetTranslationX(CGAffineTransform t);