Tools & Utilities¶
This directory contains tools and utilities for the Odoo migration project, primarily focused on diagram generation and documentation automation.
๐ ๏ธ Available Tools¶
๐ PlantUML Diagram Generator¶
plantuml.jar- PlantUML engine for generating diagramsgenerate-diagrams.ps1- PowerShell script for batch diagram generation
๐ Local Documentation Server¶
serve-local.ps1- PowerShell script for local testingserve-local.bat- Windows batch file for local testing../serve-local.py- Python HTTP server (cross-platform)../serve-python.bat- Windows batch wrapper for Python server
๐ Quick Start¶
Prerequisites¶
- Java 8 or higher (for PlantUML diagram generation)
- PowerShell (for Windows scripts)
- Python 3.6+ (for Python server option)
Installation¶
- The
plantuml.jarfile is already downloaded in this directory - The
generate-diagrams.ps1script is ready to use
๐ Usage¶
Generate All Diagrams¶
.\tools\generate-diagrams.ps1
Generate Specific Diagram¶
.\tools\generate-diagrams.ps1 "docs\diagrams\Odoo-Contact-Migration-Phases.puml"
Manual Generation¶
java -jar tools\plantuml.jar docs\diagrams\Odoo-Contact-Migration-Phases.puml
Start Local Documentation Server¶
Option 1: PowerShell (Windows/Linux/macOS)¶
.\tools\serve-local.ps1
# Custom port
.\tools\serve-local.ps1 8080
Option 2: Windows Batch¶
.\tools\serve-local.bat
Option 3: Python Server (Cross-platform)¶
# Basic usage
python serve-local.py
# Custom port
python serve-local.py --port 3000
# Allow external connections
python serve-local.py --host 0.0.0.0
# Auto-find available port
python serve-local.py --auto-port
# Don't open browser automatically
python serve-local.py --no-browser
Option 4: Python Batch Wrapper (Windows)¶
.\serve-python.bat
Access Local Documentation¶
- Open your browser to:
http://localhost:8000 - Navigate through the documentation
- Test all links and images locally
๐ Output¶
- Generated PNG files are saved in the
diagrams/directory - Each
.pumlfile will create a corresponding.pngfile - The script provides colored output showing success/failure status
๐ง Troubleshooting¶
PlantUML Issues¶
"plantuml.jar file not found"¶
- Ensure the JAR file is in the
tools/directory - Download from: https://plantuml.com/download
Java not found¶
- Ensure Java is installed and in your PATH
- Test with:
java -version
Server Issues¶
PowerShell permission errors¶
- Run PowerShell as Administrator if needed
- Check file permissions on the tools directory
Python server issues¶
- Ensure Python 3.6+ is installed:
python --version - Port already in use: Try
--auto-portflag or different port - Permission denied: Try running as administrator (Windows) or with
sudo(Linux/macOS)
Browser not opening automatically¶
- Manually navigate to the URL shown in the terminal
- Use
--no-browserflag to disable auto-opening
๐ Integration with Documentation¶
The generated PNG files can be embedded in markdown documents:

This approach is more reliable than inline PlantUML code blocks and works with all markdown renderers.
๐ Related Documentation¶
- Diagrams & Charts - Visual documentation overview
- Functional Areas - Business domain documentation
- Migration Scripts - Data migration automation
๐ฏ Best Practices¶
- Keep diagrams updated - Regenerate when source files change
- Use consistent naming - Follow established naming conventions
- Version control - Include both source (
.puml) and output (.png) files - Documentation integration - Reference generated diagrams in relevant docs
- Testing - Test diagram generation in staging before production