0.0.217 • Published 5 years ago
residence v0.0.217
Residence
Allows you find a root of a project given current working directory (process.cwd()
)
Examples
Looking for the NPM project root, by looking for package.json
import * as residence from 'residence';
const rootPath = residence.findProjectRoot(process.cwd());
// root is either null or a project root path, found by looking for the first package.json file
Looking for a project root, by looking for another file
import * as residence from 'residence';
const rootPath = residence.findRootDir(process.cwd(), '.nlu.json');
// walks up the fs towards '/' and returns the path when it finds the first .nlu.json file
// returns null otherwise.
0.0.217
5 years ago
0.0.216
5 years ago
0.0.215
6 years ago
0.0.214
6 years ago
0.0.213
6 years ago
0.0.212
6 years ago
0.0.211
6 years ago
0.0.210
6 years ago
0.0.209
6 years ago
0.0.208
6 years ago
0.0.207
6 years ago
0.0.206
7 years ago
0.0.205
7 years ago
0.0.204
7 years ago
0.0.203
7 years ago
0.0.202
7 years ago
0.0.201
7 years ago
0.0.1
8 years ago