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

doc: add detail on how api docs are published #45626

Closed
wants to merge 7 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
12 changes: 10 additions & 2 deletions doc/contributing/api-documentation.md
Expand Up @@ -11,13 +11,21 @@ generate the following:
1. Human-readable HTML in `out/doc/api/*.html`
2. A JSON representation in `out/doc/api/*.json`

These are published to nodejs.org for multiple versions of Node.js. As an
These artifacts published to nodejs.org for multiple versions of Node.js. As an
mhdawson marked this conversation as resolved.
Show resolved Hide resolved
example the latest version of the human-readable HTML is published to
[nodejs.org/en/doc](https://nodejs.org/en/docs/), and the latest version
of the json documentation is published to
[nodejs.org/api/all.json](https://nodejs.org/api/all.json)

<!-- TODO: Add docs about how the publishing process happens -->
The artifacts are built as part of release builds by running the doc-upload
Makefile target as part of the release-sources part of the
[iojs+release job](https://github.com/nodejs/node/blob/1a83ad6a693f851199608ae957ac5d4f76871485/Makefile#L1218-L1224).
Copy link
Member

Choose a reason for hiding this comment

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

Can we reference HEAD here?

Copy link
Member

Choose a reason for hiding this comment

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

Not without losing the highlighting (the line numbers are specific to that revision of the makefile).

mhdawson marked this conversation as resolved.
Show resolved Hide resolved
This target runs the doc target to build the docs and then uses
mhdawson marked this conversation as resolved.
Show resolved Hide resolved
scp to copy them onto the staging/www server into a directory of the form
mhdawson marked this conversation as resolved.
Show resolved Hide resolved
Copy link
Member

Choose a reason for hiding this comment

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

Do we need to go that deep into the specifics here? Isn't that visible by reading the Makefile?

Copy link
Member Author

Choose a reason for hiding this comment

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

I think the few lines are worth avoiding people having to click into the link.

`/home/staging/nodejs/<type>/<full_version>/docs` where <type> is e.g.
Copy link
Member

Choose a reason for hiding this comment

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

I'm undecided whether the details of where the files are on the server are useful here or not as it's only useful to people with root access to the server (e.g. the build-infra team).

Copy link
Member

Choose a reason for hiding this comment

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

That's kinda what I meant, this kind of text feels like it should belong on nodejs/build?

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't think we have this documented anywhere else and I don't think it's too much of a distraction so the value of having it documented somewhere easy to find is worth it.

release, nightly, etc. The promotion step (either automatic for
nightlies or manual for releases) then moves the docs to
/home/dist/nodejs/docs/\<full\_version> where they are served by node.org.
mhdawson marked this conversation as resolved.
Show resolved Hide resolved

**The key things to know about the tooling include:**

Expand Down