/**
 * Compare two version strings. Returns true if `latest` is newer than `current`.
 */
export declare function isNewerVersion(latest: string, current: string): boolean;
/**
 * Derive a potential cask token from an app name.
 * Returns null if the name is clearly not a cask candidate.
 */
export declare function guessCaskToken(appName: string): string | null;
/**
 * Look up the cask token for an app. Uses the static map first,
 * then falls back to algorithmic derivation.
 */
export declare function getCaskToken(appName: string): string | null;
/**
 * Scan /Applications for installed apps and read their versions from Info.plist.
 */
export declare function scanInstalledApps(applicationsDir?: string): InstalledApp[];
/**
 * Query Homebrew for latest cask versions in batch.
 * Pass an array of cask tokens, returns a map of token → info.
 */
// eslint-disable-next-line pickier/no-unused-vars
export declare function queryBrewCaskVersions(tokens: string[]): Map<string, BrewCaskInfo>;
/**
 * Check for available updates for installed desktop apps.
 * This is the main function — scans apps, queries brew, compares versions.
 */
export declare function checkAppUpdates(apps?: InstalledApp[]): AppUpdateInfo[];
/**
 * Update a desktop app via Homebrew cask.
 */
// eslint-disable-next-line pickier/no-unused-vars
export declare function updateApp(caskToken: string): Promise<{
  success: boolean
  version?: string
  error?: string
}>;
// ── App → Cask Token Mapping ─────────────────────────────────────
// Key: app name as it appears in /Applications (without .app)
// Value: Homebrew cask token
export declare const APP_CASK_MAP: {
  'Arc': 'arc';
  'Brave Browser': 'brave-browser';
  'Firefox': 'firefox';
  'Google Chrome': 'google-chrome';
  'Microsoft Edge': 'microsoft-edge';
  'Opera': 'opera';
  'Vivaldi': 'vivaldi';
  'Zen Browser': 'zen-browser';
  'Orion': 'orion';
  'Chromium': 'chromium';
  'Tor Browser': 'tor-browser';
  'Visual Studio Code': 'visual-studio-code';
  'Cursor': 'cursor';
  'Zed': 'zed';
  'Sublime Text': 'sublime-text';
  'Sublime Merge': 'sublime-merge';
  'Nova': 'nova';
  'BBEdit': 'bbedit';
  'CotEditor': 'coteditor';
  'IntelliJ IDEA': 'intellij-idea';
  'IntelliJ IDEA CE': 'intellij-idea-ce';
  'PhpStorm': 'phpstorm';
  'WebStorm': 'webstorm';
  'PyCharm': 'pycharm';
  'PyCharm CE': 'pycharm-ce';
  'RubyMine': 'rubymine';
  'CLion': 'clion';
  'GoLand': 'goland';
  'DataGrip': 'datagrip';
  'Rider': 'rider';
  'Android Studio': 'android-studio';
  'Fleet': 'jetbrains-fleet';
  'iTerm': 'iterm2';
  'Ghostty': 'ghostty';
  'Warp': 'warp';
  'Alacritty': 'alacritty';
  'Kitty': 'kitty';
  'Hyper': 'hyper';
  'GitHub Desktop': 'github';
  'GitKraken': 'gitkraken';
  'Tower': 'tower';
  'Fork': 'fork';
  'Tinkerwell': 'tinkerwell';
  'TablePlus': 'tableplus';
  'Sequel Pro': 'sequel-pro';
  'Sequel Ace': 'sequel-ace';
  'Postman': 'postman';
  'Insomnia': 'insomnia';
  'Proxyman': 'proxyman';
  'Docker': 'docker';
  'OrbStack': 'orbstack';
  'Dynobase': 'dynobase';
  'HTTPie': 'httpie';
  'Charles': 'charles';
  'Paw': 'paw';
  'Dash': 'dash';
  'SourceTree': 'sourcetree';
  'WhatsApp': 'whatsapp';
  'Slack': 'slack';
  'Discord': 'discord';
  'Telegram': 'telegram';
  'Microsoft Teams': 'microsoft-teams';
  'Zoom': 'zoom';
  'Signal': 'signal';
  'Skype': 'skype';
  'Lark': 'lark';
  'Claude': 'claude';
  'ChatGPT': 'chatgpt';
  'Obsidian': 'obsidian';
  'Notion': 'notion';
  'Bear': 'bear';
  'Craft': 'craft';
  'Logseq': 'logseq';
  'Typora': 'typora';
  'Joplin': 'joplin';
  'Things3': 'things';
  'Things': 'things';
  'Todoist': 'todoist';
  'TickTick': 'ticktick';
  'Fantastical': 'fantastical';
  'Spark': 'readdle-spark';
  '1Password': '1password';
  '1Password 7': '1password';
  'Raycast': 'raycast';
  'Alfred': 'alfred';
  'BetterTouchTool': 'bettertouchtool';
  'Bartender': 'bartender';
  'Setapp': 'setapp';
  'Grammarly Desktop': 'grammarly-desktop';
  'Spotify': 'spotify';
  'IINA': 'iina';
  'VLC': 'vlc';
  'HandBrake': 'handbrake';
  'Kap': 'kap';
  'OBS': 'obs';
  'DaVinci Resolve': 'davinci-resolve';
  'Plex': 'plex';
  'Audacity': 'audacity';
  'Elmedia Player': 'elmedia-player';
  'Figma': 'figma';
  'Sketch': 'sketch';
  'Affinity Designer': 'affinity-designer';
  'Affinity Designer 2': 'affinity-designer';
  'Affinity Photo': 'affinity-photo';
  'Affinity Photo 2': 'affinity-photo';
  'Affinity Publisher': 'affinity-publisher';
  'Affinity Publisher 2': 'affinity-publisher';
  'ImageOptim': 'imageoptim';
  'Pixelmator Pro': 'pixelmator-pro';
  'Canva': 'canva';
  'AppCleaner': 'appcleaner';
  'Pearcleaner': 'pearcleaner';
  'CleanMyMac': 'cleanmymac';
  'CleanMyMac X': 'cleanmymac';
  'Caffeine': 'caffeine';
  'KeepingYouAwake': 'keepingyouawake';
  'Muzzle': 'muzzle';
  'Rectangle': 'rectangle';
  'Magnet': 'magnet';
  'MonitorControl': 'monitorcontrol';
  'iStat Menus': 'istat-menus';
  'CleanShot X': 'cleanshot';
  'Shottr': 'shottr';
  'Karabiner-Elements': 'karabiner-elements';
  'Logi Options+': 'logi-options-plus';
  'logioptionsplus': 'logi-options-plus';
  'Logi Options Plus': 'logi-options-plus';
  'Transmit': 'transmit';
  'Cyberduck': 'cyberduck';
  'The Unarchiver': 'the-unarchiver';
  'Keka': 'keka';
  'ForkLift': 'forklift';
  'Mountain Duck': 'mountain-duck';
  'Parallels Desktop': 'parallels';
  'VMware Fusion': 'vmware-fusion';
  'UTM': 'utm';
  'Steam': 'steam';
  'Epic Games Launcher': 'epic-games';
  'Tailscale': 'tailscale';
  'WireGuard': 'wireguard-go';
  'NordVPN': 'nordvpn';
  'Mullvad VPN': 'mullvad-vpn';
  'MongoDB Compass': 'mongodb-compass';
  'Redis Insight': 'redisinsight';
  'Robo 3T': 'robo-3t';
  'Numi': 'numi';
  'Maccy': 'maccy';
  'Camo': 'camo';
  'Linear': 'linear-linear';
  'Loom': 'loom';
  'Dropbox': 'dropbox';
  'Google Drive': 'google-drive';
  'OneDrive': 'onedrive';
  'MediaInfo': 'mediainfo'
};
// Known system/Apple apps that have no cask
export declare const SYSTEM_APPS: Set<string>;
// Known MAS-only apps (available on Mac App Store but not as brew cask)
export declare const MAS_APPS: Set<string>;
// ── Types ────────────────────────────────────────────────────────
export declare interface InstalledApp {
  name: string
  version: string
  path: string
  bundleId?: string
}
export declare interface AppUpdateInfo {
  name: string
  currentVersion: string
  latestVersion: string | null
  updateAvailable: boolean
  source: 'brew-cask' | 'mas' | 'system' | 'self-updating' | 'unknown'
  caskToken: string | null
  autoUpdates: boolean
}
export declare interface BrewCaskInfo {
  token: string
  version: string
  autoUpdates: boolean
  appNames: string[]
}
