On 2019-11-26 at 10:11:31, Liberius Clavus ([email protected]) wrote:
>
> Matthias Braun <[email protected]> writes:
>
> > I'd like to open a password entry using NeoVim in a terminal window.
> >
> > This is my current script:
> >
> > #!/usr/bin/env bash
> >
> > shopt -s nullglob globstar
> >
> > prefix=${PASSWORD_STORE_DIR-~/.password-store}
> > password_files=( "$prefix"/**/*.gpg )
> >
> > # Remove the password store directories from its entries
> > password_files=( "${password_files[@]#"$prefix"/}" )
> > # Remove the ".gpg" ending
> > password_files=( "${password_files[@]%.gpg}" )
> >
> > password_entry=$(printf '%s\n' "${password_files[@]}" | rofi -dmenu
> > "$@")
> >
> > [[ -n $password_entry ]] || exit
> >
> > pass edit "$password_entry"
> >
> > What I'd like to do is make `pass edit` open a new instance of termite (my
> > terminal emulator) and pass the temporary file containing the password
> > entry to NeoVim.
>
> From what I understand when you select the entry from dmenu you want it
> to open a terminal emulator and edit that pass entry. If that's the case
> then you should read the manual for termite.
>
> For urxvt and xterm you can do, `urxvt/xterm -e sh -c "pass edit
> entry"`. Does this work on termite?
>
> --
> Liberius Clavus
Thanks Liberius Clavus, I figured it out:
# This opens the entry in the $EDITOR inside a new termite instance
termite -e "pass edit "$password_entry"" 2> /dev/null
> _______________________________________________
> Password-Store mailing list
> [email protected]
> https://lists.zx2c4.com/mailman/listinfo/password-store
_______________________________________________
Password-Store mailing list
[email protected]
https://lists.zx2c4.com/mailman/listinfo/password-store