Documentation
¶
Overview ¶
Package desktop provides functionality for detecting and validating the ToolHive Desktop application's CLI management.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrDesktopConflict = errors.New("CLI conflict detected")
ErrDesktopConflict is returned when a conflict is detected between the current CLI and the desktop-managed CLI.
Functions ¶
func ValidateDesktopAlignment ¶
func ValidateDesktopAlignment() error
ValidateDesktopAlignment checks if the current CLI binary conflicts with a desktop-managed CLI installation.
Returns nil if:
- No marker file exists (no desktop installation)
- Marker file is invalid or unreadable (treat as no desktop installation)
- The target binary in the marker doesn't exist (desktop was uninstalled)
- The current CLI is the desktop-managed CLI (paths match)
Returns an error if:
- A valid marker file exists pointing to an existing binary
- The current CLI is NOT the desktop-managed binary
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.