-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
doc: add user guide #1246
doc: add user guide #1246
Conversation
Thanks for this! I will take a look by Wednesday.
…On Sun, Mar 12, 2017 at 3:06 PM, Saúl Ibarra Corretgé < ***@***.***> wrote:
As discussed in #1027 <#1027>, this
incorporates the uvbook into our documentation.
Consider this a WIP, but I wanted to get some eyes on it early, specially
I want to make sure @nikhilm <https://github.com/nikhilm> is OK with the
approach taken here.
@nikhilm <https://github.com/nikhilm> please take a look at the commits
following "doc: add initial version of the User Guide", specially the one
regarding the licensing. I'm happy to make adjustments!
My plan is to do a quick pass replacing "book" with "guide", and
incorporate the code examples. I won't review the entire thing in a single
go. I added a warning note so the idea is to gradually improve the guide
and bring it on par with latest libuv, just like we did with the API
documentation.
Doc on!
PS: Sorry for being AWOL for some time, I needed some time off.
------------------------------
You can view, comment on, or merge this pull request online at:
#1246
Commit Summary
- doc: rename docs to "libuv documentation"
- doc: update copyright years
- doc: move TOC to a dedicated document
- doc: move documentation section up
- doc: move "upgrading" to a standalone document
- doc: add initial version of the User Guide
- doc: removed unused file
- doc: update guide/about and mention new maintainership
- doc: remove licensing note from guide/about
- doc: add warning note to user guide
File Changes
- *A* docs/src/api.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-0> (35)
- *M* docs/src/conf.py
<https://github.com/libuv/libuv/pull/1246/files#diff-1> (18)
- *A* docs/src/guide.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-2> (22)
- *A* docs/src/guide/about.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-3> (22)
- *A* docs/src/guide/basics.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-4> (188)
- *A* docs/src/guide/eventloops.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-5> (48)
- *A* docs/src/guide/filesystem.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-6> (287)
- *A* docs/src/guide/introduction.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-7> (75)
- *A* docs/src/guide/networking.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-8> (249)
- *A* docs/src/guide/processes.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-9> (389)
- *A* docs/src/guide/threads.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-10> (379)
- *A* docs/src/guide/utilities.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-11> (433)
- *M* docs/src/index.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-12> (61)
- *A* docs/src/upgrading.rst
<https://github.com/libuv/libuv/pull/1246/files#diff-13> (11)
Patch Links:
- https://github.com/libuv/libuv/pull/1246.patch
- https://github.com/libuv/libuv/pull/1246.diff
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1246>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAEzWshhzT_mjg7Oya1lV3mMf2BpBDJ4ks5rlGxmgaJpZM4Masag>
.
|
docs/src/guide/index.rst
Outdated
|
||
<ul> | ||
<li> | ||
<a href="http://nikhilm.github.com/uvbook/An%20Introduction%20to%20libuv.pdf" onClick="_gaq.push(['_trackEvent', 'Downloads', 'Download', 'PDF']);">PDF</a> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know how useful the pdf/epub has been but it would be cool to continue serving these. Not a high priority of course, but sphinx does generate them for free as long as the build host has latex setup.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We server the docs with ReadTheDocs, and they already do this with an on-screen menu, see here: http://docs.libuv.org/en/v1.x/
docs/src/guide/about.rst
Outdated
@@ -17,6 +16,10 @@ describes much of the semantics of the two libraries. | |||
This book was made using `Sphinx <http://sphinx.pocoo.org/>`_ and `vim | |||
<http://www.vim.org>`_. | |||
|
|||
.. note:: | |||
In 2017 the libuv project incorporated the Nikhil's work into the official |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: the Nikhil's -> Nikhil's
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, my bad, will fix!
docs/src/guide/about.rst
Outdated
@@ -20,9 +20,3 @@ This book was made using `Sphinx <http://sphinx.pocoo.org/>`_ and `vim | |||
In 2017 the libuv project incorporated the Nikhil's work into the official | |||
documentation and it's maintained there henceforth. | |||
|
|||
Licensing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you clarify what the new licensing is going to be?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interesting, we don't seem to have any license stated, so I guess it's MIT at the moment, like the whole project. I think a CC license makes more sense, so I'll have a look at who contributed to docs/ and ask everyone if they are ok changing it.
Thanks! Everything else looks great.
Best,
Nikhil
…On Thu, Mar 16, 2017 at 3:44 AM, Saúl Ibarra Corretgé < ***@***.***> wrote:
@nikhilm <https://github.com/nikhilm> I proposed we change the license
here: #1254 <#1254>
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1246 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAEzWvsMUGs677hq5AyAozj7T7VMlhZ9ks5rmRKhgaJpZM4Masag>
.
|
I think this is ready for review / landing. The guide / examples have not been adapted yet, but once we get it in it's easier to iterate quickly, and our current API documentation is a proof of that. @libuv/collaborators PTAL. |
#include <string.h> | ||
#include <uv.h> | ||
|
||
uv_loop_t *loop; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So, I assume this is taken directly from the book right? It should be uv_loop_t* loop
, but are we going to go through and lint the whole thing by hand?
Is rubber stamping the book an option? Cleaning up the documentation always makes for good first contributions, which are kind of hard to come by in libuv IMO. |
void alloc_buffer(uv_handle_t *handle, size_t suggested_size, uv_buf_t *buf) { | ||
buf->base = malloc(suggested_size); | ||
buf->len = suggested_size; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The indentation is not consistent in this file
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just that the uvbook is already out there. Instead of reviewing the entire book, we could take it as a known good commodity, and any necessary fixes could be made as they are discovered. That's the kind of thing that is friendly to first time contributors too.
Sure, that's what this PR is about! :-)
|
||
Since then libuv has continued to mature and become a high quality standalone | ||
library for system programming. Users outside of node.js include Mozilla's | ||
Rust_ programming language, and a variety_ of language bindings. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the Rust
reference isn't valid anymore?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note that this PR incorporates the book pretty much as is, those kind of fixes will follow. Same goes for the sample code.
I'd support this |
What do you mean by this? |
Just that the uvbook is already out there. Instead of reviewing the entire book, we could take it as a known good commodity, and any necessary fixes could be made as they are discovered. That's the kind of thing that is friendly to first time contributors too. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM then
Thanks! Once this is up, I'll update my version of the book to link to this as the canonical source. |
PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
This is a fresh import of uvbook [0], as is. It is to be considered "beta", as the entire content hasn't been revised / adapted yet. PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
We use guide.rst as our index, so there is no need for a secondary one. PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Text taken from: https://creativecommons.org/licenses/by/4.0/legalcode.txt Fixes: libuv#1254 PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
PR-URL: libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
PR-URL: libuv/libuv#1246 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
As discussed in #1027, this incorporates the uvbook into our documentation.
Consider this a WIP, but I wanted to get some eyes on it early, specially I want to make sure @nikhilm is OK with the approach taken here.
@nikhilm please take a look at the commits following "doc: add initial version of the User Guide", specially the one regarding the licensing. I'm happy to make adjustments!
My plan is to do a quick pass replacing "book" with "guide", and incorporate the code examples. I won't review the entire thing in a single go. I added a warning note so the idea is to gradually improve the guide and bring it on par with latest libuv, just like we did with the API documentation.
Doc on!
PS: Sorry for being AWOL for some time, I needed some time off.