Skip to content

Instantly share code, notes, and snippets.

View snargledorf's full-sized avatar

Ryan Esteves snargledorf

View GitHub Profile
PRIVACY POLICY FOR Memory Squares
This privacy policy governs your use of the software application Memory Squares (“Application”) for mobile devices that was created by TheEste. The Application is a game about following the pattern of lighted tiles and sounds.
What information does the Application obtain and how is it used?
User Provided Information
The Application obtains the information you provide when you download and register the Application. Registration with us is optional. However, please keep in mind that you may not be able to use some of the features offered by the Application unless you register with us.
When you register with us and use the Application, you generally provide (a) your name, email address, age, user name, password and other registration information; (b) transaction-related information, such as when you make purchases, respond to any offers, or download or use applications from us; (c) information you provide us when you contact us for help; (d) credit card information for purcha
@snargledorf
snargledorf / import.py
Created November 10, 2014 15:06 — forked from kbl/import.py
# -*- coding: utf8 -*-
import json
import urllib2
import urllib
import sys
import os
from argparse import ArgumentParser
from collections import defaultdict
@snargledorf
snargledorf / SecurePreferences.java
Last active August 29, 2015 14:01
SecurePreferences
package com.theeste.securepreferences;
/*
* Copyright (C) 2013, Daniel Abraham
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
@snargledorf
snargledorf / ViewServer.cs
Created November 12, 2013 22:16
This is a very messy and hastily done port of the ViewServer class created by romainguy (https://github.com/romainguy) to C# specificly for use in Xamarin. It works, there are probably bugs, and I don't really intend on expanding on it much more. I just want to put it out there so maybe it can help someone else out.
/*
* Copyright (C) 2011 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
@snargledorf
snargledorf / RunOnUiThreadExtensionMethod
Created July 26, 2013 16:36
This is an extension method for the Windows Form class that mimics the behavior of Androids Activity.runOnUiThread(Runnable) method.
public static class RunOnUiThreadExtensionMethod
{
public static void RunOnUiThread(this Form @this, Action action)
{
if (@this.InvokeRequired)
{
@this.BeginInvoke(action);
}
else
{
@snargledorf
snargledorf / gist:5709298
Created June 4, 2013 20:28
Else what?!
private void textSystemRequestCode_TextChanged(object sender, EventArgs e)
{
if (textSystemRequestCode.Text.Length > 0)
{
this.m_licenseResponse.SerialNumber = textSystemRequestCode.Text;
this.m_licenseResponse.UpdateResponse();
}
else { }
UpdateForm();
}
@snargledorf
snargledorf / gitignore.bat
Created February 20, 2012 19:09
Scripts for creating a .gitignore using drag and drop.
:: To use drag and drop the files/folders you would like to ignore onto the script.
:: A .gitignore file will be created in the root directory of the files/folders that you drop on the script
:: Ex. I want to hide the file 'C:\myrepo\filetohide.txt'
:: When I drop this file onto this script a .gitignore
:: file will be created at 'C:\myrepo\.gitignore'.
:: Originaly created by Ryan Esteves 1/19/2011
@echo off
@snargledorf
snargledorf / gist:1712580
Created January 31, 2012 20:01
Script for retrieving package source using apt-get. Tested under Ubuntu 11.10
#!/bin/bash
if [ $# < 1 ] || [ $# > 2 ]
then
echo -e "Usage: \n$0 <package name> \n$0 <package name> <dir>"
exit 1
fi
if [ $# == 2 ]
then
@snargledorf
snargledorf / installer.sh
Created November 21, 2011 21:59 — forked from tahl/installer.sh
Android SDK + NDK + Eclipse and ADB Installer
#!/bin/bash
#
#This script is designed to install the Android SDK, NDK, and Eclipse in Linux Mint 11 and make it easier for people that want to develop for Android using Linux.
#Script written by @ArchDukeDoug with special thanks to @BoneyNicole, @tabbwabb, and @animedbz16 for putting up with me and proofreading and/or testing the script.
#I can be reached at dougw@uab.edu, twitter, or linuxrandomly.blogspot.com
#Script version: 1.0.5
#Changelog: 1.0.5 - Fixed the Android SDK search parameters to fit the new naming scheme on http://developer.android.com/sdk
i=$(cat /proc/$PPID/cmdline)
if [[ $UID != 0 ]]; then
echo "Please type sudo $0 $*to use this."