Skip to content

Instantly share code, notes, and snippets.

@hoolymama
hoolymama / itstat_getres.sh
Created July 4, 2013 22:41
process output from itstat (sony)
# "ls *.JPG | itstat" gives the following output:
#
# File: DSCN0159.JPG
# Resolution: 2560 x 1920
# Channels: 10
# Channel Types: RGB with Alpha
# Bit Depth: 8
#
# File: DSCN0160.JPG
@hoolymama
hoolymama / MayaUpdateKLCommand.py
Created February 4, 2015 02:24
ST3 Plugin to update current file's KL code in Maya
import re, time, sys
import textwrap
from telnetlib import Telnet
import sublime, sublime_plugin
class maya_update_klCommand(sublime_plugin.TextCommand):
'''
ST3 Plugin to update current file's KL code in Maya
This is achieved by preparing and sending python
window.resolveLocalFileSystemURL(
imageUri,
function(fileEntry){
newFileName = Math.random().toString(36).substring(7) + "." + imageUri.split('.').pop();
window.resolveLocalFileSystemURL(cordova.file.dataDirectory,
function(dirEntry) {
fileEntry.moveTo(dirEntry, newFileName, successfn, failfn);
},
failfn);
@hoolymama
hoolymama / App.js
Last active March 18, 2024 09:15
Provide runtime environment to app made with create-react-app
import React, { Component } from "react";
import Navigation from "./Navigation";
import withConfig from "./withConfig";
class App extends Component {
componentWillMount() {
console.log(this.props.config);
}