BlastMerge is a revolutionary file synchronization tool that uses intelligent iterative merging to unify multiple versions of files across repositories, directories, and codebases.
Unlike traditional diff tools, BlastMerge progressively merges file versions by finding the most similar pairs and resolving conflicts interactively, ultimately synchronizing entire file ecosystems into a single, unified version.
Key Features:
- Smart Discovery: Automatically finds all versions of a file across directories/repositories
- Hash-Based Grouping: Groups identical files and identifies unique versions
- Similarity Analysis: Calculates similarity scores between all version pairs
- Optimal Merge Order: Progressively merges the most similar versions first to minimize conflicts
- Interactive Resolution: Visual TUI for resolving conflicts block-by-block
- Cross-Repository Sync: Updates all file locations with the final merged result
BlastMerge is a file synchronization tool designed to unify multiple file versions across repositories, directories, and codebases using intelligent iterative merging. It automates the process of finding similar files, resolving conflicts progressively, and synchronizing all locations with a final merged version.
README
ktsu.BlastMerge
> Cross-repository file synchronization through intelligent iterative merging
Overview
BlastMerge is a revolutionary file synchronization tool that uses intelligent iterative merging to unify multiple versions of files across repositories, directories, and codebases. Unlike traditional diff tools, BlastMerge progressively merges file versions by finding the most similar pairs and resolving conflicts interactively, ultimately synchronizing entire file ecosystems into a single, unified version.
đ Iterative File Synchronization
The Problem
When working across multiple repositories, branches, or environments, the same files often diverge into multiple versions with overlapping changes. Traditional merge tools handle two-way merges, but when you have 3, 5, or 10+ versions of the same file scattered across different locations, manual synchronization becomes a nightmare.
The Solution: Iterative Merging
BlastMerge solves this by:
Smart Discovery: Automatically finds all versions of a file across directories/repositories
Hash-Based Grouping: Groups identical files and identifies unique versions
Similarity Analysis: Calculates similarity scores between all version pairs
Optimal Merge Order: Progressively merges the most similar versions first to minimize conflicts
Interactive Resolution: Visual TUI for resolving conflicts block-by-block
Cross-Repository Sync: Updates all file locations with the final merged result
Real-World Use Cases
Multi-Repository Synchronization: Sync the same configuration files across microservices
Branch Consolidation: Merge scattered feature branch changes before cleanup
Environment Alignment: Unify deployment scripts across dev/staging/prod environments
Code Migration: Consolidate similar files when merging codebases
Documentation Sync: Align README files across related projects
Features
đ Iterative Merging Engine
Smart File Detection: Automatically finds and groups identical file versions by hash
Similarity-Based Progression: Uses advanced algorithms to find the most similar files and merge them in optimal order
Smart Discovery: Automatically locates and groups identical files by hash across directories or repositories.
Hash-Based Grouping: Efficiently identifies duplicates and unique versions for targeted merging.
Similarity Analysis: Calculates similarity scores to determine optimal merge order and minimize conflicts.
Optimal Merge Order: Progressively merges the most similar file pairs first, reducing complexity and conflicts.
Interactive Resolution: Provides a visual TUI interface for resolving merge conflicts at the block level.
Cross-Repository Sync: Updates all file locations with the final merged result.
Audience & Benefit:
Ideal for developers, DevOps teams, and organizations managing multiple repositories or branches. BlastMerge streamlines cross-repository file synchronization, enabling efficient consolidation of divergent file versions into a single, unified result while reducing manual effort and potential errors.
Cross-Repository Updates: Synchronizes all file locations with the merged result
Progressive Conflict Reduction: Each merge reduces complexity for subsequent merges
Interactive Conflict Resolution: Visual TUI for resolving merge conflicts block-by-block
Version Tracking: Maintains awareness of which files need updating across all locations
đ Advanced File Analysis
Hash-Based Comparison: Fast file comparison using FNV-1a content hashing for instant duplicate detection
Content Similarity Scoring: Sophisticated algorithms to determine merge order
Multiple Diff Formats:
Change Summary (added/removed lines only)
Git-style diff (full context)
Rich colored diff (visual formatting)
Side-by-Side Display: Context-aware diff visualization with intelligent file ordering
đ§ Repository & Directory Operations
Directory Comparison: Compare entire directories with customizable file patterns
Recursive Search: Deep directory traversal to find all file versions
Pre-defined Templates: Ready-made configurations for common repository synchronization tasks
Discrete Processing Phases: Separate gathering, hashing, grouping, and resolution phases for better UX
Pattern-based Processing: Support for wildcards and complex file matching
đģ Interactive Experience
Rich Terminal Interface: Colored output and intuitive navigation with Spectre.Console
Command History: Arrow key navigation through previous inputs with persistent history across sessions
Smart Defaults: Intelligent defaults based on most recently used inputs
Progress Indicators: Real-time feedback for long-running operations with detailed phase reporting
Block-Level Control: Choose how to handle each difference (keep, remove, use version 1/2, use both)
Keyboard Shortcuts: Comprehensive keyboard navigation for all operations
Installation
Add the NuGet package:
dotnet add package ktsu.BlastMerge
Usage
Primary Workflow: Iterative File Synchronization
# Launch interactive mode for iterative merging
BlastMerge.ConsoleApp
# Select "đ Iterative Merge"
# 1. Specify the directory containing your repositories/projects
# 2. Enter the filename pattern (e.g., "README.md", "config.json", "*.yml")
# 3. Watch as BlastMerge finds all versions and merges them optimally
# 4. Resolve conflicts interactively when needed
# 5. All file locations are automatically updated with the unified result
Command Line Mode
# Quick comparison for files with the same name across directories
BlastMerge.ConsoleApp
# Run a saved batch configuration
BlastMerge.ConsoleApp -b
# List available batch configurations
BlastMerge.ConsoleApp -l
# Show version information
BlastMerge.ConsoleApp -v
# Display help
BlastMerge.ConsoleApp -h