1 | path = require 'path'
|
2 | fs = require 'fs'
|
3 | gulpfile = require './gulpfile'
|
4 |
|
5 | parent = path.dirname gulpfile.filename
|
6 | filename = path.resolve parent, './package.json'
|
7 |
|
8 | while not (fs.existsSync(filename) and fs.statSync(filename).isFile())
|
9 | parent = path.dirname parent
|
10 | filename = path.resolve parent, './package.json'
|
11 |
|
12 | module.exports = require filename |
\ | No newline at end of file |