10 rustPlatform.buildRustPackage rec {
14 src = fetchFromGitHub {
16 repo = "subtitles-rs";
17 rev = "substudy_v${version}";
18 hash = "sha256-ACYbSQKaOJ2hS8NbOAppfKo+Mk3CKg0OAwb56AH42Zs=";
22 lockFile = ./Cargo.lock;
24 "async-openai-0.19.1" = "sha256-UrWSZW3LxMZfinmQAjouhqTrhVhHkjgz9EzrZxR0qG4=";
28 nativeBuildInputs = [ makeWrapper ];
30 nativeCheckInputs = [ ffmpeg ];
32 cargoBuildFlags = [ "-p substudy" ];
35 # That's to make sure the `test_ai_request_static`
36 # test has access to the cache at `$HOME/.cache`
37 export HOME=$(mktemp -d)
41 wrapProgram "$out/bin/substudy" \
42 --prefix PATH : ${lib.makeBinPath [ ffmpeg ]}
46 description = "Learn foreign languages using audio and subtitles extracted from video files";
47 homepage = "http://www.randomhacks.net/substudy";
48 license = licenses.asl20;
49 mainProgram = "substudy";
50 maintainers = with maintainers; [ paveloom ];