home/pkgs/qrclip/default.nix

7 lines
203 B
Nix

{ pkgs }:
let zbar = pkgs.mypkgs.zbar.override { enableVideo = false; };
in pkgs.writeShellScriptBin "qrclip" ''
set -eo pipefail
${pkgs.pngpaste}/bin/pngpaste - | ${zbar}/bin/zbarimg --raw -q1 -
''