YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context
Rust agentsagiaiai-memoryaudio-recordingcomputer-visionhermeshermes-agentllmlocal-ailocal-firstmachine-learningmcpmultimodalopenclawprivacyrewindscreen-recordingspeech-to-textycombinator
fix: ship with ffmpeg (#1641)
tribhuwan04f8c72a1add
diff --git a/screenpipe-app-tauri/.gitignore b/screenpipe-app-tauri/.gitignoreindex df7f78aa4..12994937d 100644--- a/screenpipe-app-tauri/.gitignore+++ b/screenpipe-app-tauri/.gitignore@@ -39,6 +39,7 @@ next-env.d.tsffmpeg*+ffprobe**src-tauri/screenpipe**src-tauri/tesseract**src-tauri/deno*diff --git a/screenpipe-app-tauri/scripts/pre_build.js b/screenpipe-app-tauri/scripts/pre_build.jsindex 24a72e399..2116c19ef 100644--- a/screenpipe-app-tauri/scripts/pre_build.js+++ b/screenpipe-app-tauri/scripts/pre_build.js@@ -45,8 +45,10 @@ const config = {],},macos: {- ffmpegName: 'ffmpeg-7.0-macOS-default',- ffmpegUrl: 'https://master.dl.sourceforge.net/project/avbuild/macOS/ffmpeg-7.0-macOS-default.tar.xz?viasf=1',+ ffmpegUrlArm: 'https://www.osxexperts.net/ffmpeg7arm.zip',+ ffprobeUrlArm: 'https://www.osxexperts.net/ffprobe71arm.zip',+ ffmpegUrlx86_64: 'https://evermeet.cx/ffmpeg/getrelease/zip',+ ffprobeUrlx86_64: 'https://www.osxexperts.net/ffprobe71intel.zip',},}@@ -377,17 +379,41 @@ if (platform == 'macos') {console.log(`screenpipe for ${arch} set up successfully.`);}- // Setup FFMPEG- if (!(await fs.exists(config.ffmpegRealname))) {- await $`wget --no-config -nc ${config.macos.ffmpegUrl} -O ${config.macos.ffmpegName}.tar.xz`- await $`tar xf ${config.macos.ffmpegName}.tar.xz`- await $`mv ${config.macos.ffmpegName} ${config.ffmpegRealname}`- await $`rm ${config.macos.ffmpegName}.tar.xz`- } else {- console.log('FFMPEG already exists');- }--+ // Setup ffmpeg and ffprobe for both arm64 and x86_64+ // ref: https://github.com/nathanbabcock/ffmpeg-sidecar/blob/b0ab2e1233451f219e302bf78cbbb6a5a8e85aa4/src/download.rs#L31+ if (!(await fs.exists(`ffmpeg-aarch64-apple-darwin`))) {+ await $`wget --no-config ${config.macos.ffmpegUrlArm} -O ffmpeg-aarch64.zip`;+ await $`unzip -o ffmpeg-aarch64.zip -d ffmpeg-aarch64`;+ await $`cp ffmpeg-aarch64/ffmpeg ffmpeg-aarch64-apple-darwin`;+ await $`rm ffmpeg-aarch64.zip`;+ await $`rm -rf ffmpeg-aarch64`;+ }++ if (!(await fs.exists(`ffprobe-aarch64-apple-darwin`))) {+ await $`wget --no-config ${config.macos.ffprobeUrlArm} -O ffprobe-aarch64.zip`;+ await $`unzip -o ffprobe-aarch64.zip -d ffprobe-aarch64`;+ await $`cp ffprobe-aarch64/ffprobe ffprobe-aarch64-apple-darwin`;+ await $`rm ffprobe-aarch64.zip`;+ await $`rm -rf ffprobe-aarch64`;+ }++ if (!(await fs.exists(`ffmpeg-x86_64-apple-darwin`))) {+ await $`wget --no-config ${config.macos.ffmpegUrlx86_64} -O ffmpeg-x86_64.zip`;+ await $`unzip -o ffmpeg-x86_64.zip -d ffmpeg-x86_64`;+ await $`cp ffmpeg-x86_64/ffmpeg ffmpeg-x86_64-apple-darwin`;+ await $`rm ffmpeg-x86_64.zip`;+ await $`rm -rf ffmpeg-x86_64`;+ }++ if (!(await fs.exists(`ffprobe-x86_64-apple-darwin`))) {+ await $`wget --no-config ${config.macos.ffprobeUrlx86_64} -O ffprobe-x86_64.zip`;+ await $`unzip -o ffprobe-x86_64.zip -d ffprobe-x86_64`;+ await $`cp ffprobe-x86_64/ffprobe ffprobe-x86_64-apple-darwin`;+ await $`rm ffprobe-x86_64.zip`;+ await $`rm -rf ffprobe-x86_64`;+ }++ console.log('FFMPEG and FFPROBE checks completed');console.log('Moved and renamed ffmpeg binary for externalBin');// Setup Swift UI monitoringdiff --git a/screenpipe-app-tauri/src-tauri/tauri.macos.conf.json b/screenpipe-app-tauri/src-tauri/tauri.macos.conf.jsonindex 2b05090a0..2cf020465 100644--- a/screenpipe-app-tauri/src-tauri/tauri.macos.conf.json+++ b/screenpipe-app-tauri/src-tauri/tauri.macos.conf.json@@ -12,7 +12,9 @@"externalBin": ["screenpipe","bun",- "ui_monitor"+ "ui_monitor",+ "ffmpeg",+ "ffprobe"]}}diff --git a/screenpipe-app-tauri/src-tauri/tauri.windows.conf.json b/screenpipe-app-tauri/src-tauri/tauri.windows.conf.jsonindex 76c60f619..4208ca1c5 100644--- a/screenpipe-app-tauri/src-tauri/tauri.windows.conf.json+++ b/screenpipe-app-tauri/src-tauri/tauri.windows.conf.json@@ -27,4 +27,4 @@"assets/*": "./assets/"}}-}\ No newline at end of file+}