Skip to content

Instantly share code, notes, and snippets.

View ndastur's full-sized avatar

Neville Dastur ndastur

  • Clinical Software Solutions
View GitHub Profile
@ndastur
ndastur / events.js
Created June 4, 2013 14:36
Common JS module to help with handling Titanium Appcelerator events.
/*
* Common JS module to help with Ti Event listener handling.
* @author Neville Dastur
* @url http://www.clinsoftsolutions.com
*
* Acknowledgements go to https://gist.github.com/minhnc/2333095 as my starting point on this
*/
exports.registerEventListener = function(obj, event, callabck) {
if ( typeof obj._eventListeners == 'undefined' ) {
@ndastur
ndastur / gist:5420989
Last active December 16, 2015 10:38
Build offline docs for Titanium Appcelerator on Mac OSX
#! /bin/sh
#
# This file is based on https://gist.github.com/eric-hu/4952258
# which runs on linux
#
# Run this from the folder you want to be the parent of your docs
# By default, generated docs go into
# titanium_mobile/dist/apidoc/ti_mobile_docs/
#
# This can be changed below
/*
* V4L2 video capture example
*
* This program can be used and distributed without restrictions.
*
* This program is provided with the V4L2 API
* see http://linuxtv.org/docs.php for more information
*/
#include <stdio.h>
@ndastur
ndastur / buildModForMe.bash
Created January 18, 2013 21:33
I got fed up of the fact that once I released a module into the Appcelerator marketplace I could not use it myself without getting Un-licensed module errors. So this script, modified the GUID and re-builds the module, then installs to the SDK location. Note that in more recent installs the SDK is located in home. Just change the line at 37,38 an…
#!/bin/bash
# make a backup file with the module GUID
# just in case there is some funny script error
# it will be available here
if [ ! -e "./moduleGUID_Backup.txt" ]
then
grep -i guid manifest > ./moduleGUID_Backup.txt
fi