Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add quicli post #14

Merged
merged 7 commits into from
Jan 30, 2018
Merged

Add quicli post #14

merged 7 commits into from
Jan 30, 2018

Conversation

killercup
Copy link
Owner

No description provided.

@killercup
Copy link
Owner Author

Thanks so much for offering to review this, @jamesmunns! :)

@killercup
Copy link
Owner Author

@mgattozzi pong! :)

Copy link

@jamesmunns jamesmunns left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

A few grammar/spelling comments, but other than that thanks for sharing!

[#19]: https://github.com/killercup/quicli/issues/19

That sounded pretty awesome and made me really proud:
Did me library

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

s/Did me/Did my


But, before blindly agreeing to this,
I needed to take a step back
and evaluate what I want quicli to be.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

want => wanted (consistent past tense)

I just wanted a small framework-like thing
that made writing CLI apps less of a pain.
But how exactly do I want to to this?
Thanks to Garretts' questions and comments

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Garrett's


In its implementation,
you get what I'd call
"a small framework around you main function":

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

your main

In its implementation,
you get what I'd call
"a small framework around you main function":
quicly's `main!` macro set up some basic things,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

quicli

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is embarrassing

Sadly, for newcomers/forgetful people/drunk programmers/etc.
they are also _wonderfully complex._

So, instead of offering the user "everything,"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"everything",

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, I went with the American style here, as I'm also using American spelling everywhere (I think)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are. What @jamesmunns put is how I always spell everything. I really don't see it split up often but both are valid!

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You know what: You're both right and I actually like the ", version more because it makes way more sense when parsing a sentence. It's just that I really like typography and the hanging quotes look so pretty. Oh well, I'm rendering everything in shitty monospace markdown style anyway :)

So, instead of offering the user "everything,"
I want to introduce some abstractions that are simple to use,
and have simple but useful examples.
Not not get stuck,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"not to get stuck"

Since then, I've written two more guides,
and for both I added features to the framework,
exposed new functionality,
and thought more about how I want quicly-based code to feel.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

quicly => quicli

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is sooo embarrassing

and for both I added features to the framework,
exposed new functionality,
and thought more about how I want quicly-based code to feel.
(More on the aspect of hosting and testing these docs in a future post!)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

post)!

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The whole sentence is in parentheses

It gives you a way of quickly writing CLI programs in Rust.
(Hence the name.)
In this post,
I want to present the ideas and underlaying philosophies of this project.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

underlying

Copy link
Owner Author

@killercup killercup left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks so much! Pushed an update that addressed everything I didn't explicitly comment on :)

In its implementation,
you get what I'd call
"a small framework around you main function":
quicly's `main!` macro set up some basic things,
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is embarrassing

(as well as my ergonomic requirements).

What I want you to end up with is code that is
concise,
Copy link
Owner Author

@killercup killercup Jan 29, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well-structured and boilerplate-free and part of the same point! See below

Sadly, for newcomers/forgetful people/drunk programmers/etc.
they are also _wonderfully complex._

So, instead of offering the user "everything,"
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, I went with the American style here, as I'm also using American spelling everywhere (I think)

Since then, I've written two more guides,
and for both I added features to the framework,
exposed new functionality,
and thought more about how I want quicly-based code to feel.
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is sooo embarrassing

and for both I added features to the framework,
exposed new functionality,
and thought more about how I want quicly-based code to feel.
(More on the aspect of hosting and testing these docs in a future post!)
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The whole sentence is in parentheses

@killercup
Copy link
Owner Author

@skade pong! :)

@mgattozzi
Copy link
Contributor

@killercup ping! :D

Copy link
Contributor

@mgattozzi mgattozzi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not bad! Mostly some grammatical, formatting, and spelling nit picks :D


I've been writing CLI tools in Rust for a while now.
It really surprised me how this language
that works really well for system programming
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

system -> systems

["5 Tips for Writing Small CLI Tools in Rust"][cli-tips]
at the end of August 2017
that you may have read,
where I describes some of my take-aways from that
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

describes -> describe

that you may have read,
where I describes some of my take-aways from that
in the form of short tips.
I've got some great feedback to that post,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've got -> I've gotten
to -> from

I didn't have the time or concentration
to sit down and really do this.
And here's the good news:
For some reason[^9e-talk],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this link render funny?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes: It renders a footnote :)


[cli-tips]: {% post_url 2017-08-31-rust-cli-tips %}

[^9e-talk]: Okay, I admit, I promised to give a talk about Rust, and I wanted to present some nice, clean example code. (Of course, in the end I didn't show quicli in the talk.)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since you've made these two separate sentences rather than an aside you can remove the ( and )

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, the create-react-app setup tools famously has this feature

So, instead of offering the user "everything,"
I want to introduce some abstractions that are simple to use,
and have simple but useful examples.
Not to get stuck,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Were you intending this to be part of the previous sentence? Otherwise I have no idea what you were trying to convey here with this sentence or what you mean by Not to get stuck

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Messed up the fix, should've been "To not get stuck"

Indeed, instead of adding any feature flags to this crate
(that enable additional components to be loaded/exposed),
I want to have a clear line
where a user is supposed to stop relying on quicli.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeeeeah

(that enable additional components to be loaded/exposed),
I want to have a clear line
where a user is supposed to stop relying on quicli.
I'd rather have an "eject" option
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

react-cli (I think) does this and it's nice.

but another important aspect to me is to prove that it is useful
for writing small tools
-- even if you've only just started with Rust.
This is why I initially wrote the Readme file
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Readme -> README

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

but but… my file is Readme.md :O

for writing small tools
-- even if you've only just started with Rust.
This is why I initially wrote the Readme file
in form of a How To:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in -> in the

@mgattozzi
Copy link
Contributor

I say a few but there were like 34 there lol woops

@killercup
Copy link
Owner Author

killercup commented Jan 30, 2018 via email

@skade
Copy link

skade commented Jan 30, 2018

I like it. I'd reread the introduction and see if you could make it a little shorter.

I haven't quite gotten out of it if you will merge stdcli and quicli now?

Copy link
Owner Author

@killercup killercup left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed a bunch of comments :)

Sadly, for newcomers/forgetful people/drunk programmers/etc.
they are also _wonderfully complex._

So, instead of offering the user "everything,"
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You know what: You're both right and I actually like the ", version more because it makes way more sense when parsing a sentence. It's just that I really like typography and the hanging quotes look so pretty. Oh well, I'm rendering everything in shitty monospace markdown style anyway :)

I didn't have the time or concentration
to sit down and really do this.
And here's the good news:
For some reason[^9e-talk],
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes: It renders a footnote :)

it is very concise.

Another aspect of conciseness:
Instead of using `.unwrap` to deal with errors,
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, I actually added the dot to note that it is a method and not a free function. But you're right, they're all the same :)

and good error messages.
Similarly, you get logging for free,
and if you add two more lines,
you also get a `--verbose`/`-v` CLI argument to control the log level
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I <3 consistency and will go with 'flag'

So, instead of offering the user "everything,"
I want to introduce some abstractions that are simple to use,
and have simple but useful examples.
Not to get stuck,
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Messed up the fix, should've been "To not get stuck"


[cli-tips]: {% post_url 2017-08-31-rust-cli-tips %}

[^9e-talk]: Okay, I admit, I promised to give a talk about Rust, and I wanted to present some nice, clean example code. (Of course, in the end I didn't show quicli in the talk.)
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, the create-react-app setup tools famously has this feature

but another important aspect to me is to prove that it is useful
for writing small tools
-- even if you've only just started with Rust.
This is why I initially wrote the Readme file
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

but but… my file is Readme.md :O

@killercup killercup merged commit 7391dde into gh-pages Jan 30, 2018
@killercup
Copy link
Owner Author

Thank you three! The post is now live at https://deterministic.space/quicli.html :)

@killercup killercup deleted the post/quicli branch May 31, 2018 19:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants