Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pbzweihander/howto
instant coding answers via the command line, inspired by gleitz/howdoi
https://github.com/pbzweihander/howto
cli rust search stackoverflow
Last synced: 3 days ago
JSON representation
instant coding answers via the command line, inspired by gleitz/howdoi
- Host: GitHub
- URL: https://github.com/pbzweihander/howto
- Owner: pbzweihander
- License: mit
- Created: 2018-08-21T05:20:21.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2020-01-04T07:16:36.000Z (almost 5 years ago)
- Last Synced: 2024-06-26T09:29:06.355Z (5 months ago)
- Topics: cli, rust, search, stackoverflow
- Language: Rust
- Size: 71.3 KB
- Stars: 6
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# howto
[![circleci](https://circleci.com/gh/pbzweihander/howto.svg?style=shield)](https://circleci.com/gh/pbzweihander/howto)
[![lib crate.io](https://img.shields.io/crates/v/howto.svg)](https://crates.io/crates/howto)
[![lib docs.rs](https://docs.rs/howto/badge.svg)](https://docs.rs/howto)
[![bin crate.io](https://img.shields.io/crates/v/howto-cli.svg)](https://crates.io/crates/howto-cli)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)Get instant coding answers via the command line. Inspired by [gleitz/howdoi](https://github.com/gleitz/howdoi)
## The Library
### Usage
```rust
let answers = howto(&query).await;
let answer = answers.next().await.unwrap();println("{}", answer.instruction);
```## The CLI
### Installation
#### Run with Docker
```bash
docker run --rm -it pbzweihander/howto QUERY
```#### Install with Cargo
```bash
cargo install howto-cli
howto QUERY
```#### Build yourself
```bash
git clone https://github.com/pbzwehiander/howto.git
cd howto/howto-cli
cargo build --release
cargo install --path .
howto QUERY
```### Usage
```
howto-cli 0.3.0USAGE:
howto-cli [FLAGS] [OPTIONS] [query]...FLAGS:
-h, --help Prints help information
-f, --full Whether display the full text of the answer
-l, --link Whether display only the answer link
-V, --version Prints version informationOPTIONS:
-n, --num-answers Number of answers to return [default: 1]
-p, --position Select answer in specified position [default: 0]ARGS:
...
```