nixos/frigate: use upstream grep command for LIBAVFORMAT_VERSION_MAJOR

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Bakhtiyar Neyman
2026-02-24 23:20:34 -08:00
co-authored by Claude Opus 4.6
parent 2e7ea69665
commit f83cd5b0ac
+1 -3
View File
@@ -704,9 +704,7 @@ in
LIBAVFORMAT_VERSION_MAJOR = lib.strings.trim (
builtins.readFile (
pkgs.runCommandLocal "libavformat-major-version" { } ''
${cfg.settings.ffmpeg.path}/bin/ffmpeg -version 2>&1 \
| sed -n 's/.*libavformat[[:space:]]*\([0-9]*\).*/\1/p' \
| head -1 > $out
${cfg.settings.ffmpeg.path}/bin/ffmpeg -version | grep -Po "libavformat\W+\K\d+" > $out
''
)
);