diff options
-rwxr-xr-x | bin/P | 24 | ||||
-rwxr-xr-x | bin/dmenu_run.sh | 3 | ||||
-rw-r--r-- | i3/config | 2 | ||||
-rw-r--r-- | xbindkeysrc-pincer | 15 |
4 files changed, 43 insertions, 1 deletions
@@ -0,0 +1,24 @@ +#!/usr/bin/env bash + +shopt -s nullglob globstar + +typeit=0 +if [[ $1 == "--type" ]]; then + typeit=1 + shift +fi + +prefix=${PASSWORD_STORE_DIR-~/.password-store} +password_files=( "$prefix"/**/*.gpg ) +password_files=( "${password_files[@]#"$prefix"/}" ) +password_files=( "${password_files[@]%.gpg}" ) + +password=$(printf '%s\n' "${password_files[@]}" | dmenu -fn "-*-*-*-*-*-*-20-*-*-*-*-*-*-*" "$@") + +[[ -n $password ]] || exit + +if [[ $typeit -eq 0 ]]; then + pass show -c "$password" 2>/dev/null +else + xdotool - <<<"type --clearmodifiers -- $(pass show "$password" | head -n 1)" +fi diff --git a/bin/dmenu_run.sh b/bin/dmenu_run.sh new file mode 100755 index 0000000..5469246 --- /dev/null +++ b/bin/dmenu_run.sh @@ -0,0 +1,3 @@ +#!/bin/bash +PATH=$HOME/dotfiles/bin:$PATH dmenu_run -fn -*-*-*-*-*-*-20-*-*-*-*-*-*-* "$@" + @@ -25,7 +25,7 @@ bindsym Pause exec i3lock -c 2A3462 bindsym Mod4+Shift+q kill # start dmenu (a program launcher) -bindsym Mod4+d exec dmenu_run -fn -*-*-*-*-*-*-20-*-*-*-*-*-*-* +bindsym Mod4+d exec /home/orbekk/dotfiles/bin/dmenu_run.sh # change focus bindsym Mod4+h focus left diff --git a/xbindkeysrc-pincer b/xbindkeysrc-pincer index ecf693f..6b5cc7f 100644 --- a/xbindkeysrc-pincer +++ b/xbindkeysrc-pincer @@ -3,3 +3,18 @@ "xbacklight -dec 20" XF86MonBrightnessDown + +"amixer -c 1 set Master 1dB-" + XF86AudioLowerVolume + +"amixer -c 1 set Master 1dB+" + XF86AudioRaiseVolume + +"amixer -c 1 set Master toggle" + XF86AudioMute + +"amixer -c 1 set Mic toggle" + XF86AudioMicMute + +"i3lock -c 2A3462" + XF86Tools |