<?xml version="1.0" encoding="UTF-8"?>
<schemalist gettext-domain="driftwood">
  <schema id="app.driftwood.Driftwood" path="/app/driftwood/Driftwood/">
    <key name="window-width" type="i">
      <default>900</default>
      <summary>Window width</summary>
      <description>The width of the main application window.</description>
    </key>
    <key name="window-height" type="i">
      <default>600</default>
      <summary>Window height</summary>
      <description>The height of the main application window.</description>
    </key>
    <key name="window-maximized" type="b">
      <default>false</default>
      <summary>Window maximized</summary>
      <description>Whether the main application window is maximized.</description>
    </key>
    <key name="scan-directories" type="as">
      <default>['~/Applications', '~/Downloads']</default>
      <summary>Scan directories</summary>
      <description>Directories to scan for AppImage files.</description>
    </key>
    <key name="view-mode" type="s">
      <choices>
        <choice value='grid'/>
        <choice value='list'/>
      </choices>
      <default>'list'</default>
      <summary>Library view mode</summary>
      <description>The library view mode: grid or list.</description>
    </key>
    <key name="sort-mode" type="s">
      <choices>
        <choice value='name'/>
        <choice value='recently-added'/>
        <choice value='size'/>
      </choices>
      <default>'recently-added'</default>
      <summary>Library sort mode</summary>
      <description>How to sort the library: name, recently-added, or size.</description>
    </key>
    <key name="color-scheme" type="s">
      <choices>
        <choice value='default'/>
        <choice value='force-light'/>
        <choice value='force-dark'/>
      </choices>
      <default>'default'</default>
      <summary>Color scheme</summary>
      <description>Application color scheme: default (follow system), force-light, or force-dark.</description>
    </key>
    <key name="auto-scan-on-startup" type="b">
      <default>true</default>
      <summary>Auto scan on startup</summary>
      <description>Whether to automatically scan for AppImages when the application starts.</description>
    </key>
    <key name="detail-tab" type="s">
      <choices>
        <choice value='about'/>
        <choice value='details'/>
      </choices>
      <default>'about'</default>
      <summary>Last detail view tab</summary>
      <description>The last selected tab in the detail view (about or details).</description>
    </key>
    <key name="auto-check-updates" type="b">
      <default>false</default>
      <summary>Auto check updates</summary>
      <description>Automatically check for AppImage updates periodically.</description>
    </key>
    <key name="update-check-interval-hours" type="i">
      <range min="1" max="168"/>
      <default>24</default>
      <summary>Update check interval</summary>
      <description>Hours between automatic update checks.</description>
    </key>
    <key name="last-update-check" type="s">
      <default>''</default>
      <summary>Last update check timestamp</summary>
      <description>ISO timestamp of the last automatic update check.</description>
    </key>
    <key name="auto-integrate" type="b">
      <default>false</default>
      <summary>Auto integrate</summary>
      <description>Automatically integrate newly discovered AppImages into the desktop menu.</description>
    </key>
    <key name="auto-backup-before-update" type="b">
      <default>false</default>
      <summary>Auto backup before update</summary>
      <description>Create a config backup before applying an update.</description>
    </key>
    <key name="backup-retention-days" type="i">
      <range min="1" max="365"/>
      <default>30</default>
      <summary>Backup retention days</summary>
      <description>Number of days to keep config backups before auto-cleanup.</description>
    </key>
    <key name="confirm-before-delete" type="b">
      <default>true</default>
      <summary>Confirm before delete</summary>
      <description>Show a confirmation dialog before deleting AppImages or backups.</description>
    </key>
    <key name="update-cleanup" type="s">
      <choices>
        <choice value='ask'/>
        <choice value='always'/>
        <choice value='never'/>
      </choices>
      <default>'ask'</default>
      <summary>Update cleanup mode</summary>
      <description>What to do with old versions after update: ask, keep, or delete.</description>
    </key>
    <key name="auto-security-scan" type="b">
      <default>false</default>
      <summary>Auto security scan</summary>
      <description>Automatically scan AppImages for security vulnerabilities during scan.</description>
    </key>
    <key name="security-notifications" type="b">
      <default>false</default>
      <summary>Security notifications</summary>
      <description>Send desktop notifications when new CVEs are found.</description>
    </key>
    <key name="security-notification-threshold" type="s">
      <choices>
        <choice value='critical'/>
        <choice value='high'/>
        <choice value='medium'/>
        <choice value='low'/>
      </choices>
      <default>'high'</default>
      <summary>Security notification threshold</summary>
      <description>Minimum CVE severity for desktop notifications: critical, high, medium, or low.</description>
    </key>
    <key name="catalog-last-refreshed" type="s">
      <default>''</default>
      <summary>Catalog last refreshed</summary>
      <description>ISO timestamp of the last catalog refresh.</description>
    </key>
    <key name="watch-removable-media" type="b">
      <default>false</default>
      <summary>Watch removable media</summary>
      <description>Scan removable drives for AppImages when mounted.</description>
    </key>
    <key name="github-token" type="s">
      <default>''</default>
      <summary>GitHub personal access token</summary>
      <description>Optional GitHub token for higher API rate limits (5,000 vs 60 requests per hour).</description>
    </key>
    <key name="catalog-auto-enrich" type="b">
      <default>true</default>
      <summary>Auto-enrich catalog apps</summary>
      <description>Automatically fetch GitHub metadata (stars, version, downloads) for catalog apps in the background.</description>
    </key>
  </schema>
</schemalist>
