/*! * Copyright (c) Microsoft Corporation and contributors. All rights reserved. * Licensed under the MIT License. */ import type { ReleaseVersion } from "@fluid-tools/version-tools"; import { FluidRepo, type IFluidBuildConfig, Package } from "@fluidframework/build-tools"; import { type FlubConfig } from "../config.js"; import { Repository } from "./git.js"; /** * Represents a release version and its release date, if applicable. * * @internal */ export interface VersionDetails { /** * The version of the release. */ version: ReleaseVersion; /** * The date the version was released, if applicable. */ date?: Date; } /** * Represents the different types of release groups supported by the build tools. Each of these groups should be defined * in the fluid-build section of the root package.json. * @deprecated should switch to ReleaseGroup. Currently the only difference is "azure" not in ReleaseGroup. */ export declare enum MonoRepoKind { Client = "client", Server = "server", Azure = "azure", BuildTools = "build-tools", GitRest = "gitrest", Historian = "historian" } /** * A type guard used to determine if a string is a MonoRepoKind. * @deprecated should switch to isReleaseGroup */ export declare function isMonoRepoKind(str: string | undefined): str is MonoRepoKind; /** * Context provides access to data about the Fluid repo, and exposes methods to interrogate the repo state. */ export declare class Context { readonly root: string; readonly repo: FluidRepo; readonly fullPackageMap: Map; readonly fluidBuildConfig: IFluidBuildConfig; readonly flubConfig: FlubConfig; private checkedIsGitRepo; constructor(root: string); /** * Returns the packages that belong to the specified release group. * * @param releaseGroup - The release group to filter by * @returns An array of packages that belong to the release group */ packagesInReleaseGroup(releaseGroup: string): Package[]; /** * Returns the packages that do not belong to the specified release group. * * @param releaseGroup - The release group or package to filter by. * @returns An array of packages that do not belong to the release group. */ packagesNotInReleaseGroup(releaseGroup: string | Package): Package[]; /** * Get all the packages not associated with a release group * @returns An array of packages in the repo that are not associated with a release group. */ get independentPackages(): Package[]; /** * Get all the packages. * @returns An array of all packages in the repo. */ get packages(): Package[]; /** * Gets the version for a package or release group. * * @returns A version string. * */ getVersion(key: string): string; private _gitRepository; getGitRepository(): Promise; } //# sourceMappingURL=context.d.ts.map