Skip to content

Instantly share code, notes, and snippets.

View kodamirmo's full-sized avatar
🏠
Working from home

Irving Emmanuel González kodamirmo

🏠
Working from home
  • Translate2Me
  • Mexico DF
View GitHub Profile
@panchicore
panchicore / bash
Created October 7, 2011 00:25
solve perl: warning: Setting locale failed.
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LC_CTYPE = "UTF-8",
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
@mauropm
mauropm / app.js
Created January 3, 2012 21:25
Image caching in Appcelerator
var win = Ti.UI.createWindow({
backgroundColor: 'white'
});
var imgTableLoco = Ti.UI.createTableView({
width: 270,
height: 290,
top: 0,
backgroundColor: 'black'
});
@dealforest
dealforest / AES256Cipher.java
Created March 1, 2012 13:39
AES256 encryption on Android
package net.dealforest.sample.crypt;
import javax.crypto.BadPaddingException;
import javax.crypto.Cipher;
import javax.crypto.IllegalBlockSizeException;
import javax.crypto.NoSuchPaddingException;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.SecretKeySpec;
import java.security.InvalidKeyException;
@paolorossi
paolorossi / html5-video-streamer.js
Created March 7, 2012 13:21
Node.js HTML5 video streamer
/*
* Inspired by: http://stackoverflow.com/questions/4360060/video-streaming-with-html-5-via-node-js
*/
var http = require('http'),
fs = require('fs'),
util = require('util');
http.createServer(function (req, res) {
var path = 'video.mp4';
@ThomasLomas
ThomasLomas / meteorhelper.js
Created May 9, 2012 16:45
Meteor And Helper
////////// Helpers for in-place editing //////////
// Returns an event_map key for attaching "ok/cancel" events to
// a text input (given by selector)
var okcancel_events = function (selector) {
return 'keyup '+selector+', keydown '+selector+', focusout '+selector;
};
// Creates an event handler for interpreting "escape", "return", and "blur"
// on a text field and calling "ok" or "cancel" callbacks.
@mattberg
mattberg / Parse.js
Created September 21, 2012 14:24
Simple Parse REST API module for Titanium
var baseUrl = 'https://api.parse.com/1',
appId = 'XXXXXXXXXXXXXXX',
apiKey = 'XXXXXXXXXXXXXX'; // make sure to use the REST API Key
var _register = function(params, lambda, lambdaerror) {
var method = 'POST',
url = baseUrl + '/installations',
payload = (params) ? JSON.stringify(params) : '';
_helper(url, method, payload, function(data, status) {
@dariocravero
dariocravero / README.md
Created October 20, 2012 05:25
Save files in Meteor

Create a Meteor app and put the client_/server_ files in a client/server directories. Also, create a public dir to save the uploaded files.

@cprieto
cprieto / gist:4016672
Created November 5, 2012 11:08
Capitulo 2.5 - Runtime y lenguaje

Capitulo 2.5

Intro

Bien, estaba leyendo tus notas del capitulo 3 y muchas cosas me parecieron interesantes, mas que todo algunas preguntas y comentarios del capitulo, antes que ahondemos un poco en las preguntas y comentarios de ese capitulo queria profundizar un poco en algo clave e importante acerca de la framework, es tan importante que comprendiendo las diferencias y el porque veras mas claro la evolucion y avance del lenguaje como tal. Es tan crucial que a muchos programadores 'experimentados' al entrevistarlos y preguntarles acerca de ello demuestran no solo que no lo conocen si no que andan mas perdidos que el hijo de la llorona...

El runtime, el lenguaje y las librerias - Porque Microsoft nos complica la vida

La verdad, que muchos programadores contesten una pregunta tan simple como 'que versiones de la framework existen' y al mismo tiempo fallen al comentar 'que versiones del runtime existen' no es su culpa, si no de Microsoft y su equipo de marketing al confundir a millones de programado

@raulriera
raulriera / HorizontalTableView.js
Created January 24, 2013 12:37
Horizontal TableView for Titanium Appcelerator. This still needs some android love, trying to use an inverted tableview made the table impossible to scroll (on android)
function HorizontalTableView(options) {
// defaults params
var options = options || {};
options.width = options.width || Titanium.Platform.displayCaps.platformWidth;
options.height = options.height || Titanium.Platform.displayCaps.platformHeight;
var isAndroid = Ti.Platform.osname === 'android';
// On iOS we can do this, on Android there is some weird scrolling problems
// save a global reference to the tabgroup that can be
// accessed in any controller
Alloy.Globals.tabgroup = $.index;
$.index.setActiveTab(1));
$.index.open();