npm-pkgbuild
Version:
create ArchLinux, RPM and Debian packages from npm packages
31 lines (27 loc) • 771 B
JavaScript
import { ContentEntry, CollectionEntry } from "content-entry";
/**
* Source of package content.
* @property {string} dir
* @property {Transformer[]} transformer
*/
export class ContentProvider {
transformers = [];
entryProperties;
directoryProperties;
dir;
constructor(definitions, entryProperties, directoryProperties) {
this.entryProperties = entryProperties;
this.directoryProperties = directoryProperties;
if (this.entryProperties?.destination) {
this.directoryProperties = {
...this.directoryProperties,
destination: this.entryProperties?.destination
};
}
}
/**
* List all entries.
* @return {AsyncIterable<ContentEntry|CollectionEntry>} all entries
*/
async *[Symbol.asyncIterator]() {}
}