docs: Clean a few files of too-long lines.

We also document why the rest of them are still on the list.
This commit is contained in:
Tim Abbott 2017-11-16 11:44:00 -08:00
parent 011114397b
commit bf77ad3a6e
3 changed files with 21 additions and 13 deletions

View File

@ -62,8 +62,11 @@ application.
## Django routes the request to a view in urls.py files
There are various [urls.py](https://docs.djangoproject.com/en/1.8/topics/http/urls/) files throughout the server codebase, which are
covered in more detail in [the directory structure doc](../overview/directory-structure.html).
There are various
[urls.py](https://docs.djangoproject.com/en/1.8/topics/http/urls/)
files throughout the server codebase, which are covered in more detail
in
[the directory structure doc](../overview/directory-structure.html).
The main Zulip Django app is `zerver`. The routes are found in
```
@ -77,9 +80,10 @@ on how the REST API handles our user creation example.
## Views serving HTML are internationalized by server path
If we look in [zproject/urls.py](https://github.com/zulip/zulip/blob/master/zproject/urls.py), we can see something called
`i18n_urls`. These urls show up in the address bar of the browser, and
serve HTML.
If we look in
[zproject/urls.py](https://github.com/zulip/zulip/blob/master/zproject/urls.py),
we can see something called `i18n_urls`. These urls show up in the
address bar of the browser, and serve HTML.
For example, the `/features` page (preview
[here](https://zulipchat.com/features/)) gets translated in Chinese at
@ -96,7 +100,8 @@ With the exception of Webhooks (which we do not usually control the
format of), legacy endpoints, and logged-out endpoints, Zulip uses REST
for its API. This means that we use:
* POST for creating something new where we don't have a unique ID. Also used as a catch-all if no other verb is appropriate.
* POST for creating something new where we don't have a unique
ID. Also used as a catch-all if no other verb is appropriate.
* PUT for creating something for which we have a unique ID.
* DELETE for deleting something
* PATCH for updating or editing attributes of something.
@ -205,7 +210,8 @@ in a
with a content type of 'application/json'.
To pass back data from the server to the calling client, in the event of
a successfully handled request, we use `json_success(data=<some python object which can be converted to a JSON string>`.
a successfully handled request, we use
`json_success(data=<some python object which can be converted to a JSON string>`.
This will result in a JSON string:

View File

@ -161,8 +161,7 @@ running it manually.
1. Configure *supervisord*. *supervisord* stores its configuration in
`/etc/supervisor/conf.d`.
* Do **one** of the following:
* Download the [sample config file](
https://raw.githubusercontent.com/zulip/python-zulip-api/master/zulip_botserver/zulip-botserver-supervisord.conf)
* Download the [sample config file][supervisord-config-file]
and store it in `/etc/supervisor/conf.d/zulip-botserver.conf`.
* Copy the following section into your existing supervisord config file.
```
@ -174,6 +173,8 @@ running it manually.
```
* Edit the `<>` sections according to your preferences.
[supervisord-config-file]: https://raw.githubusercontent.com/zulip/python-zulip-api/master/zulip_botserver/zulip-botserver-supervisord.conf
2. Update *supervisord* to read the configuration file:
```
supervisorctl reread

View File

@ -653,16 +653,17 @@ def build_custom_checkers(by_lang):
color = next(colors)
markdown_docs_length_exclude = {
"api/bots/converter/readme.md",
"templates/zerver/api/running-bots.md",
# Has some example Vagrant output that's very long
"docs/development/setup-vagrant.md",
# Has some example code that could perhaps be wrapped
"docs/tutorials/webhook-walkthrough.md",
"docs/tutorials/life-of-a-request.md",
# Have wide output in code blocks
"docs/subsystems/logging.md",
"docs/migration-renumbering.md",
"docs/overview/readme-symlink.md",
# Have curl commands with JSON that would be messy to wrap
"zerver/webhooks/helloworld/doc.md",
"zerver/webhooks/trello/doc.md",
# Has a very long configuration line
"templates/zerver/integrations/perforce.md",
}
for fn in by_lang['md']: