UNPKG

sf-decomposer

Version:

Decompose Salesforce metadata into granular, VCS-friendly files; recompose for deployment.

27 lines (26 loc) 1.58 kB
import { MetaAttributes } from '../helpers/types.js'; export type ParentXmlFile = { /** Absolute path to the parent metadata XML file. */ filePath: string; /** Component identity, used to resolve component-scope config overrides. */ fullName: string; }; /** * One-level `readdir` of `dir`, filtered to files ending in `.${metaSuffix}-meta.xml`. * Same glob `perFileHandler` (`decomposeFileHandler.ts`) already uses. Returns `[]` * when `dir` doesn't exist, matching the swallow-errors convention used elsewhere for * directory walks (e.g. `getPackageDirectories.searchRecursively`). */ export declare function listSuffixFiles(dir: string, metaSuffix: string): Promise<ParentXmlFile[]>; /** * List every parent metadata XML file on disk for a resolved metadata type, mirroring the file * shapes `decomposeFileHandler.ts` discovers during a real decompose — but read-only, and without * the override-driven `perFileHandler` vs. whole-directory split (that split only changes *how* * real decompose disassembles a file, not *which* files exist; every file this function finds * would eventually be visited by a real decompose run one way or another). * * `fullName` on each result is the same component identity `decomposeFileHandler.ts` uses to * resolve component-scope config overrides (directory basename for `strictDirectoryName`/ * `folderType` types, filename minus the meta suffix ending otherwise). */ export declare function listParentXmlFilesForType(metaAttributes: MetaAttributes, manifestXmlPaths?: Set<string>): Promise<ParentXmlFile[]>;