https://github.com/nottezz/format-fusion-cli
CLI conversion tool
https://github.com/nottezz/format-fusion-cli
cli-app image-to-base64 json-to-yaml-convertor
Last synced: 4 months ago
JSON representation
CLI conversion tool
- Host: GitHub
- URL: https://github.com/nottezz/format-fusion-cli
- Owner: Nottezz
- License: apache-2.0
- Created: 2024-11-12T20:30:28.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-01-06T15:39:58.000Z (over 1 year ago)
- Last Synced: 2025-03-26T21:35:13.018Z (over 1 year ago)
- Topics: cli-app, image-to-base64, json-to-yaml-convertor
- Language: Python
- Homepage: https://pypi.org/project/cli-format-fusion/
- Size: 77.1 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Format Fusion
**Format Fusion** is a CLI tool for converting various data formats: JSON, YAML, and images to Base64.
[](https://github.com/Nottezz/format-fusion-cli/actions/workflows/python-check.yaml)
[](https://pypi.org/project/cli-format-fusion/)
---
## Installation
```bash
pip install cli-format-fusion
```
---
## Available Commands
Format Fusion supports the following conversions:
| Conversion | Command | Options |
| -------------- | ------------------------------ | ----------------------- |
| JSON → YAML | `format-fusion yaml` | `--reverse`, `--output` |
| YAML → JSON | `format-fusion yaml --reverse` | `--output` |
| Image → Base64 | `format-fusion image` | `--output` |
> All commands support the --output option to specify the output file path.
---
### Usage Examples
#### JSON → YAML
```bash
# Convert JSON to YAML
format-fusion yaml D:\response_api.json
```
Result: an `output.yaml` file will be created in the current directory.
---
#### YAML → JSON
```bash
# Convert YAML back to JSON
format-fusion yaml D:\response_api.yaml --reverse
```
Result: an `output.json` file will be created.
---
#### Specify Output Path
```
# Save the converted file to a specific location
format-fusion yaml D:\response_api.json --output D:\data.yaml
```
Result: the file will be saved to the specified path `D:\data.yaml`.
---
#### Image → Base64
```
# Convert an image to Base64 and save to a file
format-fusion image D:\screenshot.png --output D:\screenshot.txt
```
Result: a file `screenshot.txt` will be created containing the Base64-encoded content.
---
## Useful Resources
[Issue Tracker](https://github.com/Nottezz/format-fusion-cli/issues)