1
0
mirror of https://github.com/kmein/niveum synced 2026-03-18 11:01:07 +01:00

configure niri

This commit is contained in:
2025-08-26 07:19:54 +02:00
parent d0ac0af7c3
commit f08e43067b
9 changed files with 415 additions and 583 deletions

18
packages/passmenu.nix Normal file
View File

@@ -0,0 +1,18 @@
{ writers, wofi, pass, libnotify, ... }:
writers.writeBashBin "passmenu" ''
shopt -s nullglob globstar
IFS=$'\n'
prefix=$(readlink -f $${PASSWORD_STORE_DIR-~/.password-store})
password_files=( $( fd -L ".gpg\$" "$prefix" ) )
password_files=( "$${password_files[@]#"$prefix"/}" )
password_files=( "$${password_files[@]%.gpg}" )
password=$( printf '%s\n' "$${password_files[@]}" | ${wofi}/bin/wofi -i -k /dev/null -d menu -- "$@" )
[[ -n $password ]] || exit
OUT=$(${pass}/bin/pass show --clip "$password")
${libnotify}/bin/notify-send -t 5000 "$(echo "$OUT" | grep '^login:' | sed 's/^login: //')"
''