UNPKG

@schemifyjs/core

Version:

Core module of the SchemifyJS CLI. Provides reusable functions such as scaffolding, template handling, and general utilities.

13 lines (12 loc) 369 B
import fs from 'fs-extra'; export class ProjectNotFoundError extends Error { constructor(projectPath) { super(`No project was found at: ${projectPath}`); this.name = 'ProjectNotFoundError'; } static validate(projectPath) { if (!fs.existsSync(projectPath)) { throw new ProjectNotFoundError(projectPath); } } }