This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//windows | |
[ | |
//ctrl+i to indent lines properly like in eclipse (Windows) | |
{ "keys": ["ctrl+i"], "command": "reindent" } | |
] | |
//macosx | |
[ | |
//ctrl+i to indent lines properly like in eclipse (Mac OSX) | |
{ "keys": ["super+i"], "command": "reindent" } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var q= function(s){ return document.getElementById(s) } | |
function send(){ | |
var input = q('text'); | |
socket.send(input.value); | |
input.value = ''; | |
} | |
var socket = new io.Socket(null, { | |
port: 8001, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ifconfig | grep usb -1 | grep 'inet addr:' | cut -d: -f2 | awk '{ print $1}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var express = require('express'); | |
var app = express(); | |
var path = require('path'); | |
app.get('/', function(req, res) { | |
res.sendfile('index.html'); | |
}); | |
app.use(express.static(path.join(__dirname, '/'))); |