screenshot util

This commit is contained in:
Janis 2025-07-29 23:42:48 +02:00
parent f32204ffce
commit 20f793fca0
4 changed files with 43 additions and 0 deletions

View file

@ -42,6 +42,7 @@ in {
pavucontrol
ripgrep
screenshot
# nur.repos.LuisChDev.nordvpn
];
};

25
pkgs/dotfiles.nix Normal file
View file

@ -0,0 +1,25 @@
{lib, stdenv, ...}: stdenv.mkDerivation {
name = "dotfiles";
version = "0.1.0";
src = builtins.fetchGit {
url = "git@git.nirgendwo.xyz:janis/dotfiles.git";
rev = "1af2254ee4d278305d9a8b9d6eb28a4bfc79162c";
};
dontConfigure = true;
dontBuild = true;
installPhase = ''
runHook preInstall
mkdir -p $out
cp -r . $out
runHook postInstall
'';
meta = {
homepage = "https://git.nirgendwo.xyz/janis/dotfiles";
description = "My personal dotfiles";
license = lib.licenses.mit;
platforms = lib.platforms.linux;
};
}

View file

@ -1,4 +1,6 @@
final: prev: {
nordvpn = prev.callPackage ./nordvpn.nix {};
nordvpn-rofi = prev.callPackage ./nordvpn-rofi.nix {};
screenshot = prev.callPackage ./screenshot.nix {};
dotfiles = prev.callPackage ./dotfiles.nix {};
}

15
pkgs/screenshot.nix Normal file
View file

@ -0,0 +1,15 @@
{writeShellApplication, dotfiles, slurp, grim, sway, wl-clipboard, imagemagick, jq, coreutils, ...}: writeShellApplication {
name = "screenshot";
runtimeInputs = [
slurp
grim
wl-clipboard
sway
coreutils
imagemagick
jq
];
text = builtins.readFile "${dotfiles}/.local/bin/screenshot";
}