]>
git.lizzy.rs Git - rust.git/log
Nick Cameron [Sun, 22 Nov 2015 18:23:58 +0000 (07:23 +1300)]
Merge pull request #638 from marcusklaas/visual-struct-last-comment
Fix last comment for visually formatted struct lits
Nick Cameron [Sun, 22 Nov 2015 18:22:26 +0000 (07:22 +1300)]
Merge pull request #637 from marcusklaas/fn-type
Improve function type formatting
Marcus Klaas [Sun, 22 Nov 2015 16:41:54 +0000 (17:41 +0100)]
Fix last comment for visually formatted struct lits
Marcus Klaas [Sun, 22 Nov 2015 15:07:38 +0000 (16:07 +0100)]
Format bare function types
Fix https://github.com/rust-lang-nursery/rustfmt/issues/616.
Fix https://github.com/rust-lang-nursery/rustfmt/issues/276.
Close https://github.com/rust-lang-nursery/rustfmt/issues/350.
Marcus Klaas [Sun, 22 Nov 2015 13:48:30 +0000 (14:48 +0100)]
Fix up indentation of function style paths
Fixes https://github.com/rust-lang-nursery/rustfmt/issues/105.
Marcus Klaas [Sun, 22 Nov 2015 12:45:51 +0000 (13:45 +0100)]
Extract fn rewrite methods from RewriteVisitor
Nick Cameron [Sun, 22 Nov 2015 05:37:51 +0000 (18:37 +1300)]
Merge pull request #636 from KiChjang/spelling
Fix incorrect usage of 'it's'
Keith Yeung [Sat, 21 Nov 2015 23:55:42 +0000 (15:55 -0800)]
Fix incorrect usage of 'it's'
Marcus Klaas de Vries [Sat, 21 Nov 2015 20:24:29 +0000 (21:24 +0100)]
Merge pull request #633 from marcusklaas/mod-comment
Rewrite module declarations
Marcus Klaas [Fri, 20 Nov 2015 21:44:15 +0000 (22:44 +0100)]
Rewrite module declarations
Marcus Klaas de Vries [Sat, 21 Nov 2015 20:04:34 +0000 (21:04 +0100)]
Merge pull request #635 from Marwes/long_field_access
Fix long field accesses not being broken onto separate lines
Markus Westerlind [Sat, 21 Nov 2015 00:04:23 +0000 (01:04 +0100)]
Fix long field accesses not being broken onto separate lines
Fixes #512
Nick Cameron [Fri, 20 Nov 2015 23:47:53 +0000 (12:47 +1300)]
Merge pull request #634 from Marwes/block_comment_crlf
Avoid adding an extra newline after block comments
Markus Westerlind [Fri, 20 Nov 2015 22:31:05 +0000 (23:31 +0100)]
Avoid adding an extra newline after block comments
When block comments were rewritten to line comments they check if a new line needs to be added and adds one if needed. It only checked for '\n' however which would cause a newline to be added even if the comment was ended by "\r\n"
Marcus Klaas de Vries [Fri, 20 Nov 2015 20:58:39 +0000 (21:58 +0100)]
Merge pull request #603 from marcusklaas/multiline-math-armz
Wrap/unwrap match arms
Marcus Klaas [Fri, 20 Nov 2015 20:50:25 +0000 (21:50 +0100)]
Add option to disable (un)wrapping of match arms
Marcus Klaas [Sat, 14 Nov 2015 20:59:04 +0000 (21:59 +0100)]
Force chains to adhere to restrictions
Marcus Klaas [Sat, 14 Nov 2015 20:57:31 +0000 (21:57 +0100)]
Unwrap match arms that are simple blocks
Marcus Klaas [Fri, 20 Nov 2015 20:05:10 +0000 (21:05 +0100)]
Blockify multiline match arms
Nick Cameron [Fri, 20 Nov 2015 20:00:40 +0000 (09:00 +1300)]
Merge pull request #631 from malbarbo/patch-1
Update README.md
Marco A L Barbosa [Fri, 20 Nov 2015 18:58:57 +0000 (16:58 -0200)]
Update README.md
Nick Cameron [Fri, 20 Nov 2015 05:14:26 +0000 (18:14 +1300)]
Merge pull request #618 from zyphrus/master
Comments in structs use appropriate style
Nick Cameron [Fri, 20 Nov 2015 05:13:03 +0000 (18:13 +1300)]
Merge pull request #628 from kyeah/single-line-fn
Single-line Functions
Kevin Yeh [Fri, 20 Nov 2015 02:49:24 +0000 (20:49 -0600)]
Combine rewrite_single_line_fn and rewrite_fn
Kevin Yeh [Fri, 20 Nov 2015 02:11:32 +0000 (20:11 -0600)]
Fix empty body format, add fn_empty_single_line option, refactor block tests
Nick Cameron [Fri, 20 Nov 2015 02:09:42 +0000 (15:09 +1300)]
Merge pull request #629 from sfackler/usage
Use argv[0] for usage output
Steven Fackler [Fri, 20 Nov 2015 01:56:37 +0000 (17:56 -0800)]
Use argv[0] for usage output
Usage messages traditionally use this as it contains the path that the
user provided to run the executable (e.g. `rustfmt` instead of
`/usr/local/bin/rustfmt`).
David Barnett [Thu, 19 Nov 2015 21:37:00 +0000 (10:37 +1300)]
Use tactic instead of config
Add mixed test
Mixed is unreachable as there is no input combination that could get
to this value
Kevin Yeh [Thu, 19 Nov 2015 08:08:17 +0000 (02:08 -0600)]
Implement Rewrite for ast::Stmt
Kevin Yeh [Thu, 19 Nov 2015 07:53:25 +0000 (01:53 -0600)]
Combine block utilities
Kevin Yeh [Wed, 18 Nov 2015 04:53:06 +0000 (22:53 -0600)]
Support single-line functions
By default, places functions with empty bodies on one line.
If the function has only one expression or statement that fits on one line, the 'fn_single_line' option can be used.
Nick Cameron [Thu, 19 Nov 2015 18:41:12 +0000 (07:41 +1300)]
Merge pull request #619 from SiegeLord/item_brace_style_1
Implement initial option for brace style for non-fn items.
Pavel Sountsov [Thu, 19 Nov 2015 06:34:14 +0000 (22:34 -0800)]
Properly follow the brace styles.
David Barnett [Wed, 18 Nov 2015 10:30:23 +0000 (23:30 +1300)]
Test for single arm in struct
Pavel Sountsov [Tue, 17 Nov 2015 07:18:07 +0000 (23:18 -0800)]
Comments.
- Move the option
- Add some more tests (don't pass yet)
Nick Cameron [Tue, 17 Nov 2015 05:28:57 +0000 (18:28 +1300)]
Merge pull request #620 from sidred10/atom-instructions
Atom instructions
sid [Tue, 17 Nov 2015 05:24:42 +0000 (10:54 +0530)]
remove unnecessary full stop
sid [Tue, 17 Nov 2015 05:22:05 +0000 (10:52 +0530)]
update atom instructions
Nick Cameron [Tue, 17 Nov 2015 03:14:06 +0000 (16:14 +1300)]
Merge pull request #591 from rust-lang-nursery/atom
Instructions for using Rustfmt from Atom.
Nick Cameron [Thu, 12 Nov 2015 21:49:06 +0000 (10:49 +1300)]
Instructions for using Rustfmt from Atom.
Closes #581
David Barnett [Mon, 16 Nov 2015 22:57:49 +0000 (11:57 +1300)]
Comments in structs use appropriate style
Fixes #491
Nick Cameron [Mon, 16 Nov 2015 18:53:09 +0000 (07:53 +1300)]
Merge pull request #589 from rust-lang-nursery/rustup
Slightly awkward rustup
Nick Cameron [Thu, 12 Nov 2015 20:38:41 +0000 (09:38 +1300)]
Rustup
Pavel Sountsov [Sun, 15 Nov 2015 19:55:18 +0000 (11:55 -0800)]
Implement initial option for brace style for non-fn items.
Nick Cameron [Sun, 15 Nov 2015 19:25:22 +0000 (08:25 +1300)]
Merge pull request #607 from rhoot/native-newline
Adding a "Native" option to newline_style.
Nick Cameron [Sun, 15 Nov 2015 18:33:39 +0000 (07:33 +1300)]
Merge pull request #605 from sanxiyn/verbose
Add verbose mode
Johan Sköld [Sun, 15 Nov 2015 11:34:04 +0000 (03:34 -0800)]
Adds a "Native" option to newline_style.
By using it one will get \r\n line endings on Windows, and \n line endings
on other platforms.
Seo Sanghyeon [Sun, 15 Nov 2015 06:41:41 +0000 (15:41 +0900)]
Add verbose mode
Marcus Klaas de Vries [Sat, 14 Nov 2015 23:02:12 +0000 (00:02 +0100)]
Merge pull request #604 from eefriedman/path-cleanup
Pass in whether an ast::Path is in an expression context.
Eli Friedman [Sat, 14 Nov 2015 21:52:43 +0000 (13:52 -0800)]
Pass in whether an ast::Path is in an expression context.
This gets rid of a slightly nasty hack involving scanning the source
expression for a ":".
Marcus Klaas de Vries [Sat, 14 Nov 2015 21:00:11 +0000 (22:00 +0100)]
Merge pull request #601 from thorbenk/chains_tabbed_indent
Chains tabbed indent
Thorben Kroeger [Sat, 14 Nov 2015 16:47:59 +0000 (17:47 +0100)]
new config 'chain_indent'
Marcus Klaas de Vries [Sat, 14 Nov 2015 18:23:00 +0000 (19:23 +0100)]
Merge pull request #602 from crumblingstatue/report_newline
Don't print an unnecessary newline after printing format report
Marcus Klaas de Vries [Sat, 14 Nov 2015 18:22:27 +0000 (19:22 +0100)]
Merge pull request #600 from thorbenk/config_help_cmd
fix documentation of config help
Mika Attila [Sat, 14 Nov 2015 18:01:28 +0000 (19:01 +0100)]
Don't print an unnecessary newline after printing format report
The Display implementation for FormatReport already prints
a newline after every error.
However, if the format report does not contain errors, we
don't want to print an empty newline.
This behavior clutters up the console output with
empty lines when rustfmt is invoked multiple times
(from .e.g a script or cargo-fmt).
So instead of using println! to print the report, we just
use print!.
Thorben Kroeger [Sat, 14 Nov 2015 15:43:18 +0000 (16:43 +0100)]
fix documentation of config help
Nick Cameron [Fri, 13 Nov 2015 21:04:04 +0000 (10:04 +1300)]
Merge pull request #596 from marcusklaas/where-indent
Fix brace indentation after where clause
Nick Cameron [Fri, 13 Nov 2015 21:03:12 +0000 (10:03 +1300)]
Merge pull request #597 from marcusklaas/method-generix
Fix span issue with generic method calls
Nick Cameron [Fri, 13 Nov 2015 21:01:58 +0000 (10:01 +1300)]
Merge pull request #593 from JanLikar/Fix580
Enable rustfmt to format a list of files
Marcus Klaas [Fri, 13 Nov 2015 13:53:34 +0000 (14:53 +0100)]
Fix span issue with generic method calls
Marcus Klaas [Fri, 13 Nov 2015 13:31:20 +0000 (14:31 +0100)]
Fix brace indentation after where clause
Nick Cameron [Fri, 13 Nov 2015 05:56:59 +0000 (18:56 +1300)]
Merge pull request #594 from cskksc/master
Add emacs integration to readme.
cskksc [Fri, 13 Nov 2015 03:25:48 +0000 (08:55 +0530)]
Merge branch 'master' of https://github.com/rust-lang-nursery/rustfmt
cskksc [Thu, 12 Nov 2015 09:44:28 +0000 (15:14 +0530)]
Add emacs integration to readme.
Jan Likar [Fri, 13 Nov 2015 01:08:57 +0000 (02:08 +0100)]
Correct some non-idiomatic code
Nick Cameron [Fri, 13 Nov 2015 00:32:25 +0000 (13:32 +1300)]
Merge pull request #592 from johannhof/coveralls
Try fixing OSX builds
Jan Likar [Fri, 13 Nov 2015 00:13:25 +0000 (01:13 +0100)]
Enable rustfmt to format a list of files
Fix #580 by allowing rustfmt to accept a list of files. This also
enables usage of shell wildcard expansion, although notably this does
not work with cmd.exe on Windows. For example: 'rustfmt *.rs' will
format all rust files in the current working directory.
- Change usage text to show rustfmt will accept a list of files
- Change "Using rustfmt config file: {}" message to
"Using rustfmt config file {} for {}"
- Change Operation::Format(PathBuf, WriteMode) to
Operation::Format(Vec<PathBuf>, WriteMode)
- Loop through Vec<PathBuf>, load config and call 'run' for each path
Johann [Thu, 12 Nov 2015 22:47:24 +0000 (23:47 +0100)]
Try fixing OSX builds
... that I broke by introducing travis-cargo.
Nick Cameron [Thu, 12 Nov 2015 21:58:51 +0000 (10:58 +1300)]
Merge pull request #590 from johannhof/coveralls
Report test coverage with travis-cargo & coveralls
Johann [Thu, 12 Nov 2015 21:38:35 +0000 (22:38 +0100)]
Report test coverage with travis-cargo & coveralls
As this project grows, it might be beneficial to require pull requests
to keep a certain level of test coverage. Plus it's a fun statistic.
Nick Cameron [Wed, 11 Nov 2015 22:51:51 +0000 (11:51 +1300)]
Merge pull request #582 from rust-lang-nursery/links
make links work
Nick Cameron [Wed, 11 Nov 2015 22:46:55 +0000 (11:46 +1300)]
make links work
Nick Cameron [Wed, 11 Nov 2015 20:14:50 +0000 (09:14 +1300)]
Merge pull request #579 from alex/patch-2
Cache downloaded packages on travis
Nick Cameron [Wed, 11 Nov 2015 20:01:38 +0000 (09:01 +1300)]
Update README with new url
Nick Cameron [Wed, 11 Nov 2015 20:00:09 +0000 (09:00 +1300)]
Merge pull request #578 from alex/patch-1
Update README, cargo install is now stable
Alex Gaynor [Wed, 11 Nov 2015 17:41:12 +0000 (12:41 -0500)]
Cache downloaded packages on travis
Alex Gaynor [Wed, 11 Nov 2015 17:34:17 +0000 (12:34 -0500)]
Update README, cargo install is now stable
Nick Cameron [Tue, 10 Nov 2015 22:24:12 +0000 (11:24 +1300)]
Merge pull request #478 from KeenS/travis
Create a binary from travis ci and so on
Nick Cameron [Tue, 10 Nov 2015 22:16:20 +0000 (11:16 +1300)]
Merge pull request #577 from nrc/docs
Information for new contributors
Nick Cameron [Mon, 9 Nov 2015 18:34:44 +0000 (07:34 +1300)]
Information for new contributors
Marcus Klaas de Vries [Tue, 10 Nov 2015 07:43:29 +0000 (08:43 +0100)]
Merge pull request #571 from nrc/semi
Don't strip semi-colons from expressions with non-void type since it …
Nick Cameron [Mon, 9 Nov 2015 22:05:48 +0000 (17:05 -0500)]
Merge pull request #576 from boblehest/check_cwd_for_config
Check if the CWD contains a config (previously it only checked parents)
Jørn Lode [Mon, 9 Nov 2015 20:41:25 +0000 (21:41 +0100)]
Check if the CWD contains a config (previously it only checked parents)
Marcus Klaas de Vries [Mon, 9 Nov 2015 19:17:50 +0000 (20:17 +0100)]
Merge pull request #573 from nrc/doom_panic
Format tuple structs better
Marcus Klaas de Vries [Mon, 9 Nov 2015 19:15:56 +0000 (20:15 +0100)]
Merge pull request #575 from nrc/comments
Option to disable line breaking in comments
Nick Cameron [Mon, 9 Nov 2015 19:03:01 +0000 (08:03 +1300)]
Option to disable line breaking in comments
Set to false by default for now, since we are having a lot of problems with comments. We should set to true once we have a better algorithm.
Nick Cameron [Mon, 9 Nov 2015 06:00:04 +0000 (19:00 +1300)]
Format tuple structs better
closes #546
Nick Cameron [Mon, 9 Nov 2015 00:23:19 +0000 (13:23 +1300)]
Don't strip semi-colons from expressions with non-void type since it can change semantics
Nick Cameron [Sun, 8 Nov 2015 03:41:16 +0000 (22:41 -0500)]
Merge pull request #567 from kamalmarhubi/config-docs-flag
Move config help to dedicated --config-help flag
Kamal Marhubi [Sun, 8 Nov 2015 00:03:25 +0000 (19:03 -0500)]
Move config help to dedicated --config-help flag
The existing help output is very verbose, overflowing a 50+ line
terminal. This moves the configuration options to a separate help flag
to make a mistyped command less annoying!
Nick Cameron [Wed, 4 Nov 2015 23:37:27 +0000 (18:37 -0500)]
Merge pull request #565 from takkanm/fix_unused_variable_path_warning
fix unused variable `path` warning
Mitsutaka Mimura [Wed, 4 Nov 2015 23:14:55 +0000 (08:14 +0900)]
fix unused variable `path` warning
Nick Cameron [Wed, 4 Nov 2015 04:45:01 +0000 (17:45 +1300)]
Add Vim reference to README and reorg
Nick Cameron [Tue, 3 Nov 2015 23:59:43 +0000 (18:59 -0500)]
Merge pull request #560 from Florob/enum_trailing_comma
Honor "enum_trailing_comma" option. Fixes #556
Florian Zeitz [Tue, 3 Nov 2015 22:14:37 +0000 (23:14 +0100)]
Honor "enum_trailing_comma" option. Fixes #556
Nick Cameron [Tue, 3 Nov 2015 08:39:21 +0000 (03:39 -0500)]
Merge pull request #558 from johannhof/master
Stdin support
Johann [Tue, 3 Nov 2015 08:16:33 +0000 (09:16 +0100)]
Address review concerns
Johann [Mon, 2 Nov 2015 19:45:45 +0000 (20:45 +0100)]
Stdin support
Adds support for receiving input from stdin in case no file was
specified. This is useful for editor/IDE integrations and other tooling.
To achieve clean output a new write-mode option called plain was added,
this option is mandatory when using stdin.
Marcus Klaas de Vries [Wed, 28 Oct 2015 07:09:44 +0000 (08:09 +0100)]
Merge pull request #543 from eefriedman/macro-crash
Fix crash speculatively parsing macro arguments as expressions.
Eli Friedman [Wed, 28 Oct 2015 06:41:32 +0000 (23:41 -0700)]
Fix crash speculatively parsing macro arguments as expressions.
The problem is essentially that if we try to parse a token tree using a
CodeMap different from the one the tree was originally parsed with,
spans become nonsense. Since CodeMaps can't be cloned, we're basically
forced to use the original ParseSess for additional parsing.
Ideally, rustfmt would be a bit more clever and figure out how to parse
macro arguments based on the definition of the macro itself, rather than
just guessing that a particular token sequence looks like an expression,
but this is good enough for now.
Fixes #538.