import { ReleaseType } from 'semver'; /** * Determines whether the changelog should be updated based on the provided release type and optional tag name. * * The changelog is updated if: * - The `releaseType` exists in `releaseTypesToUpdateChangelogList` and the `tagName` exists in `tagNamesToUpdateChangelog`, or * - The `releaseType` is considered valid according to the `valid` function. * * @param releaseType - The type of the release to evaluate. * @param tagName - (Optional) The tag name associated with the release. * @returns `true` if the changelog should be updated, otherwise `false`. */ export declare const shouldUpdateChangelog: (releaseType: ReleaseType, tagName?: string) => string | true | null; /** * Validates and determines the next version for a release based on the current version, release type, and optional tag name. * * - If `releaseType` is a valid semantic version, checks that it is greater than `oldVersion`. * - If `releaseType` is a standard release type (e.g., "major", "minor", "patch"), validates it against supported types. * - Optionally validates the provided `tagName` against supported tag names. * - Throws an error with a descriptive message if validation fails. * * @param oldVersion - The current version string (semver). * @param releaseType - The release type or a specific version string. * @param tagName - (Optional) The release tag to validate. * @returns A tuple containing the old version and the new version if a specific version is provided. * @throws {Error} If the new version is not greater than the old version, or if the release type or tag name is invalid. */ export declare const validateVersion: (oldVersion: string, releaseType: ReleaseType, tagName?: string) => string[] | undefined; /** * Organizes raw commit messages into a structured changelog and determines the release type. * * This function processes a string of commit messages, filters unreleased changes, * categorizes each commit by its type (e.g., feature, fix, breaking change), and * generates a formatted changelog section. It also determines the appropriate release * type (e.g., major, minor, patch) based on the categorized changes. * * @param commits - A string containing commit messages, typically separated by newlines. * @param originUrl - The origin URL of the repository, used to generate links for pull requests or commits. * @returns An object containing the generated changelog section and the determined release type. */ export declare const organizeCommitsToChangelog: (commits: string, originUrl: string) => { changelog: string; releaseType: ReleaseType; };