Skip to content

Instantly share code, notes, and snippets.

View GJSmith3rd's full-sized avatar

Gilbert Smith GJSmith3rd

View GitHub Profile
@GJSmith3rd
GJSmith3rd / gitrevert
Created May 10, 2016 03:53
From http://stackoverflow.com/questions/4114095/revert-git-repo-to-a-previous-commit - Safely revert to previous commit while keeping history and avoid continuous prompts at various commit stages.
git revert --no-commit 0766c053..HEAD
git commit
@GJSmith3rd
GJSmith3rd / FPMessaging.mod
Created February 12, 2016 23:31
FreedomPop Messaging Mod
https://forums.freedompop.com/discussion/9504/how-do-you-disable-freedompops-integration-with-the-android-dialer
nickjuly4nickjuly4 Posts: 10FreedomPop Newbie
February 3 edited February 3
I found a way to disable the integration with Android dialer that seems to work, though it requires a rooted device and a root file explorer (like Root Browser) unless there's some other way to do it.
- Launch Root Browser (or any other root file explorer)
- Navigate to the root directory of your phone (in Root Browser tap the home icon in the top left corner of the screen)
@GJSmith3rd
GJSmith3rd / index.html
Last active August 27, 2015 22:19
mobileCreature Web Design Studio
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
<meta name="mobileCreature Web Design Studio" content="">
<meta name="Gilbert Joseph Smith III" content="">
<link rel="icon" href="http://i.imgur.com/fZpm3YM.jpg">
@GJSmith3rd
GJSmith3rd / gulpfile.js
Created July 25, 2015 17:47
Gulp file that starts a node.js app and performs other tasks like auto restarting browsers, injecting CSS and JS, Linting, etc.
/// <reference path="typings/tsd.d.ts" />
var gulp = require('gulp');
var args = require('yargs').argv;
var browserSync = require('browser-sync');
//require func-sion containing config variable and run
var config = require('./gulp.config.js')();
var del = require('del');
Reset remote to local master with commits.
git push bitbucket master --force
$ java -version
$ sudo update-alternatives --config java
$ ls -la /etc/alternatives/java* && ls -la /etc/alternatives/jar
$ sudo update-alternatives --config javac
$ sudo update-alternatives --config java
@GJSmith3rd
GJSmith3rd / clear_android_cache.js
Created October 9, 2013 07:24
Unverified - Undefined Error in Apperi.io - Clearing Android Hybrid App Cache via Cordova/PhoneGap Undocumented API http://community.phonegap.com/nitobi/topics/android_caching_problems
navigator.app.cleanCache(); //PhoneGap Build - Undefined Error Apperi.io
webview.getSettings().setCacheMode(false); //Eclipse
service_name.execute(
{
data: { object with request params },
headers: { object with request header params },
success: function( PlainObject data, String textStatus, jqXHR jqXHR ) {
//Success handler here
},
ADB Sideload
What is ADB sideload?
ADB sideload is a new feature that was added to AOSP recovery in Jelly Bean. As of version 2.3, TWRP now supports ADB sideload mode. ADB sideload is a different ADB mode that you can use to push and install a zip using one command from your computer. Most likely ADB sideload won't be very useful for your average recovery user, but ADB sideload can be a huge time-saver for a ROM developer.
How do I use ADB sideload?
Have a recovery installed on your device that supports ADB sideload like TWRP 2.3 or higher
Have newer ADB binaries installed on your computer. If it's been a while since you installed ADB on your computer, you may need to get the latest ADB binaries in platform-tools from the Android SDK. You will need version 1.0.29 or higher. You can find your current version by typing "adb version" at the command line.
@GJSmith3rd
GJSmith3rd / 0_reuse_code.js
Created October 8, 2013 22:01
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