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
#!/bin/sh | |
# | |
# init.d script with LSB support. | |
# | |
# Copyright (c) 2007 Javier Fernandez-Sanguino <[email protected]> | |
# | |
# This is free software; you may redistribute it and/or modify | |
# it under the terms of the GNU General Public License as | |
# published by the Free Software Foundation; either version 2, | |
# or (at your option) any later version. |
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
sudo apt-get install libssl-dev build-essential |
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
"use strict"; | |
var express = require('express'); | |
var app = express(); | |
var jsDAV = require("jsDAV/lib/jsdav"); | |
app.use(function (req, res, next) { | |
if (req.url.search(/^\/webdav/) >= 0) { | |
jsDAV.mount({ | |
node: __dirname + "/data", | |
mount: "/webdav", |
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
'use strict'; | |
var fs = require('fs') | |
, marked = require('marked') | |
; | |
module.exports = function (options) { | |
if (!options) { | |
options = {}; | |
} |
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
#!/bin/sh | |
sudo add-apt-repository ppa:fkrull/deadsnakes | |
sudo apt-get update | |
sudo apt-get install python2.5 python2.5-dev libxml2 libxml2-dev libxslt libxslt1-dev build-essential | |
wget http://lxml.de/files/lxml-2.1.1.tgz | |
cd lxml-2.1.1/ | |
sudo python2.5 setup.py build | |
sudo python2.5 setup.py install |
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
#!/usr/bin/env node | |
process.stdin.resume(); | |
process.stdin.setEncoding('utf8'); | |
var remainder = '' | |
process.stdin.on('data', function (chunk) { | |
var lines = chunk.toString().split('\n'); | |
lines.unshift(remainder + lines.shift()); | |
remainder = lines.pop(); |
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 http = require('http'); | |
var server = http.createServer(function (req, res) { | |
var nb_chunk = 0; | |
res.write('Shifting ...'); | |
req.pause(); | |
req.setEncoding('utf-8'); | |
req.on('data', function(chunk) { | |
nb_chunk++; | |
res.write('Request Chunked #'+nb_chunk+' : '+chunk[0]+chunk[1]+chunk[2]+'\n'); |
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
[branch "master"] | |
remote=origin | |
merge=refs/heads/master | |
[remote "origin"] | |
url = http://github.com/touv/node-xml-mapping.git | |
fetch = +refs/heads/*:refs/remotes/origin/* |
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
#!/bin/sh | |
mkdir -p ./bin | |
mkdir -p ./etc/init.d | |
mkdir -p ./etc/default/ | |
mkdir -p ./var/log/express | |
mkdir -p ./var/run | |
touch ./etc/init.d/express | |
touch ./etc/default/express |
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
#!/bin/sh | |
##3.5...10...15...20...25...30...35...40...45...50...55...60...65...70...75...80 | |
## | |
## Debian / Linux / Ubuntu / LSB | |
## Startup script for Express / Node.js application with the forever module | |
## | |
## | |
## A modification of "init.d.lsb.ex" by Nicolas Thouvenin | |
## | |
## |