Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
return async (context: Task.Context) => {
profile = postProcessInstallProfile(mc, profile);
const parsedLibs = Version.resolveLibraries([...profile.libraries, ...versionJson.libraries]);
await context.execute(Installer.installLibrariesDirectTask(parsedLibs, mc, {
...installLibOption,
libraryHost: installLibOption.libraryHost ? (l) => {
if (l.artifactId === "forge" && l.groupId === "net.minecraftforge") {
return `file://${mc.getLibraryByPath(l.path)}`;
}
return installLibOption.libraryHost!(l);
} : undefined,
}));
await context.execute(async function postProcessing(ctx) {
ctx.update(0, profile.processors.length);
let i = 0;
const errs: Error[] = [];
for (const proc of profile.processors) {
try {
await postProcess(mc, proc, java);