Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tubone24/ebook-homebrew-rust-client
CLI created by Rust which use ebook-homebrew Rest API
https://github.com/tubone24/ebook-homebrew-rust-client
rust
Last synced: 1 day ago
JSON representation
CLI created by Rust which use ebook-homebrew Rest API
- Host: GitHub
- URL: https://github.com/tubone24/ebook-homebrew-rust-client
- Owner: tubone24
- License: mit
- Created: 2019-07-30T14:56:21.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-12-15T05:30:37.000Z (about 1 year ago)
- Last Synced: 2024-04-13T04:55:37.157Z (9 months ago)
- Topics: rust
- Language: Rust
- Homepage:
- Size: 1.51 MB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ebook-homebrew-rust-client
> Make pdf file which you use e-books by take in some image files such as jpeg, png and gif.
[![CircleCI](https://circleci.com/gh/tubone24/ebook-homebrew-rust-client.svg?style=svg)](https://circleci.com/gh/tubone24/ebook-homebrew-rust-client)
## What is this app?
This app is a Demo client CLI Client for using [ebook-homebrew](https://github.com/tubone24/ebook_homebrew).
This app is created `Rust`, so you have to build app for `cargo`.
## Project build
```
cargo run
```Build success, create execute file on `target/debug/ebook-homebrew-rust-client`
## Usage
Show help, set opt `-h`
```
$ cd target/debug
$ ./ebook-homebrew-rust-client -hebook_homebrew_rust_client 0.1.0
tubone24
Ebook-homebrew Command Line ToolsUSAGE:
ebook-homebrew-rust-client.exe [SUBCOMMAND]FLAGS:
-v, --version CLI version
-h, --help Prints help informationSUBCOMMANDS:
status check server status
upload upload image files
convert convert image files to PDF
download download converted PDF file
help Prints this message or the help of the given subcommand(s)
```### Example
```
$ cd target/debug
$ ./ebook-homebrew-rust-client -h
$ ebook-homebrew-rust-client upload image_directory png============================
Upload image file
============================
SKIP: aaaa\66623244_2156448614404555_1652487473135091712_n.jpg
ADD: aaaa\standalone-choose-img.png
ADD: aaaa\standalone-top.png
ADD: aaaa\test_001.png
{"release_date": "2019-08-02T14:39:56.001293", "upload_id": "/tmp/tmpz79kzx2l"}$ ebook-homebrew-rust-client convert "/tmp/tmpz79kzx2l" png
============================
Convert PDF
============================
{"release_date": "2019-08-02T14:40:51.017644", "upload_id": "/tmp/tmpz79kzx2l"}$ ebook-homebrew-rust-client download "/tmp/tmpz79kzx2l" test.pdf
============================
Download PDF
============================
Response { url: "https://ebook-homebrew.herokuapp.com/convert/pdf/download", status: 200, headers: {"connection": "keep-alive", "date": "Fri, 02 Aug 2019 14:42:03 GMT", "server": "uvicorn", "content-type": "application/pdf", "vary": "Accept-Encoding", "via": "1.1 vegur"} }
```## Completions
This CLI has prepared shell completions include shell type below.
* Bash
* Zsh
* Fish
* PowerShellUse Those!
## Test
Use cargo test.
```
cargo test
```