Skip to content

Commit

Permalink
Add gently support
Browse files Browse the repository at this point in the history
  • Loading branch information
agnoster committed Oct 10, 2012
1 parent 43a24ca commit 2258c7f
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 1 deletion.
3 changes: 3 additions & 0 deletions lib/cli.js
@@ -1,3 +1,6 @@
// Gently, see https://github.com/felixge/node-gently#gentlyhijackrealrequire
if (global.GENTLY) require = GENTLY.hijack(require)

var literapi = require('./')
, optimist = require('optimist')

Expand Down
3 changes: 3 additions & 0 deletions lib/index.js
@@ -1,3 +1,6 @@
// Gently, see https://github.com/felixge/node-gently#gentlyhijackrealrequire
if (global.GENTLY) require = GENTLY.hijack(require)

var fs = require('fs')
, async = require('async')
, debug = require('debug')('literapi')
Expand Down
3 changes: 3 additions & 0 deletions lib/plugins/debug.js
@@ -1,3 +1,6 @@
// Gently, see https://github.com/felixge/node-gently#gentlyhijackrealrequire
if (global.GENTLY) require = GENTLY.hijack(require)

module.exports = {
"document": function(doc, next) {
console("Document: ", doc)
Expand Down
3 changes: 3 additions & 0 deletions lib/plugins/http.js
@@ -1,3 +1,6 @@
// Gently, see https://github.com/felixge/node-gently#gentlyhijackrealrequire
if (global.GENTLY) require = GENTLY.hijack(require)

var request = require('request')

var requestRegex = /^(GET|PUT|POST|PATCH|DELETE|HEAD|OPTIONS|CONNECT)\s+(\/\S*)/
Expand Down
3 changes: 3 additions & 0 deletions lib/plugins/markdown.js
@@ -1,3 +1,6 @@
// Gently, see https://github.com/felixge/node-gently#gentlyhijackrealrequire
if (global.GENTLY) require = GENTLY.hijack(require)

var Markdownstream = require('markdownstream')
, debug = require('debug')('literapi:plugin:markdown')

Expand Down
3 changes: 3 additions & 0 deletions lib/plugins/readfile.js
@@ -1,3 +1,6 @@
// Gently, see https://github.com/felixge/node-gently#gentlyhijackrealrequire
if (global.GENTLY) require = GENTLY.hijack(require)

var fs = require('fs')
, debug = require('debug')('literapi:plugin:readfile')

Expand Down
3 changes: 2 additions & 1 deletion package.json
Expand Up @@ -35,7 +35,8 @@
"async": "~0.1.22"
},
"devDependencies": {
"express": "~3.0"
"express": "~3.0",
"gently": "~0.9.2"
},
"engines": {
"node": ">0.6.0",
Expand Down

0 comments on commit 2258c7f

Please sign in to comment.