https://github.com/hernancerm/zvault
Simple file vault written in Zsh.
https://github.com/hernancerm/zvault
dotfiles encryption-decryption gpg vault zsh
Last synced: about 2 months ago
JSON representation
Simple file vault written in Zsh.
- Host: GitHub
- URL: https://github.com/hernancerm/zvault
- Owner: hernancerm
- License: mit
- Created: 2025-03-17T20:35:36.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-22T22:31:51.000Z (over 1 year ago)
- Last Synced: 2026-03-29T17:09:19.853Z (3 months ago)
- Topics: dotfiles, encryption-decryption, gpg, vault, zsh
- Language: Shell
- Homepage:
- Size: 8.79 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ZVault
Simple file vault written in Zsh.
## Sub-commands
- `store `: Encrypt files and move to destination dir, as per the config file.
- `install `: Decrypt files and move to installation dir, as per the config file.
Function pass-through: `decrypt`, `encrypt`. Used for testing.
## Configuration file
Sub-commands which use the configuration file: `store` and `install`.
The configuration file can have as many lines as needed and can be named anyway.
Each line has 3 items separated by whitespace. These 3 items are enough for `zvault` to infer data
required to both store and install. The caret symbol (`~`) can be used for the user home:
1. Full path of encrypted file. Must be suffixed with `.enc`.
2. Full path of dir where to install the decrypted file on running `install`.
3. File permissions used by `chmod`, set on both encrypted and plaintext files.
## Example usage
Given a `config` file with this single line:
```text
~/.dotfiles/vault/aws/credentials.enc ~/.aws 600
```
`zvault store config`:
- Expects `~/.aws/credentials` to exist, encrypting it to
`~/.dotfiles/vault/aws/credentials.enc` if the latter does not exist. If the
`.enc` file was created, set its permissions with `chmod`.
`zvault install config`:
- Expects `~/.dotfiles/vault/aws/credentials.enc` to exist, decrypting it to
`~/.aws/credentials` if the latter does not exist. If the plaintext file was
created, set its permissions with `chmod`.