UNPKG

changelog-guru

Version:
27 lines (26 loc) 1.25 kB
import { Dependencies, IChange, Restriction } from 'package-json-helper/types/package'; import { Exclusion } from './Config.js'; import { IAuthor } from './entities/Author.js'; import { ICommit } from './entities/Commit.js'; import { ChangeLevel } from './entities/Entity.js'; import { ISection, ISectionOptions } from './entities/Section.js'; import { IRule, IRuleContext } from './rules/BaseRule.js'; export default class State implements IRuleContext { #private; readonly currentLicense: string; readonly hasChangedLicense: boolean; readonly previousLicense?: string; constructor(currentLicense: string, previousLicense?: string); get sections(): ISection[]; get authors(): IAuthor[]; get commits(): ICommit[]; get changesLevels(): [number, number, number]; addChanges(type: Dependencies | Restriction, changes: IChange[]): void; addCommit(commit: ICommit): void; addSection(options: ISectionOptions): ISection | undefined; findSection(name: string): ISection | undefined; getChanges(type: Dependencies | Restriction): IChange[]; ignore(exclusions: [Exclusion, string[]][]): void; modify(rules: IRule[]): void; updateCommitsChangeLevel(types: [string, ChangeLevel][]): void; }