#ergonomics #cli #application

ergo

making rust’s ecosystem more ergonomic, therefore more fun

5 releases

Uses old Rust 2015

0.1.2 Jan 26, 2018
0.1.1 Jan 26, 2018
0.0.5 Jul 13, 2018
0.0.4 Apr 21, 2018
0.0.1 Feb 7, 2018

#4 in #application

Download history 4/week @ 2021-05-25 4/week @ 2021-06-01 15/week @ 2021-06-08 5/week @ 2021-06-15 2/week @ 2021-06-22 5/week @ 2021-06-29 5/week @ 2021-07-06 7/week @ 2021-07-13 13/week @ 2021-07-20 22/week @ 2021-07-27 15/week @ 2021-08-03 26/week @ 2021-08-10 2/week @ 2021-08-17 3/week @ 2021-08-24 1/week @ 2021-08-31 3/week @ 2021-09-07

56 downloads per month
Used in novault

MIT/Apache

11KB
92 lines

Ergo: making rust's ecosystem more ergonomic, therefore more fun.

Build Status Build status Docs

The Ergo Ecosystem is an effort to unify the rust ecosystem at critical sections. It is currently focused on improving Command Line Interface (CLI) ergonomics. To accomplish this it will create multiple targeted conglomeration crates. These crates do much more than simply exporting the API of their sub-crates. They implement wrapper types to unify them, as well as have tested documentation to ensure they interopate together reliably.

@autron said it best in the rust 2018 roadmap

CLI apps

Rust is a fantastic language for writing a Command Line Application (CLI). For the ergonomics of hacking, it has one of the best argument parsers ever, has seriously the best serialization library ever and it compiles to almost any target and goes fast when it runs. (@vitiral)

Rust has also seem some production update in the CLI space, for which it is very well-suited. This is a space where Rust’s portability, reliability, and ability to produce static binaries make it extremely attractive. We also have a number of excellent libraries already. This year, we will improve this ecosystem and pull it together into a polished, coherent package for people checking out Rust. Read @vitiral’s post and @killercup’s crate for some inspiration!

Vision

Ergo's current goal is to be a full featured CLI SDK, built from composable and distinct sub components. You should be able to depend on the ergo library itself or each of its sub components individually.

Ergo aims to provide the following benefits:

  • A standardized API for disparate types/approaches, allowing library authors to develop simple libraries of high quality, which can then be combined into an ecosystem with a unified API and excellent ergonomics.
  • A starting point for CLI and application developers for documentation and How To guides. We hope to release an Ergo Cookbook once the libraries are more stable.
  • Encourage interopability, quality, and ergonomic errors among the major CLI crates in the rust ecosystem and act as a driver towards higher quality and uniformity.

Sub Crates

The ergo ecosystem is split into multiple crates, each with the prefix ergo_

The ergo crate itself is currently in alpha status. The primary author is rewriting his CLI application using it to get the rough edges ironed out and we are looking for feedback, contributors and leaders from the community during this time

For now, consuder using quicli which will integrate cleanly with the ergo ecosystem in the future. If you do use this crate expect frequenty changes that are not semver compliant.

Implemented Sub Crates

  • ergo_fs: ergonomic filesystem operations. (beta status)
  • ergo_sync: provides an ultra-simple API for using Sync types, i.e. running threads and sending messages. (beta status)
  • ergo_std: "generally needed stuff" -- regex, lazy_static, maplit, itertools, ordermap. This will be very few crates. It is mostly composed of things which could practically be in the std library. (beta status)
  • ergo_config: deserialization and config files and ENV variables: ron, toml, serde_json, serde_yaml, configure (alpha status)
  • ergo_sys: deal with interfacing with the OS. Examples currently only include signal handling (ctrlc) and randomness (rand) but we are looking for other important crates. (alpha status)

Future Sub Crates

  • ergo_client: methods/types to be an HTTP client. Sub crates probably include reqwest, h2 and some kinds of json-rpc+soap protocol helpers.
  • ergo_term: simple and ergonomic terminal rendering.
  • ergo_test: one-stop-shop for core testing functionality, mocking, etc.

LICENSE

The source code in this repository is Licensed under either of

at your option.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies

~10MB
~214K SLoC