From c2ddd6e720ee86f8b601b1ba7974c45ab29993ef Mon Sep 17 00:00:00 2001 From: ItsDrike Date: Fri, 21 Jun 2024 11:52:39 +0200 Subject: [PATCH] Add wayland applications for screenshot/video taking --- home/packages/cli/wayland.nix | 30 +++++++++++++++++++++++++++++- home/packages/gui/wayland.nix | 3 ++- 2 files changed, 31 insertions(+), 2 deletions(-) diff --git a/home/packages/cli/wayland.nix b/home/packages/cli/wayland.nix index 7e3c31e..3dbf6d9 100644 --- a/home/packages/cli/wayland.nix +++ b/home/packages/cli/wayland.nix @@ -8,7 +8,35 @@ in { config = mkIf osConfig.myOptions.home-manager.wms.isWayland { home.packages = with pkgs; [ - wl-clipboard + wl-clipboard # clipboard interactions + grim # grab images + slurp # select a region + wf-recorder # screen recording + + # Grabs text from screenshot image + (pkgs.writeShellApplication { + name = "ocr"; + runtimeInputs = with pkgs; [tesseract grim slurp coreutils]; + text = '' + echo "Generating a random ID..." + id=$(tr -dc 'a-zA-Z0-9'