[pass] find command: merged to tree, but tree-command patch required

Matthew Cengia mattcen at gmail.com
Mon Apr 14 16:34:29 CEST 2014

On 2014-04-14 15:02, Jason A. Donenfeld wrote:
> Hi folks,
> We now have the long-desired find/search command:
>    http://git.zx2c4.com/password-store/commit/?id=df83c64c102fb8c22535e5fd8fd2557c19671929
> Unfortunately, we rely on a patch to tree for it:
>    http://git.zx2c4.com/password-store/tree/contrib/tree-1.6.0-matchdirs.patch
> Hopefully upstream tree will merge it, but I'm a bit doubtful. In
> event that they don't, we probably need to start talking to distros to
> popularize our patch and get it everywhere. Any ideas going forward
> with this?

Sorry, I've not really been following the purpose of the tree(1) patch
and how it pertains to searching. Nonetheless, I don't really understand
the attraction of tree(1). Yes, it gives pretty lines to show the
directory hierarchy, but other than that, it mostly sounds like a
hindrance. I'd just as soon use find(1). It's POSIX (so it'll probably
work everywhere), and it's machine parseable. You can get a greppable
lise using:

  (cd ~/.password-store/ && find -name \*.gpg)

(on top of which you can trivially build search functionality)

And a tree-like structure (without the pretty lines) using:

  (cd ~/.password-store/ && find *) | sort | sed 's|[^/]\+/| |g;s/\.gpg$//'

Just my 2 cents.

Matthew Cengia
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 966 bytes
Desc: Digital signature
URL: <http://lists.zx2c4.com/pipermail/password-store/attachments/20140415/7c577564/attachment.asc>

More information about the Password-Store mailing list