UNPKG

@git.zone/cli

Version:

A comprehensive CLI tool for enhancing and managing local development workflows with gitzone utilities, focusing on project setup, version control, code formatting, and template management.

22 lines (21 loc) 1.03 kB
import { FormatContext } from './classes.formatcontext.js'; import type { IPlannedChange } from './interfaces.format.js'; import { Project } from '../classes.project.js'; import { ChangeCache } from './classes.changecache.js'; export declare abstract class BaseFormatter { protected context: FormatContext; protected project: Project; protected cache: ChangeCache; protected stats: any; constructor(context: FormatContext, project: Project); abstract get name(): string; abstract analyze(): Promise<IPlannedChange[]>; abstract applyChange(change: IPlannedChange): Promise<void>; execute(changes: IPlannedChange[]): Promise<void>; protected preExecute(): Promise<void>; protected postExecute(): Promise<void>; protected modifyFile(filepath: string, content: string): Promise<void>; protected createFile(filepath: string, content: string): Promise<void>; protected deleteFile(filepath: string): Promise<void>; protected shouldProcessFile(filepath: string): Promise<boolean>; }