This file contains hidden or 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 http = require('http'), | |
sys = require('sys'), | |
fs = require('fs'), | |
io = require('socket.io'); | |
var server = http.createServer(function(request, response) { | |
response.writeHead(200, { | |
'Content-Type': 'text/html' | |
}); | |
This file contains hidden or 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'), | |
form = require('connect-form'), | |
fs = require('fs'), | |
util = require('util'); | |
var app = express.createServer( | |
form({keepExtensions: true}) | |
); | |
// switch between development and production like this: |
This file contains hidden or 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'), | |
form = require('connect-form'), | |
fs = require('fs'), | |
util = require('util'); | |
var app = express.createServer( | |
form({keepExtensions: true}) | |
); | |
// switch between development and production like this: |
This file contains hidden or 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.createServer(); | |
app.configure('development', function () { | |
app.use(express.logger()); | |
app.use(express.errorHandler({ | |
dumpExceptions: true, | |
showStack: true | |
})); |
This file contains hidden or 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
// database.js | |
sys = require('sys'); | |
var mongo = require('./lib/node-mongodb-native/lib/mongodb'), | |
Connection = mongo.Connection, | |
Server = mongo.Server, | |
BSON = mongo.BSONNative; | |
var host = process.env['MONGO_NODE_DRIVER_HOST'] != null ? process.env['MONGO_NODE_DRIVER_HOST'] : 'localhost'; | |
var port = process.env['MONGO_NODE_DRIVER_PORT'] != null ? process.env['MONGO_NODE_DRIVER_PORT'] : Connection.DEFAULT_PORT; |
This file contains hidden or 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.createServer(); | |
app.configure('development', function () { | |
app.use(express.logger()); | |
app.use(express.errorHandler({ | |
dumpExceptions: true, | |
showStack: true | |
})); |
This file contains hidden or 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
-- Add Portable software to your msysgit-PATH -- | |
If you like to work with your *nix shell even under Windows, you'll | |
likely use the git-bash provided by msysgit a lot. | |
A problem might be, that you don't have your tools in the PATH of that | |
shell and therefore can't use them. Those tools might be on the same | |
USB-drive as the git-shell, so you would have to adjust the PATH | |
(if you're allowed to) every time the drive-letter changes. |
This file contains hidden or 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 mod = {}; | |
mod.AuthCtrl = [ | |
'$scope', 'requests401', '$http', 'Ping', '$location', function($scope, requests401, $http, Ping, $location) { | |
var fadespeed = 300; | |
$scope.user = { | |
"username": "test", | |
"password": "test" | |
}; |
This file contains hidden or 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
#!/usr/bin/env sh | |
VBOX_LATEST_VERSION=$(curl http://download.virtualbox.org/virtualbox/LATEST.TXT) | |
wget -c http://download.virtualbox.org/virtualbox/${VBOX_LATEST_VERSION}/VBoxGuestAdditions_${VBOX_LATEST_VERSION}.iso -O /tmp/VBoxGuestAdditions_${VBOX_LATEST_VERSION}.iso | |
sudo mkdir -p /media/guestadditions ; sudo mount -o loop /tmp/VBoxGuestAdditions_${VBOX_LATEST_VERSION}.iso /media/guestadditions | |
sudo /media/guestadditions/VBoxLinuxAdditions.run | |
sudo umount /media/guestadditions && sudo rm -rf /tmp/VBoxGuestAdditions_$VBOX_VERSION.iso /media/guestadditions | |
echo 'You may safely ignore the message that reads: "Could not find the X.Org or XFree86 Window System."' |
This file contains hidden or 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
# Cookbook Name:: mongodb | |
# Recipe:: default | |
case node['platform'] | |
when "ubuntu" | |
execute "apt-get update" do | |
action :nothing | |
end | |
execute "add gpg key" do |
OlderNewer