Commit Graph

14 Commits (f79e838095ea78f13561ec474575f4a422f938dc)

Author SHA1 Message Date
Benjamin Tan bc9b1fde19 Add newline after shebang if necessary. (#215) 2017-01-17 17:16:40 -05:00
James Long 3af7da5748 Reprint all the files! 2017-01-13 15:03:53 -05:00
Christopher Chedeau df99ae56b0 Add test for shebang and move to index.js (#170)
When looking into adding a test, I realized that the logic was inside of bin/prettier.js and therefore only applying to the cli. Moving it to index.js and adding a test so that it's more robust :)
2017-01-13 13:39:07 -05:00
Jamie Webb ecb26b3432 treat shebang outside of parsing (#137)
* treat shebang outside of parsing

* use less costly indexOf and reuse format function

* avoid reprinting new line and potential double space at start

* move options back to format function
2017-01-13 12:57:27 -05:00
James Long ac6cb883c8 Merge pull request #113 from fortes/master
Enable reading from stdin
2017-01-11 11:29:50 -05:00
James Long 722e5b4477 Merge pull request #114 from dinoboff/docs-update-usage
docs: add globbing example
2017-01-11 11:28:06 -05:00
Damien Lebrun f1db144341 docs: add globbing example
Although prettier lacks options to filter project files to format by itself, most shells allow to submit multiple files with a filename expansion. Add an example using bash.
2017-01-11 16:05:31 +00:00
Filipe Fortes 9ffbd32723 Enable reading from stdin 2017-01-11 07:57:16 -08:00
James Long 83c378e8e8 Merge pull request #84 from vjeux/print_filename
Log the filename when --write is being used
2017-01-11 10:49:47 -05:00
Christopher Chedeau b8e6fc5cb0 Do not fatal when formatting throws
When you are formatting an entire codebase and a single file throw, it shouldn't stop the entire process.
2017-01-10 22:10:00 -08:00
Christopher Chedeau 0fdf14dbe6 Log the filename when --write is being used
This helps giving a sense of progress when printing a lot of files
2017-01-10 22:09:18 -08:00
Andrey Okonetchnikov 85dc8eb118 style: Run prettier on the source code 2017-01-10 21:47:52 +01:00
Andrey Okonetchnikov 1a77d072cc feature: Add support for passing multiple files
Fixes #58
2017-01-10 21:47:24 +01:00
Andrey Okonetchnikov 3b1762b3a9 chore: Added .js extension to ./bin/prettier 2017-01-10 21:45:51 +01:00