<p dir="ltr">Great idea!<br>
Is the echo necessary?<br>
Brian</p>
<div class="gmail_quote">On Jun 27, 2014 12:47 PM, "Christoph Egger" <<a href="mailto:christoph@christoph-egger.org">christoph@christoph-egger.org</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Ahoi!<br>
<br>
  I've built a NIH version of the dmenu script with one -- in my opinion<br>
quite important -- difference: Instead of using the clipboard  it just<br>
use `xdotool` to actually type the password. I've attached the script if<br>
someone's interested.<br>
<br>
  Christoph<br>
<br>
<br>#!/bin/bash<br>
<br>
list_passwords() {<br>
        basedir=~/.password-store/<br>
        passwords=( ~/.password-store/**/*.gpg ~/.password-store/*.gpg )<br>
        for password in "${passwords[@]}"<br>
        do<br>
                filename="${password#$basedir}"<br>
                filename="${filename%.gpg}"<br>
                echo $filename<br>
        done<br>
}<br>
<br>
xdotool_command() {<br>
        echo -n "type "<br>
        pass "$1"<br>
}<br>
<br>
selected_password="$(list_passwords 2>/dev/null| dmenu)"<br>
<br>
echo $selected_password<br>
if [ -n "$selected_password" ]<br>
then<br>
        xdotool_command "$selected_password" | xdotool -<br>
fi<br>
<br>_______________________________________________<br>
Password-Store mailing list<br>
<a href="mailto:Password-Store@lists.zx2c4.com">Password-Store@lists.zx2c4.com</a><br>
<a href="http://lists.zx2c4.com/mailman/listinfo/password-store" target="_blank">http://lists.zx2c4.com/mailman/listinfo/password-store</a><br>
<br></blockquote></div>