ray/doc
Alok Singh 42a9233e1d Improve yapf speed and document its usage (#2160)
* Allow yapf to lint individual files

* Add tip for using yapf

* Update doc

* Update script to autoformat changed py files

The new default is for the script to only updated changed files to encourage
using it as a pre-push hook. Travis still checks all since it's not that big an
increase to runtime.

* Exclude formatting thirdparty/autogen py files

* Symlink .travis -> scripts

Hidden directories may get glossed over otherwise.

* .travis -> scripts in docs

They are symlinks to the same thing, but `scripts` is more dev-friendly, while
`.travis` is really only for Travis CI.

* Document different yapf format functions

Most devs will only need `format_changed`, and this is run by default.
`format_changed` should be fast enough in most cases to work as a pre-commit
hook.

* Speed up yapf by only formatting changed files

* Update docs

1. Mention how yapf can be used a pre-commit hook
2. rm `bash`, script is executable

* Update yapf.sh

* Update development.rst

* Update yapf.sh

* Use bash arrays for correct argument splitting

Playing fast and loose with whitespace in bash is a terrible idea.

* Only format non-excluded by default

* Check changes against master

Normally, the remote is called `origin`, but naming it explicit

* Adding missing directory to `format_all`

* Cleanup YAPF code

Remove unused function and move around code to make clearer and adding lines
give cleaner diffs.

* Ensure correct files are autoformatted

* Fix cmd line arg splitting

Each arg has to be in its own set of quotes.

* Diff against mergebase

TIL there's a clean syntax for doing that, but it's too clever to belong in a
shell script.

We use `mapfile -t` to ensure no problems down the line with weird filenames.
2018-06-05 20:22:11 -07:00
..
_build Get Sphinx infrastructure in place 2016-07-01 18:21:02 -07:00
source Improve yapf speed and document its usage (#2160) 2018-06-05 20:22:11 -07:00
make.bat Get Sphinx infrastructure in place 2016-07-01 18:21:02 -07:00
Makefile Move documentation to ReadTheDocs. (#326) 2017-02-27 21:14:31 -08:00
README.md Only install ray python packages. (#330) 2017-03-01 23:34:44 -08:00
requirements-doc.txt Bring cloudpickle inside the repository. (#1445) 2018-01-25 11:36:37 -08:00

Ray Documentation

To compile the documentation, run the following commands from this directory. Note that Ray must be installed first.

pip install -r requirements-doc.txt
make html
open _build/html/index.html

To test if there are any build errors with the documentation, do the following.

sphinx-build -W -b html -d _build/doctrees source _build/html