Skip to content
mtdbPublic

About

A pass extension that provides a schema to organize the metadata in yaml format

Resources

Stars

0 stars

Watchers

1 watching

Forks

Latest commit

 

History

17 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pass-meta

A pass extension that provides a schema to organize the metadata in yaml format, the idea is to have a valid yaml document within ⊥ and ⊤ delimiters, it is not relevant the content out of them, then you can edit the document following the yaml rules inside the delimiters or write without rules outside them.

Features

  • Add and copy metadata in yaml format
  • File attachment support
  • Basic TOTP support

Requirements

To install the requirements in Ubuntu or MacOS systems are:

apt install oathtool yq
brew install oath-toolkit yq

Usage

Usage:
    pass append pass-name key-name [value|file-path]
        Add a new key/value pair in the document metadata
    pass meta pass-name key-name [--clip,-c]
        Show existing key and optionally put it on the clipboard.
        If the key value is a file, it will open using the xdg-open command.

Example

pass Super/Secret

S3cr3tP4ssw0rd
this is a secret note

pass append Super/Secret username mtdb

pass Super/Secret

S3cr3tP4ssw0rd
this is a secret note
⊥
username: mtdb
⊤

pass meta Super/Secret username (use -c to copy instead show)

mtdb

pass append Super/Secret secretimage /secret/image.png (the command detects if the file exists before executing)

pass Super/Secret

S3cr3tP4ssw0rd
this is a secret note
⊥
username: mtdb
secretimage: //sFDuY8jez8H2rful.gpg
⊤

pass meta Super/Secret secretimage (show the image)

The command shows the file following the mailcap rules.

pass append Super/Secret otp BASE32SECRET3232

pass Super/Secret

S3cr3tP4ssw0rd
this is a secret note
⊥
username: mtdb
secretimage: //sFDuY8jez8H2rful.gpg
otp: BASE32SECRET3232
⊤

pass meta Super/Secret otp (assume base32 standard totp secret)

456123

Options

Set these environment variables to configure the command behavior

  • PASSWORD_STORE_META_START_DELIMITER (default: ⊥)
  • PASSWORD_STORE_META_END_DELIMITER (default: ⊤)
  • PASSWORD_STORE_ATTACHMENTS_DIR (default: $PREFIX/.attachments)
  • PASSWORD_STORE_TOTP_KEY_IDENTIFIER (default: otp)

Installation

  • Enable password-store extensions by setting PASSWORD_STORE_ENABLE_EXTENSIONS=true
  • Copy append.bash and meta.bash into ~/password-store/.extensions

Note: make sure the yq and oathtool commands are available in your console

Run tests

Ensure you have pytest installed, then run:

make test

About

A pass extension that provides a schema to organize the metadata in yaml format

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages