Metadata-Version: 2.4
Name: md-merge
Version: 0.1.1
Summary: A Python tool designed to take a list of Markdown files and merge them into a single document.
Project-URL: Homepage, https://github.com/difegam/md-merge
Project-URL: Bug Reports, https://github.com/difegam/md-merge/issues
Project-URL: Source, https://github.com/difegam/md-merge
Author-email: difegam <difegam3@gmail.com>
License-File: LICENSE
Keywords: markdown,markdown-merge,md-merge,merge,python-markdown
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.12
Description-Content-Type: text/markdown

# Markdown Merger (md-merge)

A command-line tool to merge multiple Markdown files into a single document.

## Installation

```bash
uv pip install md-merge
```
## CLI
You can also install it using the `uv` tool, and run it directly from the command line:
```bash
uv tool install md-merge
md-merge --help
```

## Usage

```bash
# Merge specific files in order
md-merge file1.md another/file.md docs/intro.md --output combined_manual.md

# Merge all *.md files recursively from a directory (alphabetical order)
md-merge --dir path/to/markdown/docs --output full_docs.md

# Specify a different output file
md-merge file.md --output my_merged_file.md

# Enable verbose logging for debugging
mdmerge --dir my_project --verbose

# Get help
md-merge --help
```

## Features
- Merges specified files or all .md files in a directory.
- Inserts a separator between files showing the source path.
- Adds a header to the merged document with timestamp and file count.
- Preserves YAML front matter (from the first file only).
- Configurable output file path (default: merged.md).
- Verbose logging option (--verbose or -v).
- Robust error handling and validation.


## Future Improvements
- Add support for custom separators.
- Implement a GUI for easier file selection.
- Support for other file formats (e.g., .txt, .rst).
- Add unit tests for better coverage.
