Ex_doc: Watch CLI option to make development easier

Created on 17 Jan 2018  路  2Comments  路  Source: elixir-lang/ex_doc

When writing docs, I frequently want to check the output in the browser to ensure things are formatted like I鈥檓 intending. During development, this creates a bit of an awkward workflow. I write, save in the editor, run the mix docs command, then refresh the browser. It鈥檇 be great if there was a watch option on the CLI or some sort of live reload-type system so changes are reflected a bit more immediately. It would make the writing workflow a bit more productive.

Is this possible to add, perhaps with a file system watcher? If so, and if desired, I鈥檇 be happy to attempt a PR. Any tips on the implementation would be appreciated!

Most helpful comment

With fswatch, this seems like the syntax:

fswatch -o lib | xargs -n1 -I {} mix docs

All 2 comments

I would say the file system watcher should be set externally, something like fswatch:

fswatch . | mix docs

With fswatch, this seems like the syntax:

fswatch -o lib | xargs -n1 -I {} mix docs
Was this page helpful?
0 / 5 - 0 ratings

Related issues

eksperimental picture eksperimental  路  11Comments

eksperimental picture eksperimental  路  5Comments

zacky1972 picture zacky1972  路  4Comments

jcelliott picture jcelliott  路  6Comments

josevalim picture josevalim  路  3Comments