This repository has no description
486 B
26 lines
1{
2 pkgs,
3 pinentry-auto ? pkgs.callPackage ../pinentry-auto/package.nix { },
4 ...
5}:
6let
7 python = pkgs.python3.withPackages (
8 ps: with ps; [
9 beautifulsoup4
10 ]
11 );
12in
13pkgs.writeShellApplication {
14 name = "kagi-search";
15 runtimeInputs = [
16 python
17 pkgs.rbw
18 ];
19 text = ''
20 if ! rbw unlocked 2>/dev/null; then
21 rbw config set pinentry ${pinentry-auto}/bin/pinentry-auto
22 rbw unlock
23 fi
24 ${python}/bin/python ${./kagi_search.py} "$@"
25 '';
26}