UNPKG

@atomist/atomist-sdm

Version:

Atomist SDM to deliver our own projects

29 lines (28 loc) 1.08 kB
import { Project } from "@atomist/automation-client"; import { PushAwareParametersInvocation } from "@atomist/sdm"; import { RequestedCommitParameters } from "./RequestedCommitParameters"; /** * Default glob pattern matches all C family languages */ export declare class AddHeaderParameters extends RequestedCommitParameters { glob: string; excludeGlob: string; onlyChangedFiles: boolean; license: "apache"; constructor(); readonly header: string; } export declare function apacheHeader(): string; /** * CodeTransform that upserts headers into files per [[AddHeaderParameters]]. */ export declare function addHeaderTransform(p: Project, ci: PushAwareParametersInvocation<AddHeaderParameters>): Promise<Project>; /** * Add or replace begining empty lines and any header comment in * `content` with `header`. * * @param header header that should be upserted into content * @param content current content to be updated * @return updated content that contains header */ export declare function upsertHeader(header: string, content: string): string;