diff --git a/configuration.nix b/configuration.nix index 3ec957e..ac78f15 100644 --- a/configuration.nix +++ b/configuration.nix @@ -76,23 +76,6 @@ ]; }; - # yt-transcribe-watcher: scans reclip's download dir (media/video on the - # Unraid share) every 5 min and transcribes new media files (Whisper — a - # bare download carries no captions). Runs the nix-store copy through a - # stable ~/.local/bin symlink — launchd can neither exec from the SMB share - # (EPERM) nor reach into TCC-protected ~/Documents. Silent exit when the - # share is unmounted. - launchd.user.agents."yt-transcribe-watcher" = { - command = "/Users/laptran/.local/bin/yt-transcribe-watcher"; - serviceConfig = { - StartInterval = 300; - StandardOutPath = "/tmp/yt-transcribe-watcher.out"; - StandardErrorPath = "/tmp/yt-transcribe-watcher.err"; - EnvironmentVariables = { - HOME = "/Users/laptran"; - PATH = "/usr/bin:/bin:/usr/sbin:/sbin"; - }; - }; - }; + launchd.user.agents = { }; } diff --git a/home.nix b/home.nix index b2c9796..70fd781 100644 --- a/home.nix +++ b/home.nix @@ -10,7 +10,6 @@ let # ~/.local/bin symlinks below survive store-path changes between rebuilds. ytTranscribe = pkgs.runCommand "yt-transcribe" { } '' install -Dm755 ${./home/bin/yt-transcribe} $out/bin/yt-transcribe - install -Dm755 ${./home/bin/yt-transcribe-watcher} $out/bin/yt-transcribe-watcher ''; in @@ -204,15 +203,12 @@ in source = config.lib.file.mkOutOfStoreSymlink "${dotfiles}/home/bin/security-audit-sandbox"; force = true; }; - # Stable symlinks for yt-transcribe: launchd and shells exec these from local - # disk. The repo's home/bin scripts are the source of truth — a repo edit - # takes effect on the next rebuild; the Unraid share holds only data. + # Stable symlink for yt-transcribe: shells exec it from local disk. The + # repo's home/bin script is the source of truth — a repo edit takes effect + # on the next rebuild; the Unraid share holds only data. home.file.".local/bin/yt-transcribe" = { source = "${ytTranscribe}/bin/yt-transcribe"; }; - home.file.".local/bin/yt-transcribe-watcher" = { - source = "${ytTranscribe}/bin/yt-transcribe-watcher"; - }; home.file.".grok/AGENTS.md" = { source = config.lib.file.mkOutOfStoreSymlink "${dotfiles}/home/AGENTS.md"; force = true; diff --git a/home/bin/yt-transcribe b/home/bin/yt-transcribe index 97801ac..71429d0 100755 --- a/home/bin/yt-transcribe +++ b/home/bin/yt-transcribe @@ -35,7 +35,7 @@ # YT_TRANSCRIBE_ROOT (transcript root), YT_MEDIA_DIR (reclip download dir), # YT_COOKIES (cookies.txt for yt-dlp/gallery-dl). # Index: `yt-transcribe --list` prints id->title mapping; --index rewrites -# INDEX.md next to the transcripts; both modes + the watcher refresh it. +# INDEX.md next to the transcripts; both modes refresh it after each run. # ============================================================================ set -euo pipefail @@ -106,7 +106,7 @@ for dirpath, dirs, files in os.walk(scan_dir): mt = time.strftime("%Y-%m-%d", time.localtime(os.path.getmtime(p))) L.append(f"| `{clean(fn)}` | {mt} |") if not found: - L.append("| _(none yet — the watcher adds one per download)_ | |") + L.append("| _(none yet — patched reclip or manual file-mode runs add one per download)_ | |") print("\n".join(L)) PY }