{
 "app_id": "org.popcorntime.PopcornTime",
 "source_url": "https://gitlab.com/Jan_Willem/popcorntime-flatpak/-/raw/master/org.popcorntime.PopcornTime.json",
 "runtime": "org.gnome.Platform",
 "runtime_version": "46",
 "sdk": "org.gnome.Sdk",
 "finish_args": [
  "--share=ipc",
  "--share=network",
  "--socket=wayland",
  "--device=dri",
  "--socket=pulseaudio",
  "--filesystem=home",
  "--filesystem=/tmp/Popcorn Time:create",
  "--talk-name=org.freedesktop.Notifications"
 ],
 "module_count": 1,
 "fetched_at": "2026-09-18T08:27:15.949519+00:00",
 "manifest": {
  "app-id": "org.popcorntime.PopcornTime",
  "runtime": "org.gnome.Platform",
  "runtime-version": "46",
  "sdk": "org.gnome.Sdk",
  "base": "org.electronjs.Electron2.BaseApp",
  "base-version": "23.08",
  "command": "popcorntime-wrapper",
  "separate-locales": false,
  "finish-args": [
   "--share=ipc",
   "--share=network",
   "--socket=wayland",
   "--device=dri",
   "--socket=pulseaudio",
   "--filesystem=home",
   "--filesystem=/tmp/Popcorn Time:create",
   "--talk-name=org.freedesktop.Notifications"
  ],
  "modules": [
   {
    "name": "popcorntime",
    "buildsystem": "simple",
    "cleanup": [
     "Popcorn-Time-0.5.1-linux64.zip"
    ],
    "sources": [
     {
      "type": "file",
      "only-arches": [
       "x86_64"
      ],
      "url": "https://github.com/popcorn-official/popcorn-desktop/releases/download/v0.5.1/Popcorn-Time-0.5.1-linux64.zip",
      "sha256": "942b088a8476e761963fffb0370913c393cb49a97f33dc7a9a547f10a39dfe1b"
     },
     {
      "type": "file",
      "path": "org.popcorntime.PopcornTime.metainfo.xml"
     },
     {
      "type": "script",
      "dest-filename": "popcorntime-wrapper",
      "commands": [
       "exec /app/popcorntime/Popcorn-Time --enable-features=UseOzonePlatform --ozone-platform=wayland"
      ]
     }
    ],
    "build-commands": [
     "install -d /app/popcorntime",
     "unzip Popcorn-Time-0.5.1-linux64.zip -d /app/popcorntime",
     "install popcorntime-wrapper /app/bin/",
     "install -d /app/share/icons/hicolor/256x256/apps/",
     "install /app/popcorntime/src/app/images/icon.png /app/share/icons/hicolor/256x256/apps/org.popcorntime.PopcornTime.png",
     "install -d /app/share/applications",
     "touch org.popcorntime.PopcornTime.desktop",
     "install -Dp -m644 org.popcorntime.PopcornTime.metainfo.xml /app/share/metainfo/org.popcorntime.PopcornTime.metainfo.xml",
     "install -m644 org.popcorntime.PopcornTime.desktop /app/share/applications/org.popcorntime.PopcornTime.desktop",
     "desktop-file-edit --set-key=Exec --set-value='popcorntime-wrapper %U' --set-key=Icon --set-value='org.popcorntime.PopcornTime' --set-key=Comment --set-value='Watch Movies and TV Shows instantly' --set-key=Name --set-value='Popcorn-Time' --set-key=MimeType --set-value='application/x-bittorrent;x-scheme-handler/magnet;' --set-key=StartupNotify --set-value='false' --set-key=Categories --set-value='AudioVideo;Video;Player;' --set-key=Type --set-value='Application' /app/share/applications/org.popcorntime.PopcornTime.desktop"
    ]
   }
  ]
 }
}