/** * Forgejo `uses:` action-reference resolver. * * GitHub Actions resolves a bare `uses: actions/checkout@v4` against the GitHub * Marketplace. Forgejo / Codeberg / Gitea runners have no Marketplace, so such a * ref must be rewritten to a form their runner can fetch — a full repository URL, * or a path under a configured actions root that mirrors the action. * * The resolver rewrites a built-in set of common actions and reports anything it * can't place as a diagnostic (never dropping or silently passing it through). */ /** * Default actions root. `code.forgejo.org` hosts the Forgejo `actions/*` mirror * (checkout, setup-*, cache, upload/download-artifact, …). Override per project * via `forgejo.actionsRoot` in `chant.config.ts`. */ export declare const DEFAULT_ACTIONS_ROOT = "https://code.forgejo.org"; /** * Where a known action resolves: * - `mirror`: `/` — follows the configured actions root. * - `url`: an absolute base URL — independent of the actions root (used for * actions not carried by the Forgejo mirror, e.g. `docker/*`). */ export type ActionTarget = { kind: "mirror"; repo: string; } | { kind: "url"; url: string; }; /** Built-in mapping of GitHub action `owner/repo` → Forgejo-resolvable target. */ export declare const KNOWN_ACTIONS: Record; export interface ActionResolveOptions { /** Base for `mirror` targets; defaults to {@link DEFAULT_ACTIONS_ROOT}. */ actionsRoot?: string; /** Mapping table to use; defaults to {@link KNOWN_ACTIONS}. */ known?: Record; } export interface ActionResolveResult { /** The rewritten (or unchanged) `uses:` ref. */ rewritten: string; /** Set when the ref could not be resolved — surfaced as a build warning. */ warning?: string; } /** * Resolve a single `uses:` action ref to a Forgejo-resolvable form. */ export declare function resolveActionRef(ref: string, options?: ActionResolveOptions): ActionResolveResult; //# sourceMappingURL=actions.d.ts.map