46 lines
		
	
	
		
			955 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
			
		
		
	
	
			46 lines
		
	
	
		
			955 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
export type IFormatOperation = {
 | 
						|
  id: string;
 | 
						|
  timestamp: number;
 | 
						|
  files: Array<{
 | 
						|
    path: string;
 | 
						|
    originalContent: string;
 | 
						|
    checksum: string;
 | 
						|
    permissions: string;
 | 
						|
  }>;
 | 
						|
  status: 'pending' | 'in-progress' | 'completed' | 'failed' | 'rolled-back';
 | 
						|
  error?: Error;
 | 
						|
};
 | 
						|
 | 
						|
export type IFormatPlan = {
 | 
						|
  summary: {
 | 
						|
    totalFiles: number;
 | 
						|
    filesAdded: number;
 | 
						|
    filesModified: number;
 | 
						|
    filesRemoved: number;
 | 
						|
    estimatedTime: number;
 | 
						|
  };
 | 
						|
  changes: Array<{
 | 
						|
    type: 'create' | 'modify' | 'delete';
 | 
						|
    path: string;
 | 
						|
    module: string;
 | 
						|
    description: string;
 | 
						|
    diff?: string;
 | 
						|
    size?: number;
 | 
						|
  }>;
 | 
						|
  warnings: Array<{
 | 
						|
    level: 'info' | 'warning' | 'error';
 | 
						|
    message: string;
 | 
						|
    module: string;
 | 
						|
  }>;
 | 
						|
};
 | 
						|
 | 
						|
export type IPlannedChange = {
 | 
						|
  type: 'create' | 'modify' | 'delete';
 | 
						|
  path: string;
 | 
						|
  module: string;
 | 
						|
  description: string;
 | 
						|
  content?: string; // For create/modify operations
 | 
						|
  diff?: string;
 | 
						|
  size?: number;
 | 
						|
};
 |