Files
velum-raycast/src/project-mapping-actions.ts

13 lines
657 B
TypeScript

import { listRuns } from "./lib/velum-project";
import { reviseProjectRun } from "./lib/project-revision";
import { depseudonymizeDocument } from "./velum";
/** Release the whole alias group and update the latest saved project files. */
export async function releaseProjectMapping(projectPath: string, placeholder: string) {
const latest = (await listRuns(projectPath))[0];
if (!latest) throw new Error("Projektstand nicht gefunden.");
return reviseProjectRun({ previous: latest.run, previousDirectory: latest.directory,
release: new Set([placeholder]), merges: {}, rewriteDocument: depseudonymizeDocument,
useCurrentInPlaceFiles: true });
}