Skip to content

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

perf: skip frontend rebuild for beta builds, fix find grouping

Louis Beaumonte4d46ad48d01
diff --git a/.github/workflows/release-app.yml b/.github/workflows/release-app.yml
index 6f28f1d75..5d16ca089 100644
--- a/.github/workflows/release-app.yml
+++ b/.github/workflows/release-app.yml
@@ -924,7 +924,8 @@ jobs:
$bundleNsis = "target\x86_64-pc-windows-msvc\release\bundle\nsis"
if (Test-Path $bundleNsis) { Remove-Item -Recurse -Force $bundleNsis }
Push-Location ..
- # Skip vulkan for now — ExternalProject can't find cl.exe on GH runners
+ # Skip frontend rebuild (already built for stable) and vulkan
+ $env:TAURI_CLI_CONFIG = '{"build":{"beforeBuildCommand":""}}'
bunx tauri build --target x86_64-pc-windows-msvc --features mkl,official-build
Pop-Location
Write-Host "=== Beta rebuild complete ==="
@@ -979,16 +980,16 @@ jobs:
MACOSX_DEPLOYMENT_TARGET: "10.15"
run: |
echo "=== Rebuilding with beta config ==="
- # Swap to beta config (Rust is already compiled, this just repackages)
+ # Swap to beta config
cp apps/screenpipe-app-tauri/src-tauri/tauri.beta.conf.json apps/screenpipe-app-tauri/src-tauri/tauri.conf.json
- # Clean ALL bundle artifacts so only beta artifacts exist for upload
+ # Only remove bundle outputs (NOT cargo cache). Use parens to group -o conditions properly.
find apps/screenpipe-app-tauri/src-tauri/target -type d -name "bundle" -exec rm -rf {} + 2>/dev/null || true
- # Also remove any .dmg, .app.tar.gz, .sig files from previous build
- find apps/screenpipe-app-tauri/src-tauri/target -name "*.dmg" -o -name "*.app.tar.gz" -o -name "*.sig" -o -name "*.nsis*" | xargs rm -f 2>/dev/null || true
+ find apps/screenpipe-app-tauri/src-tauri/target \( -name "*.dmg" -o -name "*.app.tar.gz" -o -name "*.sig" -o -name "*.nsis*" \) -type f -delete 2>/dev/null || true
+ # Skip frontend rebuild — already built for stable, beta uses same frontend
+ # Override beforeBuildCommand to no-op so tauri doesn't re-run bun run build
cd apps/screenpipe-app-tauri
- bunx tauri build ${{ steps.tauri-args.outputs.args || matrix.tauri-args }}
+ TAURI_CLI_CONFIG='{"build":{"beforeBuildCommand":""}}' bunx tauri build ${{ steps.tauri-args.outputs.args || matrix.tauri-args }}
echo "=== Beta rebuild complete ==="
- # Verify only beta artifacts exist
echo "Beta artifacts:"
find src-tauri/target -name "*.dmg" -o -name "*.app.tar.gz" -o -name "*.exe" 2>/dev/null
diff --git a/apps/screenpipe-app-tauri/components/rewind/timeline.tsx b/apps/screenpipe-app-tauri/components/rewind/timeline.tsx
index 1b3814833..a1d38c590 100644
--- a/apps/screenpipe-app-tauri/components/rewind/timeline.tsx
+++ b/apps/screenpipe-app-tauri/components/rewind/timeline.tsx
@@ -613,79 +613,73 @@ export default function Timeline() {
return () => { unlisten.then((fn) => fn()); };
}, [showSearchModal]);
- // Suspend/resume arrow shortcuts when search modal opens/closes
+ // Handle arrow key navigation via JS keydown (no global hotkey stealing)
useEffect(() => {
- if (showSearchModal) {
- commands.suspendArrowShortcuts().catch(() => {});
- } else {
- commands.resumeArrowShortcuts().catch(() => {});
- }
- }, [showSearchModal]);
+ const handleArrowKeys = (e: KeyboardEvent) => {
+ // Skip when search modal is open (it has its own arrow handling)
+ if (showSearchModal) return;
- // Suspend arrow shortcuts when any text input is focused (AI panel, etc.)
- // so arrow keys work normally for cursor movement in text fields
- useEffect(() => {
- const handleFocusIn = (e: FocusEvent) => {
+ // Skip when a text input is focused (let cursor movement work normally)
const target = e.target as HTMLElement;
if (target instanceof HTMLInputElement || target instanceof HTMLTextAreaElement || target.isContentEditable) {
- commands.suspendArrowShortcuts().catch(() => {});
+ return;
}
- };
- const handleFocusOut = (e: FocusEvent) => {
- const target = e.target as HTMLElement;
- if (target instanceof HTMLInputElement || target instanceof HTMLTextAreaElement || target.isContentEditable) {
- // Only resume if search modal isn't open
- if (!showSearchModal) {
- commands.resumeArrowShortcuts().catch(() => {});
+
+ const isAlt = e.altKey;
+ if (e.key === "ArrowLeft") {
+ e.preventDefault();
+ if (isAlt) {
+ // Alt+ArrowLeft = prev app boundary
+ setCurrentIndex((prev) => {
+ const currentApp = getFrameAppName(frames[prev]);
+ let i = prev + 1;
+ while (i < frames.length) {
+ if (getFrameAppName(frames[i]) !== currentApp) {
+ if (frames[i]) setCurrentFrame(frames[i]);
+ return i;
+ }
+ i++;
+ }
+ return prev;
+ });
+ } else {
+ // ArrowLeft = prev frame
+ setCurrentIndex((prev) => {
+ const next = Math.min(prev + 1, frames.length - 1);
+ if (frames[next]) setCurrentFrame(frames[next]);
+ return next;
+ });
+ }
+ } else if (e.key === "ArrowRight") {
+ e.preventDefault();
+ if (isAlt) {
+ // Alt+ArrowRight = next app boundary
+ setCurrentIndex((prev) => {
+ const currentApp = getFrameAppName(frames[prev]);
+ let i = prev - 1;
+ while (i >= 0) {
+ if (getFrameAppName(frames[i]) !== currentApp) {
+ if (frames[i]) setCurrentFrame(frames[i]);
+ return i;
+ }
+ i--;
+ }
+ return prev;
+ });
+ } else {
+ // ArrowRight = next frame
+ setCurrentIndex((prev) => {
+ const next = Math.max(prev - 1, 0);
+ if (frames[next]) setCurrentFrame(frames[next]);
+ return next;
+ });
}
}
};
- document.addEventListener("focusin", handleFocusIn);
- document.addEventListener("focusout", handleFocusOut);
- return () => {
- document.removeEventListener("focusin", handleFocusIn);
- document.removeEventListener("focusout", handleFocusOut);
- };
- }, [showSearchModal]);
- // Handle arrow key navigation from Rust global shortcuts
- useEffect(() => {
- const unlisten = listen<string>("timeline-navigate", (event) => {
- const dir = event.payload;
- if (dir === "prev-frame") {
- setCurrentIndex((prev) => {
- const next = Math.min(prev + 1, frames.length - 1);
- if (frames[next]) setCurrentFrame(frames[next]);
- return next;
- });
- } else if (dir === "next-frame") {
- setCurrentIndex((prev) => {
- const next = Math.max(prev - 1, 0);
- if (frames[next]) setCurrentFrame(frames[next]);
- return next;
- });
- } else if (dir === "prev-app" || dir === "next-app") {
- setCurrentIndex((prev) => {
- const currentApp = getFrameAppName(frames[prev]);
- // prev-app = go back in time = increase index
- // next-app = go forward in time = decrease index
- const step = dir === "prev-app" ? 1 : -1;
- let i = prev + step;
- // Skip frames with the same app to find the boundary
- while (i >= 0 && i < frames.length) {
- const app = getFrameAppName(frames[i]);
- if (app !== currentApp) {
- if (frames[i]) setCurrentFrame(frames[i]);
- return i;
- }
- i += step;
- }
- return prev; // no boundary found
- });
- }
- });
- return () => { unlisten.then((fn) => fn()); };
- }, [frames, setCurrentFrame]);
+ window.addEventListener("keydown", handleArrowKeys);
+ return () => window.removeEventListener("keydown", handleArrowKeys);
+ }, [frames, setCurrentFrame, showSearchModal]);
useEffect(() => {
const getStartDateAndSet = async () => {
diff --git a/apps/screenpipe-app-tauri/lib/utils/tauri.ts b/apps/screenpipe-app-tauri/lib/utils/tauri.ts
index 3ba15391c..5ea3b5c3f 100644
--- a/apps/screenpipe-app-tauri/lib/utils/tauri.ts
+++ b/apps/screenpipe-app-tauri/lib/utils/tauri.ts
@@ -250,28 +250,6 @@ async unregisterWindowShortcuts() : Promise<Result<null, string>> {
else return { status: "error", error: e as any };
}
},
-/**
- * Suspend arrow shortcuts (called from JS when search/chat modal opens)
- */
-async suspendArrowShortcuts() : Promise<Result<null, string>> {
- try {
- return { status: "ok", data: await TAURI_INVOKE("suspend_arrow_shortcuts") };
-} catch (e) {
- if(e instanceof Error) throw e;
- else return { status: "error", error: e as any };
-}
-},
-/**
- * Resume arrow shortcuts (called from JS when search/chat modal closes)
- */
-async resumeArrowShortcuts() : Promise<Result<null, string>> {
- try {
- return { status: "ok", data: await TAURI_INVOKE("resume_arrow_shortcuts") };
-} catch (e) {
- if(e instanceof Error) throw e;
- else return { status: "error", error: e as any };
-}
-},
/**
* Get the version of the backed-up app (if any), so the UI can show a rollback button
*/
diff --git a/apps/screenpipe-app-tauri/src-tauri/Cargo.lock b/apps/screenpipe-app-tauri/src-tauri/Cargo.lock
index 0346fd422..31b13fdff 100755
--- a/apps/screenpipe-app-tauri/src-tauri/Cargo.lock
+++ b/apps/screenpipe-app-tauri/src-tauri/Cargo.lock
@@ -8719,7 +8719,7 @@ dependencies = [
[[package]]
name = "screenpipe-app"
-version = "2.0.427"
+version = "2.0.428"
dependencies = [
"anyhow",
"async-stream",
diff --git a/apps/screenpipe-app-tauri/src-tauri/src/commands.rs b/apps/screenpipe-app-tauri/src-tauri/src/commands.rs
index 83fca8dc2..e9428f79f 100644
--- a/apps/screenpipe-app-tauri/src-tauri/src/commands.rs
+++ b/apps/screenpipe-app-tauri/src-tauri/src/commands.rs
@@ -756,11 +756,7 @@ pub fn register_window_shortcuts(app_handle: tauri::AppHandle) -> Result<(), Str
// Having it in both places caused it to be unregistered globally when the window
// closed, breaking Ctrl+Cmd+K entirely until app restart.
- // Register arrow key shortcuts for timeline navigation
- // Plain arrows = frame step, Alt+arrows = app-boundary jump
- register_arrow_shortcuts(app_handle.clone())?;
-
- info!("Window-specific shortcuts registered (Escape, arrows)");
+ info!("Window-specific shortcuts registered (Escape)");
Ok(())
}
@@ -783,87 +779,11 @@ pub fn unregister_window_shortcuts(app_handle: tauri::AppHandle) -> Result<(), S
// hides. Previously unregistering it here killed the global registration,
// causing Ctrl+Cmd+K to stop working entirely after pressing Escape.
- // Unregister arrow key shortcuts (these are window-only, safe to remove)
- unregister_arrow_shortcuts(&app_handle)?;
-
info!("Window-specific shortcuts unregistered");
Ok(())
}
-/// Register arrow key shortcuts for timeline frame navigation
-/// Plain arrows = frame step, Alt+arrows = app-boundary jump
-fn register_arrow_shortcuts(app_handle: tauri::AppHandle) -> Result<(), String> {
- use tauri_plugin_global_shortcut::{Code, GlobalShortcutExt, Modifiers, Shortcut, ShortcutState};
- use tauri::Emitter;
-
- let gs = app_handle.global_shortcut();
-
- // ArrowLeft = prev frame
- let left = Shortcut::new(None, Code::ArrowLeft);
- let app = app_handle.clone();
- if let Err(e) = gs.on_shortcut(left, move |_app, _, event| {
- if matches!(event.state, ShortcutState::Pressed) {
- let _ = app.emit("timeline-navigate", "prev-frame");
- }
- }) {
- if !e.to_string().contains("already registered") {
- error!("Failed to register ArrowLeft shortcut: {}", e);
- }
- }
-
- // ArrowRight = next frame
- let right = Shortcut::new(None, Code::ArrowRight);
- let app = app_handle.clone();
- if let Err(e) = gs.on_shortcut(right, move |_app, _, event| {
- if matches!(event.state, ShortcutState::Pressed) {
- let _ = app.emit("timeline-navigate", "next-frame");
- }
- }) {
- if !e.to_string().contains("already registered") {
- error!("Failed to register ArrowRight shortcut: {}", e);
- }
- }
-
- // Alt+ArrowLeft = prev app boundary
- let alt_left = Shortcut::new(Some(Modifiers::ALT), Code::ArrowLeft);
- let app = app_handle.clone();
- if let Err(e) = gs.on_shortcut(alt_left, move |_app, _, event| {
- if matches!(event.state, ShortcutState::Pressed) {
- let _ = app.emit("timeline-navigate", "prev-app");
- }
- }) {
- if !e.to_string().contains("already registered") {
- error!("Failed to register Alt+ArrowLeft shortcut: {}", e);
- }
- }
-
- // Alt+ArrowRight = next app boundary
- let alt_right = Shortcut::new(Some(Modifiers::ALT), Code::ArrowRight);
- let app = app_handle.clone();
- if let Err(e) = gs.on_shortcut(alt_right, move |_app, _, event| {
- if matches!(event.state, ShortcutState::Pressed) {
- let _ = app.emit("timeline-navigate", "next-app");
- }
- }) {
- if !e.to_string().contains("already registered") {
- error!("Failed to register Alt+ArrowRight shortcut: {}", e);
- }
- }
-
- Ok(())
-}
-
-/// Unregister arrow key shortcuts
-fn unregister_arrow_shortcuts(app_handle: &tauri::AppHandle) -> Result<(), String> {
- use tauri_plugin_global_shortcut::{Code, GlobalShortcutExt, Modifiers, Shortcut};
- let gs = app_handle.global_shortcut();
- let _ = gs.unregister(Shortcut::new(None, Code::ArrowLeft));
- let _ = gs.unregister(Shortcut::new(None, Code::ArrowRight));
- let _ = gs.unregister(Shortcut::new(Some(Modifiers::ALT), Code::ArrowLeft));
- let _ = gs.unregister(Shortcut::new(Some(Modifiers::ALT), Code::ArrowRight));
- Ok(())
-}
/// Get the version of the backed-up app (if any), so the UI can show a rollback button
#[tauri::command]
@@ -906,16 +826,3 @@ pub async fn rollback_to_previous_version(
Ok(())
}
-/// Suspend arrow shortcuts (called from JS when search/chat modal opens)
-#[tauri::command]
-#[specta::specta]
-pub fn suspend_arrow_shortcuts(app_handle: tauri::AppHandle) -> Result<(), String> {
- unregister_arrow_shortcuts(&app_handle)
-}
-
-/// Resume arrow shortcuts (called from JS when search/chat modal closes)
-#[tauri::command]
-#[specta::specta]
-pub fn resume_arrow_shortcuts(app_handle: tauri::AppHandle) -> Result<(), String> {
- register_arrow_shortcuts(app_handle)
-}
\ No newline at end of file
diff --git a/apps/screenpipe-app-tauri/src-tauri/src/main.rs b/apps/screenpipe-app-tauri/src-tauri/src/main.rs
index 64888c169..da25f524d 100755
--- a/apps/screenpipe-app-tauri/src-tauri/src/main.rs
+++ b/apps/screenpipe-app-tauri/src-tauri/src/main.rs
@@ -1107,8 +1107,6 @@ async fn main() {
// Window-specific shortcut commands (dynamic registration)
commands::register_window_shortcuts,
commands::unregister_window_shortcuts,
- commands::suspend_arrow_shortcuts,
- commands::resume_arrow_shortcuts,
// Rollback commands
commands::get_rollback_version,
commands::rollback_to_previous_version,
@@ -1281,8 +1279,6 @@ async fn main() {
// Window-specific shortcut commands (dynamic registration)
commands::register_window_shortcuts,
commands::unregister_window_shortcuts,
- commands::suspend_arrow_shortcuts,
- commands::resume_arrow_shortcuts,
// Overlay commands (Windows)
commands::enable_overlay_click_through,
commands::disable_overlay_click_through,