Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mpwsh/byteme
file compression/decompression and z85 encoding/decoding to store binary files as text
https://github.com/mpwsh/byteme
Last synced: 10 days ago
JSON representation
file compression/decompression and z85 encoding/decoding to store binary files as text
- Host: GitHub
- URL: https://github.com/mpwsh/byteme
- Owner: mpwsh
- Created: 2022-10-04T22:48:49.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2023-11-05T22:31:27.000Z (about 1 year ago)
- Last Synced: 2024-10-12T01:33:12.160Z (about 1 month ago)
- Language: Rust
- Homepage:
- Size: 28.3 KB
- Stars: 1
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
## Description
Compress/Decompress, Encode and Decode any file to a z85 string.
Useful to store binaries in text format, for NFC cards/stickers/keychains or anywhere you want.## Build
```bash
#Build
❯ cargo build --release
```## Usage
Compress a file and encode bytes to z85
```bash
#Create a test file
echo "This is a test" >> raw.txt
#Process
❯ ./target/release/byteme raw.txt
#Output
C?JLE:sHu(Qc%Y#!z.8[04z%)###00
```Decode z85 and decompress back to original file
```bash
#Decode
❯ echo 'C?JLE:sHu(Qc%Y#!z.8[04z%)###00' | ./target/release/byteme out.txt
#Check your new file
❯ cat out.txt
This is a test
```## Encryption
Encrypt a file using `gpg` and process with `byteme`
```bash
#Interactive mode
❯ gpg -c --no-symkey-cache raw.txt
#No interactive mode
❯ gpg --batch --passphrase 'somepass' -c raw.txt
```Now run the steps above but using `.gpg` instead.
## Decryption
```bash
❯ gpg -d raw.txt.gpg
```