{
 "app_id": "org.b3log.siyuan",
 "source_url": "https://raw.githubusercontent.com/flathub/org.b3log.siyuan/master/org.b3log.siyuan.yml",
 "runtime": "org.freedesktop.Platform",
 "runtime_version": "25.08",
 "sdk": "org.freedesktop.Sdk",
 "finish_args": [
  "--share=ipc",
  "--share=network",
  "--socket=fallback-x11",
  "--socket=wayland",
  "--device=dri",
  "--filesystem=xdg-download",
  "--filesystem=xdg-pictures:ro",
  "--filesystem=xdg-videos:ro",
  "--filesystem=xdg-music:ro",
  "--filesystem=xdg-desktop",
  "--filesystem=xdg-documents",
  "--talk-name=org.kde.StatusNotifierWatcher"
 ],
 "module_count": 1,
 "fetched_at": "2026-09-17T16:14:11.961990+00:00",
 "manifest": {
  "app-id": "org.b3log.siyuan",
  "runtime": "org.freedesktop.Platform",
  "runtime-version": "25.08",
  "sdk": "org.freedesktop.Sdk",
  "base": "org.electronjs.Electron2.BaseApp",
  "base-version": "25.08",
  "command": "start-siyuan.sh",
  "finish-args": [
   "--device=dri",
   "--persist=SiYuan",
   "--persist=.config/siyuan",
   "--persist=.config/SiYuan",
   "--persist=.config/SiYuan-Electron",
   "--filesystem=xdg-pictures:ro",
   "--filesystem=xdg-videos:ro",
   "--filesystem=xdg-music:ro",
   "--filesystem=xdg-desktop",
   "--filesystem=xdg-download",
   "--filesystem=xdg-documents",
   "--share=ipc",
   "--share=network",
   "--socket=wayland",
   "--socket=fallback-x11",
   "--talk-name=org.kde.StatusNotifierWatcher",
   "--env=XCURSOR_PATH=/run/host/user-share/icons:/run/host/share/icons"
  ],
  "modules": [
   {
    "name": "siyuan",
    "buildsystem": "simple",
    "build-commands": [
     "mv \"siyuan\" ${FLATPAK_DEST}/siyuan",
     "rm ${FLATPAK_DEST}/siyuan/chrome-sandbox",
     "for lang in ${FLATPAK_DEST}/siyuan/locales/*.pak\ndo\n  locale=\"$(basename -s .pak $lang)\"\n  install -Dm644 -t \"${FLATPAK_DEST}/share/runtime/locale/${locale%%-*}/\" \"$lang\"\n  ln -sf \"${FLATPAK_DEST}/share/runtime/locale/${locale%%-*}/$(basename $lang)\" \"${FLATPAK_DEST}/siyuan/locales/$(basename $lang)\"\ndone\n",
     "install -Dm644 \"${FLATPAK_DEST}/siyuan/resources/stage/icon-large.png\" \"${FLATPAK_DEST}/share/icons/hicolor/512x512/apps/${FLATPAK_ID}.png\"",
     "install -Dm644 org.b3log.siyuan.desktop \"${FLATPAK_DEST}/share/applications/${FLATPAK_ID}.desktop\"",
     "install -Dm644 org.b3log.siyuan.metainfo.xml /app/share/metainfo/$FLATPAK_ID.metainfo.xml",
     "install -Dm755 start-siyuan.sh /app/bin/start-siyuan.sh"
    ],
    "sources": [
     {
      "type": "archive",
      "dest": "siyuan",
      "only-arches": [
       "x86_64"
      ],
      "url": "https://github.com/siyuan-note/siyuan/releases/download/v3.8.4/siyuan-3.8.4-linux.tar.gz",
      "sha256": "4c15959de7c187064db6f82acaaf97bbbb6fb0280e479c9af031b53db2870c5e",
      "x-checker-data": {
       "is-main-source": true,
       "type": "anitya",
       "project-id": 358424,
       "url-template": "https://github.com/siyuan-note/siyuan/releases/download/v$version/siyuan-$version-linux.tar.gz",
       "stable-only": true
      }
     },
     {
      "type": "archive",
      "dest": "siyuan",
      "only-arches": [
       "aarch64"
      ],
      "url": "https://github.com/siyuan-note/siyuan/releases/download/v3.8.4/siyuan-3.8.4-linux-arm64.tar.gz",
      "sha256": "91cdfe672d05e92ec171a630c67f1bceed05fc68b1133bfef89f424f5378552e",
      "x-checker-data": {
       "type": "anitya",
       "project-id": 358424,
       "url-template": "https://github.com/siyuan-note/siyuan/releases/download/v$version/siyuan-$version-linux-arm64.tar.gz",
       "stable-only": true
      }
     },
     {
      "type": "file",
      "path": "org.b3log.siyuan.desktop"
     },
     {
      "type": "file",
      "path": "org.b3log.siyuan.metainfo.xml"
     },
     {
      "type": "file",
      "path": "start-siyuan.sh"
     }
    ]
   }
  ]
 }
}