Skip to content

Instantly share code, notes, and snippets.

@vml-rmott
vml-rmott / AnimateMaskableGraphic.cs
Created September 3, 2018 21:49
Proxy materialForRendering properties for Timeline animation
using System.Collections;
using UnityEngine;
using UnityEngine.UI;
[ExecuteInEditMode]
public class AnimateMaskableGraphic : MonoBehaviour {
private Material m_Material;
[Range(0f, 1f)]
@vml-rmott
vml-rmott / tmux-shortcuts.md
Last active August 9, 2017 18:16 — forked from jkuchar/tmux-shortcuts.md
TMUX for dummies

TMUX

Start it using

command what it does?
tmux Starts new tmux session
tmux attach attaches to last openned tmux session

When it is running

#!/bin/bash
# usage: drupal-quick-dump database (assumes use of .my.cnf)
DB="$1"
DATE=`date +%Y%m%d`
# Dump Structure
echo "Starting to dump the table structure."
TABLES=`mysql --skip-column-names -e 'show tables' ${DB}`
mysqldump --complete-insert --disable-keys --single-transaction --no-data ${DB} ${TABLES} > ${DB}.${DATE}.sql
@vml-rmott
vml-rmott / DefaultItemCursorAdapter.java
Last active August 29, 2015 14:11
ResourceCursorAdapter with a configurable initial default value
package com.vml.example;
import android.content.Context;
import android.database.Cursor;
import android.support.v4.widget.ResourceCursorAdapter;
import android.view.View;
import android.view.ViewGroup;
/**
* Ryan Mott - VML, Inc.
@vml-rmott
vml-rmott / move-windows.scpt
Created September 25, 2014 18:21
Detect and move off-screen windows back within the desktop bounds. Forked from http://snipplr.com/view/8645/gather-windows/ by bradchoate to add multiple display support.
#!/usr/bin/osascript
-- ryan mott
-- forked from bradchoate http://snipplr.com/view/8645/gather-windows/
tell application "Finder"
-- get desktop dimensions (dw = desktop width; dh = desktop height)
set db to bounds of window of desktop
-- min width and height can be less than zero when multiple monitors arranged
package com.example;
import android.content.Context;
import android.database.Cursor;
import android.app.Fragment;
import android.app.FragmentManager;
import android.support.v13.app.FragmentStatePagerAdapter;
import android.util.SparseIntArray;
import android.view.ViewGroup;