beforeRunningCommand saveActiveFile command [[ ! -z $TM_OBJJ_MASTER_FILE ]] && INDEXFILE="$TM_OBJJ_MASTER_FILE" [[ ! -z $TM_PROJECT_DIRECTORY ]] && INDEXFILE="$TM_PROJECT_DIRECTORY/index.html" [[ ! -z $TM_DIRECTORY ]] && INDEXFILE="$TM_DIRECTORY/index.html" if [ -z "$INDEXFILE" ]; then D=`dirname "$TM_FILEPATH"` while [ -z `find "$D" -name index.html` ]; do D=`dirname "$D"` done INDEXFILE="${D}/index.html" fi [[ -z $INDEXFILE ]] && echo "No start file found. Please set the shell variable 'OBJJ_MASTER_FILE'" && exit 206 cat <<-HTML <script type="text/javascript" charset="utf-8"> try { if (TextMate.system("", function (task) { })) { var __TM_confirm_Status; alert = function(s){TextMate.system("\"$DIALOG\" -e -p '{messageTitle=\"JavaScript\";informativeText=\""+s.toString().replace(/\x27/g,"’").replace(/\"/g,'\\\"')+"\";}'",null);}; confirm = function(s){TextMate.system("\"$DIALOG\" -e -p '{messageTitle=\"JavaScript\";informativeText=\""+s.toString().replace(/\x27/g,"’").replace(/\"/g,'\\\"')+"\";buttonTitles=(\"OK\",\"Cancel\");}'",null).onreadoutput=function(s){__TM_confirm_Status = s != 1;};return(__TM_confirm_Status)}; } } catch(e) {} </script> <base href="file://${INDEXFILE// /%20}"> HTML cat "$INDEXFILE" [[ ! -z $(grep 'objj_exception_setOutputStream' "$INDEXFILE") ]] && exit 205 cat <<-JS <script type="text/javascript" charset="utf-8"> objj_exception_setOutputStream(function(aString) { console.log(aString);alert(aString) }); </script> JS exit 205 input none keyEquivalent @r name Run output showAsTooltip scope source.js.objj uuid 0C55A19B-3B2D-418F-B7FD-7E64B736F379