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

fix slash swift path

Louis Beaumontf89564bca91b
diff --git a/screenpipe-actions/src/run.rs b/screenpipe-actions/src/run.rs
index 120d99be7..fed4c44c8 100644
--- a/screenpipe-actions/src/run.rs
+++ b/screenpipe-actions/src/run.rs
@@ -1,6 +1,7 @@
use crate::type_and_animate::{delete_characters, type_slowly, EnigoCommand};
use crate::{call_ai, run_keystroke_monitor, KeystrokeCommand};
use reqwest;
+use std::path::Path;
use std::string::ToString;
use std::sync::atomic::{AtomicBool, Ordering};
use std::sync::Arc;
@@ -418,7 +419,24 @@ printAllAttributeValuesForCurrentApp()
"#;
info!("running swift script");
- let mut child = Command::new("swift")
+
+ // Check multiple possible Swift paths
+ let swift_paths = [
+ "/usr/bin/swift", // Common path for both Intel and Apple Silicon
+ "/usr/local/bin/swift", // Possible alternative location
+ "/opt/homebrew/bin/swift", // Homebrew path on Apple Silicon
+ ];
+
+ let swift_path = swift_paths
+ .iter()
+ .find(|&path| Path::new(path).exists())
+ .ok_or_else(|| {
+ anyhow::anyhow!("Swift executable not found in any of the expected locations")
+ })?;
+
+ info!("using swift at: {}", swift_path);
+
+ let mut child = Command::new(swift_path)
.arg("-") // Read from stdin
.stdin(std::process::Stdio::piped())
.stdout(std::process::Stdio::piped())
diff --git a/screenpipe-app-tauri/components/recording-settings.tsx b/screenpipe-app-tauri/components/recording-settings.tsx
index eb2decfe1..d76f2e766 100644
--- a/screenpipe-app-tauri/components/recording-settings.tsx
+++ b/screenpipe-app-tauri/components/recording-settings.tsx
@@ -1243,18 +1243,23 @@ export function RecordingSettings({
</TooltipTrigger>
<TooltipContent side="right">
<p>
- ⚠️ uses our hosted AI service (powered by OpenAI) ⚠️
+ ⚠️ uses screenpipe cloud ⚠️
<br />
• we provide free ChatGPT credits
<br />
- • may have privacy implications (data sent to our
- servers)
+ • may have privacy implications read our data privacy
+ policy at
<br />
- enables experimental features like double slash
- <br />
- which you can use to autocomplete anywhere
+ <a
+ href="https://screenpi.pe/privacy"
+ target="_blank"
+ rel="noopener noreferrer"
+ className="text-primary hover:underline"
+ >
+ https://screenpi.pe/privacy
+ </a>
<br />
- by pressing twice on slash or stop it with pressing q
+ enables experimental features like double slash
<br />
(only tested on US or German qwertz keyboards)
</p>
diff --git a/screenpipe-app-tauri/src-tauri/Cargo.toml b/screenpipe-app-tauri/src-tauri/Cargo.toml
index c6e18db78..9354239d3 100644
--- a/screenpipe-app-tauri/src-tauri/Cargo.toml
+++ b/screenpipe-app-tauri/src-tauri/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "screenpipe-app"
-version = "0.5.5"
+version = "0.5.6"
description = ""
authors = ["you"]
license = ""