Skip to main content

Module platform_paths

Module platform_paths 

Source
Expand description

Platform-aware directory resolution.

macOS: ~/Library/Application Support/Convergio Linux: ~/.local/share/convergio Windows: %APPDATA%/Convergio Fallback: ~/.convergio/

Functions§

convergio_data_dir
Primary Convergio data directory.
project_output_dir
Output directory for a named project. The project name is validated to prevent path traversal.
sanitize_path
Validate a path is within an allowed base directory. Prevents path traversal. Returns the canonicalized path on success, or an error if traversal detected.
validate_path_components
Validate a path only contains safe characters (no traversal components). Does NOT require the path to exist yet (for create operations). Rejects absolute paths (/foo) and parent traversal (..).