UNPKG

@softwareventures/maintain-project

Version:

Automatically create and maintain TypeScript projects with standard settings for Software Ventures Limited

19 lines 679 B
import { anyFn } from "@softwareventures/array"; import { projectFileExists } from "../project/file-exists.js"; import { writeLicense } from "./write.js"; export async function addMissingLicense(project) { return Promise.all([ projectFileExists(project, "LICENSE"), projectFileExists(project, "LICENSE.md"), projectFileExists(project, "LICENSE.txt") ]) .then(anyFn(exists => exists)) .then(exists => exists ? null : { type: "fs-stage-update", log: "docs(license): add missing LICENSE.md", apply: writeLicense(project) }); } //# sourceMappingURL=add-missing-license.js.map