Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lahr/pass-csv
pass extension to generate a CSV summary from key-value pairs
https://github.com/lahr/pass-csv
Last synced: 2 days ago
JSON representation
pass extension to generate a CSV summary from key-value pairs
- Host: GitHub
- URL: https://github.com/lahr/pass-csv
- Owner: lahr
- License: gpl-3.0
- Created: 2021-02-01T19:38:02.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2021-02-09T19:08:08.000Z (almost 4 years ago)
- Last Synced: 2024-08-03T02:02:49.028Z (3 months ago)
- Language: Shell
- Homepage:
- Size: 15.6 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-password-store - pass-csv - value pairs in the metadata. (Extensions / Output)
README
# pass csv
An extension for the [standard unix password manager](https://www.passwordstore.org) that generates a CSV file from specified key-value pairs in the metadata. A use case for `pass csv` could be to generate a summary to which service you gave your address and phone number across the password store.
A password file can store arbitrary information in the lines after the password:
```
Yw|ZSNH!}z"6{ym9pI
URL: *.amazon.com/*
Username: [email protected]
has-address: true
has-tel: false
Account Created: 2021-02-01
````pass csv key1 key2 ...` iterates over the password store, searches for the specified keys and prints their value. The key-value pairs in the password files must be colon-delimited. The password itself is never read. The first column is always the name of the password file. If a specified key is not found in a password file, the corresponding value in the CSV is `-`.
## Example
`pass csv has-addr has-tel "Account Created" > summary.csv` generates the following CSV file:
```
"name","has-addr","has-tel","Account Created"
"amazon.com","true","false","2021-02-01"
"google.com","false","true","-"
```| name | has-addr | has-tel | Account Created |
| :--------- | :------: | :-----: | :-------------: |
| amazon.com | true | false | 2021-02-01 |
| google.com | false | true | - |## Installation
- `make install`
- On MacOS via Homebrew with [this tap](https://github.com/SimplyDanny/homebrew-pass-extensions/)
- Alternatively, you can copy `src/csv.bash` to `~/.password-store/.extensions`, make it executable and set the `PASSWORD_STORE_ENABLE_EXTENSIONS` environment variable to `true`.