oxidize-pdf-cli
Command-line interface for oxidize-pdf - a comprehensive, pure Rust PDF library.
Overview
oxidize-pdf-cli provides a powerful command-line interface to create, manipulate, and analyze PDF files using the oxidize-pdf library. It supports PDF generation, merging, splitting, rotation, text extraction, and document analysis.
Installation
Or build from source:
Quick Start
Create a simple PDF:
Generate a demo PDF with graphics:
Extract text from a PDF:
Get PDF information:
Command Reference
Create
Create a simple PDF with text content.
Demo
Generate a demonstration PDF showcasing graphics and text capabilities.
Info
Display information about a PDF file including metadata and structure.
Extract Text
Extract text content from PDF files with optional layout preservation.
Rotate
Rotate pages in a PDF document.
# Examples:
Merge (Coming Soon)
Merge multiple PDF files into a single document.
Split (Coming Soon)
Split a PDF into multiple files.
Features
- Pure Rust: No external PDF dependencies
- Fast: Native performance with zero overhead
- Comprehensive: Supports creation, manipulation, and analysis
- Cross-platform: Works on Windows, macOS, and Linux
- Memory efficient: Streaming operations for large files
Examples
Creating a PDF with formatted text
Extracting text with layout preservation
Rotating specific pages
Getting detailed PDF information
Error Handling
The CLI provides detailed error messages for common issues:
- Invalid file paths
- Unsupported PDF features
- Invalid page ranges
- Parsing errors
Exit codes:
- 0: Success
- 1: Error occurred
Performance
oxidize-pdf-cli is optimized for performance:
- Fast PDF parsing (< 50ms for typical documents)
- Efficient memory usage with streaming operations
- Multi-threaded operations where applicable
Limitations
Current limitations (as of v0.1.2):
- No support for encrypted PDFs
- Limited to JPEG images (PNG support planned)
- Text extraction limited to simple encoding
- Merge and split operations coming in Q2 2025
License
GPL v3.0 - See LICENSE file for details