TranslationAuditor
Pennington.TranslationAudit
IBuildAuditor that pairs each default-locale page with its translations in every other configured locale and classifies the pair as Up-to-date, Outdated (translation predates source's last commit) or Missing (no translation file).
Properties
Codestring- Stable identifier surfaced on every diagnostic this auditor emits.
Constructors
TranslationAuditor
#public TranslationAuditor(TranslationAuditOptions options, IGitHistoryReader git)
Wires the auditor to its options and git history reader.
Parameters
optionsTranslationAuditOptionsgitIGitHistoryReader
Methods
AuditAsync
#public Task<IReadOnlyList<BuildDiagnostic>> AuditAsync(BuildAuditContext context, CancellationToken cancellationToken)
Runs the auditor against context and returns its diagnostics.
Parameters
contextBuildAuditContextcancellationTokenCancellationToken
Returns
Task<IReadOnlyList<BuildDiagnostic>>Pennington.TranslationAudit.TranslationAuditor
namespace Pennington.TranslationAudit;
/// IBuildAuditor that pairs each default-locale page with its translations in every other configured locale and classifies the pair as Up-to-date, Outdated (translation predates source's last commit) or Missing (no translation file).
public class TranslationAuditor
{
/// Runs the auditor against context and returns its diagnostics.
public Task<IReadOnlyList<BuildDiagnostic>> AuditAsync(BuildAuditContext context, CancellationToken cancellationToken)
;
/// Stable identifier surfaced on every diagnostic this auditor emits.
public string Code { get; }
/// Wires the auditor to its options and git history reader.
public TranslationAuditor(TranslationAuditOptions options, IGitHistoryReader git)
;
}