list-projects
TypeScript icon, indicating that this package has built-in type declarations

1.0.1 • Public • Published

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.

Readme

Keywords

none

Package Sidebar

Install

npm i list-projects

Weekly Downloads

2

Version

1.0.1

License

MIT

Unpacked Size

6.1 kB

Total Files

6

Last publish

Collaborators

  • atacheny
  • talinmatteson