1.0.1 • Published 5 years ago

list-projects v1.0.1

Weekly downloads
2
License
MIT
Repository
github
Last release
5 years ago

list-projects

Given a root path, recursively searches subdirectories and lists basic information about node projects

npm install list-projects

The only function is listProjects which returns an array of Project objects.

interface {
    path: string;
    packageName: string;
    dirName: string;
    gitDirName?: string;
}

If the project is contained in a folder containing a .git directory (a git repo) then the name of the repo directory will be included.

TypeScript:

import { listProjects, Project } from 'list-projects';

const projects: Project[] = listProjects('(some directory to recursively search for node projects)');

JavaScript:

const { listProjects } = require('list-projects');
const projects = listProjects('(some directory to recursively search for node projects)');

I'm open to extending this to return other information about the directory, adding flags/options, etc.

1.0.1

5 years ago

1.0.0

5 years ago