Comments (3)
I think this kind of "story" can also help with #19 to tell the purpose of quicli
. It is an entry point for beginners and a helper when your knowledge expands.
This will help reduce the amount of "should this crate be part of quicli" discussions -- most of those could be redirected to the relevant ergo
subcrate.
from quicli.
from quicli.
Awesome! 🎉
How about just a full-throttle
feature as the only default feature (for now), and ergo will work with just no-default-features
.
I would like to unify the docs as well, to tell the full story. Basically the story is this:
Getting Started Guide
This is the kind of person who is not familiar with rust, or at least not familiar with the full ecosystem and how to build an application.
They are directed to use a cargo like this:
[dependencies]
quicli = "0.X.X"
serde = "0.X.X"
# ... other `derive` dependencies
The "cookbook" guide then looks very similar to what it does today (but we will keep improving them 😄)
Next Level: full ecosystem
At the next level, they are instructed to use a Cargo.toml
like this:
[dependencies]
ergo = "0.X.X"
serde = "0.X.X"
# ... other `derive` dependencies
[dependencies.quicli]
default-features = false
version = "0.X.X"
We then basically replicate the rust cookbook, as well as additional examples, using this as the ecosystem. I would like one of the primary goals of ergo
to be that it should be able to do almost anything from within the rust cookbook with zero additional dependencies.
Usecase
I think I see clearly now how these two crates interact:
quicli
is for reducing boilerplate to quickly setup a CLI application. It is intended only for--bin
crates.ergo
is an ecosystem of crates built for high level libraries, including--bin
crates. It is also split into subcrates (i.e.ergo_fs
) for some lower level libraries.
Let me include a use case, which is the CLI application I am rewriting.
artifact
will be (eventually) split into 3 crates. Their dependencies (roughtly) would look like this:
---- artifact-data
/ - ergo
/
artifact-app -------- artifact-web
- quicli - ergo
- ergo - yew
- gotham
As you can see, the two "high level libraries" can feel free to depend on ergo
. In order for this to be ergonomic, ergo
must not include libraries like StructOpt and envlogger
, which should only exist in --bin
crates.
Conclusion / Vision
I think these two libraries can interact very nicely, and I think our first goal can/should be to rewrite the rust Cookbook using these libraries.
I'm currently reviewing the API guidelines and plan on contacting the libz blitz team and see if we can share knoweldge/expertise. The ideal case would be that the cookbook we work on writing will be the rust cookbook once ergo
and quicli
are stabilized. I would like to see if bringing the libz blitz team onboard would allow those goals to align.
Before that though I am going to actually use ergo
and quicli
as they exists today to rewrite artifact
and port some of the cookbook. I will be making frequent changes/PRs for any bugs I find.
Does that all sound like a reasonable strategy?
from quicli.
Related Issues (20)
- issue in 'getting started' HOT 2
- Issue with glob in thumbnail tutorial HOT 2
- Include `read_input`?
- bail!() no longer works with quicli 0.4 HOT 1
- Quicli in the wild HOT 2
- Testing, examples, docs, CI
- Move Result type out of the prelude HOT 2
- Update failure to 1.0.0 on March 15
- docs and crates to support re-parsing the command line (readline style)
- export clap macros HOT 2
- Unix pipes support out of the box HOT 1
- Switch to globwalk
- human-panic
- Readme example doesn't compile HOT 2
- StructOpt not found in scope HOT 3
- "methods are not allowed for flattened entry" HOT 1
- Expose remove_dir_all crate HOT 1
- main! macro emits warning
- Turn on logging in all subcrates? HOT 2
- use of deprecated item 'failure::Error::causes' HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from quicli.