Kind: Service
Source: Pams/Logic/Pams.Email/Pams.Email.csproj (line 1)
Part of: Pams
NuGet package dependency
Pams.Email is a legacy-format project that declares NuGet package dependencies for the email component. It participates in the PAMS build by restoring referenced packages before the email project is compiled and consumed by other applications.
Diagram
mermaidsequenceDiagram participant Developer participant Build as Build Process participant Email as Pams.Email.csproj participant NuGet participant App as PAMS Application Developer->>Build: Run restore and build Build->>Email: Read project dependencies Email->>NuGet: Request referenced packages NuGet-->>Build: Restore packages Build->>Email: Compile email project Email-->>App: Provide compiled email component
Usage
tsimport { execFile } from "node:child_process";
import { promisify } from "node:util";
const execFileAsync = promisify(execFile);
async function restoreEmailProject() {
const projectPath = "Pams/Logic/Pams.Email/Pams.Email.csproj";
await execFileAsync("dotnet", ["restore", projectPath]);
await execFileAsync("dotnet", ["build", projectPath, "--no-restore"]);
console.log("Pams.Email dependencies restored and project built.");
}
restoreEmailProject().catch((error) => {
console.error("Failed to build Pams.Email:", error);
process.exitCode = 1;
});
AI Coding Instructions
- Keep NuGet package references in
Pams.Email.csprojaligned with the legacy project format already used by the project. - Run
dotnet restorebefore building when package references or package sources change. - Avoid changing package versions without checking projects that reference the compiled
Pams.Emailoutput. - Update package references in the project file rather than adding JavaScript or TypeScript package management files to this .NET project.
Was this page helpful?