]>
git.lizzy.rs Git - rust.git/log
Mark Story [Fri, 15 Jan 2016 03:04:24 +0000 (22:04 -0500)]
Clean up function names for checkstyle output.
Mark Story [Thu, 14 Jan 2016 01:56:35 +0000 (20:56 -0500)]
Use PartialEq/Eq implementation instead of match.
Also cleanup from rebasing onto master.
Mark Story [Wed, 13 Jan 2016 05:22:30 +0000 (00:22 -0500)]
Extract checkstyle output into a separate module.
Rename functions a bit now that they are specific to checkstyle output.
Mark Story [Sat, 9 Jan 2016 03:38:27 +0000 (22:38 -0500)]
Update based on pull request feedback.
* Extract duplicated logic.
* Make checkstyle errors into warnings.
Mark Story [Mon, 4 Jan 2016 04:17:49 +0000 (23:17 -0500)]
Encode XML entities.
Mark Story [Thu, 31 Dec 2015 05:33:51 +0000 (00:33 -0500)]
Remove unused argument.
Mark Story [Thu, 31 Dec 2015 05:33:07 +0000 (00:33 -0500)]
Fix formatting errors.
Mark Story [Wed, 30 Dec 2015 04:54:35 +0000 (23:54 -0500)]
Hack together checkstyle output that compiles.
I'm not sure it does something useful yet though.
Mark Story [Mon, 28 Dec 2015 04:13:32 +0000 (23:13 -0500)]
Start hacking checkstyle output in.
checkstyle now shows up on the option parser, and the code still
compiles/passes tests. Next up will be outputing the XML to stdout.
Marcus Klaas de Vries [Wed, 13 Jan 2016 17:11:11 +0000 (18:11 +0100)]
Merge pull request #769 from svmnotn/write-mode-config
Allow for setting of write-mode via config file. FIxes #215
Victor M. Suarez [Tue, 12 Jan 2016 23:12:48 +0000 (18:12 -0500)]
Allow for setting of write-mode via config file. FIxes #215
Also from @marcusklaas:
Refactor code output functions
Specifically, `write_all_files` no longer returns a HashMap. It would sometimes
contain items, and sometimes be empty. When "fixed" newlines are required, this
must now be done with a separate call. The tests use this strategy and should now pass!
Marcus Klaas de Vries [Tue, 12 Jan 2016 21:52:34 +0000 (22:52 +0100)]
Merge pull request #766 from ConnorGBrewster/fix-#489
Added option for tighter punctuation in types. fixes #489
Marcus Klaas de Vries [Tue, 12 Jan 2016 20:53:19 +0000 (21:53 +0100)]
Merge pull request #768 from DarkDrek/amend-to-fix-#447
fixes parsing issue #767
Connor Brewster [Tue, 12 Jan 2016 20:51:32 +0000 (13:51 -0700)]
Added test case
Connor Brewster [Tue, 12 Jan 2016 20:42:53 +0000 (13:42 -0700)]
Changed TypeDensity::WhiteSpace to TypeDensity::Wide
Changed eq_str and plus_str assignments to use a match
Marcus Klaas de Vries [Tue, 12 Jan 2016 20:17:45 +0000 (21:17 +0100)]
Merge pull request #757 from ConnorGBrewster/fix-#650
Fix for #650
DarkDrek [Tue, 12 Jan 2016 20:13:59 +0000 (21:13 +0100)]
fixes parsing issue #767
Connor Brewster [Sun, 10 Jan 2016 05:45:58 +0000 (22:45 -0700)]
If where is on the same line as the impl, { is put on the same line fixes #650
factored if clause into a separate function
Nick Cameron [Tue, 12 Jan 2016 02:41:16 +0000 (15:41 +1300)]
Merge pull request #765 from DarkDrek/fix-#447-2
Fix #447 2. try
DarkDrek [Tue, 12 Jan 2016 00:32:29 +0000 (01:32 +0100)]
Removed the failing test part since it will work when #754 is accepted
DarkDrek [Tue, 12 Jan 2016 00:09:08 +0000 (01:09 +0100)]
Handle more possible comment position for if else
Extended the test with the new possiblecomment positions
DarkDrek [Sun, 10 Jan 2016 04:20:35 +0000 (05:20 +0100)]
Keep comments between if and else blocks. Fixes #447
Nick Cameron [Tue, 12 Jan 2016 01:49:59 +0000 (14:49 +1300)]
Merge pull request #762 from ConnorGBrewster/fix-#760
Where clause is on same line as fn if fn is empty Fixes #760
Connor Brewster [Mon, 11 Jan 2016 21:47:56 +0000 (14:47 -0700)]
Changed is_block_empty to has_body
Connor Brewster [Mon, 11 Jan 2016 19:26:57 +0000 (12:26 -0700)]
Added option for tighter punctuation in types. fixes #489
Connor Brewster [Mon, 11 Jan 2016 05:06:06 +0000 (22:06 -0700)]
Where clause is on same line as fn if fn is empty fix-#760
only applies if fn_empty_single_line is set to true
cassiersg [Mon, 11 Jan 2016 00:16:52 +0000 (01:16 +0100)]
Merge pull request #756 from cassiersg/missed-comments
Detect (and recover) when comments disappear
Nick Cameron [Sun, 10 Jan 2016 21:45:51 +0000 (10:45 +1300)]
Merge pull request #740 from svmnotn/less_tmp_files
stop creating bk files if there are no changes. Fixes #733
Victor M. Suarez [Sun, 3 Jan 2016 04:21:55 +0000 (23:21 -0500)]
stop creating bk files if there are no changes. Fixes #733
Nick Cameron [Sun, 10 Jan 2016 21:24:14 +0000 (10:24 +1300)]
Merge pull request #758 from cassiersg/issue-717
Fix issue with windows line endings (#717).
Gaëtan Cassiers [Sun, 10 Jan 2016 21:04:30 +0000 (22:04 +0100)]
Document comment::*CodeCharKind
Gaëtan Cassiers [Sun, 10 Jan 2016 15:25:31 +0000 (16:25 +0100)]
Fix issue with windows line endings (#717).
The '\r' character wasn't counted in the line length.
Gaëtan Cassiers [Sun, 10 Jan 2016 14:12:15 +0000 (15:12 +0100)]
Detect when comments disappear
When the reformatted code doesn't contain the same quantity of comments
as the original code, use the original code instead of the reformatted
code.
This is done for all expressions and `let` statements.
This should be used at the finest grained level possible, to avoid that
a small disappearing comment prevents a big chunk of code to be
reformatted.
Kind of fixes (avoid disappearing comments, but prevents a good
formatting is such case) #285 #225 #563 #743
Marcus Klaas de Vries [Fri, 8 Jan 2016 13:39:04 +0000 (14:39 +0100)]
Merge pull request #749 from sanxiyn/skip-arm
Add commas after skipped arms when needed
Seo Sanghyeon [Fri, 8 Jan 2016 08:03:41 +0000 (17:03 +0900)]
Add commas after skipped arms when needed
Nick Cameron [Thu, 7 Jan 2016 07:15:49 +0000 (20:15 +1300)]
Merge pull request #747 from Manishearth/clippy
Clippy rustfmt
Manish Goregaokar [Thu, 7 Jan 2016 06:43:45 +0000 (12:13 +0530)]
Clippy rustfmt
Nick Cameron [Wed, 6 Jan 2016 03:48:11 +0000 (16:48 +1300)]
Merge pull request #744 from sanxiyn/wildcard-arm
Trailing commas for wildcard arms
Seo Sanghyeon [Wed, 6 Jan 2016 02:02:01 +0000 (11:02 +0900)]
Trailing commas for wildcard arms
Nick Cameron [Mon, 4 Jan 2016 18:40:03 +0000 (07:40 +1300)]
Merge pull request #739 from svmnotn/case_insensitive_config_options
ignore case for config enums. Fixes #738
Victor M. Suarez [Sun, 3 Jan 2016 01:47:10 +0000 (20:47 -0500)]
ignore case for config enums. Fixes #738
Marcus Klaas de Vries [Sat, 2 Jan 2016 16:46:35 +0000 (17:46 +0100)]
Merge pull request #736 from sinhpham/vsc_doc
Add doc for Visual Studio Code plugins
Marcus Klaas de Vries [Fri, 1 Jan 2016 19:21:15 +0000 (20:21 +0100)]
Merge pull request #734 from sinhpham/issue_700
Fixed #700
Sinh Pham [Fri, 1 Jan 2016 17:30:36 +0000 (09:30 -0800)]
Add doc for Visual Studio Code plugins
Sinh Pham [Thu, 31 Dec 2015 23:02:44 +0000 (15:02 -0800)]
Fixed #700, use default color for titles and context in write-mode=diff
Marcus Klaas de Vries [Mon, 28 Dec 2015 16:45:56 +0000 (17:45 +0100)]
Merge pull request #732 from utkarshkukreti/update-diff-to-0.1.8
Update diff to 0.1.8
Utkarsh Kukreti [Mon, 28 Dec 2015 11:53:34 +0000 (17:23 +0530)]
Add tests for #606.
Utkarsh Kukreti [Mon, 28 Dec 2015 06:10:47 +0000 (11:40 +0530)]
Bump diff to 0.1.8. Fixes #606.
Marcus Klaas de Vries [Sun, 27 Dec 2015 14:09:14 +0000 (15:09 +0100)]
Merge pull request #729 from marcusklaas/funky-self
Make fn argument formatting more resilient for complex self types
Marcus Klaas [Sun, 27 Dec 2015 13:25:37 +0000 (14:25 +0100)]
Make fn argument formatting more resilient for complex self types
Nick Cameron [Sat, 26 Dec 2015 20:18:20 +0000 (09:18 +1300)]
Merge pull request #728 from marcusklaas/typed-mut-self
format typed mut self
Nick Cameron [Sat, 26 Dec 2015 20:15:34 +0000 (09:15 +1300)]
Merge pull request #726 from marcusklaas/string-backslashes
Prevent incorrect backslash removal in strings
Marcus Klaas [Fri, 25 Dec 2015 19:59:46 +0000 (20:59 +0100)]
Reduce dependency on pprust
Marcus Klaas [Fri, 25 Dec 2015 18:07:51 +0000 (19:07 +0100)]
Preserve mutability for typed self arguments
Marcus Klaas [Fri, 25 Dec 2015 17:50:40 +0000 (18:50 +0100)]
Prevent incorrect backslash removal in strings
Nick Cameron [Wed, 23 Dec 2015 22:11:56 +0000 (11:11 +1300)]
Merge pull request #722 from matklad/test-ignore-children
test ignored out of line modules
Aleksey Kladov [Wed, 23 Dec 2015 21:15:29 +0000 (00:15 +0300)]
test ignored out of line modules
tests #719
Nick Cameron [Wed, 23 Dec 2015 20:34:18 +0000 (09:34 +1300)]
Merge pull request #720 from matklad/update-lcok
update Cargo.lock to match Cargo.toml
Nick Cameron [Wed, 23 Dec 2015 20:32:44 +0000 (09:32 +1300)]
Merge pull request #719 from matklad/ignore-child-mods
add option to ignore out of line modules
Aleksey Kladov [Wed, 23 Dec 2015 14:31:54 +0000 (17:31 +0300)]
update Cargo.lock to match Cargo.toml
Aleksey Kladov [Wed, 23 Dec 2015 14:25:49 +0000 (17:25 +0300)]
add option to ignore out of line modules
Nick Cameron [Sun, 20 Dec 2015 18:50:02 +0000 (07:50 +1300)]
Merge pull request #713 from JanLikar/master
Add verbose and quiet flags to cargo-fmt
Jan Likar [Sun, 20 Dec 2015 03:19:08 +0000 (04:19 +0100)]
Add verbose and quiet flags to cargo-fmt
Quiet mode supresses rustfmt's stdout, verbose mode prints targets that
are going to be formatted.
Nick Cameron [Thu, 17 Dec 2015 19:43:41 +0000 (08:43 +1300)]
Merge pull request #710 from JanLikar/master
Remove `--write-mode=replace` from cargo-fmt
Jan Likar [Thu, 17 Dec 2015 16:17:43 +0000 (17:17 +0100)]
Remove `--write-mode=replace` from cargo-fmt
Since replace is the default rustfmt write mode, there's no need to
call rustfmt with `--write-mode=replace`. As a bonus, it is now also
possible to override the write-mode.
Marcus Klaas de Vries [Wed, 16 Dec 2015 17:43:19 +0000 (18:43 +0100)]
Merge pull request #704 from Sean1708/patch-1
Fix spelling mistake in cargo-fmt usage string.
Sean Marshallsay [Wed, 16 Dec 2015 12:18:18 +0000 (12:18 +0000)]
Fix spelling mistake in cargo-fmt usage string.
Nick Cameron [Wed, 16 Dec 2015 05:07:59 +0000 (18:07 +1300)]
Use replace rather than overwrite for cargo fmt
Nick Cameron [Wed, 16 Dec 2015 05:00:40 +0000 (18:00 +1300)]
make cargo install easier
Nick Cameron [Wed, 16 Dec 2015 04:58:20 +0000 (17:58 +1300)]
Add quick start info to README.md, cargo update.
Nick Cameron [Wed, 16 Dec 2015 04:51:29 +0000 (17:51 +1300)]
Merge pull request #703 from JanLikar/cargo-fmt
Add cargo-fmt binary
Jan Likar [Wed, 16 Dec 2015 03:48:49 +0000 (04:48 +0100)]
Allow to pass arguments to rustfmt
Jan Likar [Wed, 16 Dec 2015 03:41:58 +0000 (04:41 +0100)]
Improve README.md
Jan Likar [Wed, 16 Dec 2015 01:21:43 +0000 (02:21 +0100)]
Replace `locate-project` with `read-manifest`
Use `cargo read-manifest` instead of `cargo locate-project` to get
a list of files to be formatted.
Jan Likar [Tue, 15 Dec 2015 22:57:05 +0000 (23:57 +0100)]
Remove unneeded dependencies
Remove dependency on Walkdir, which is no longer needed, because
cargo-fmt now uses cargo read-manifest to get a list of targets to
format.
Jan Likar [Tue, 15 Dec 2015 00:18:47 +0000 (01:18 +0100)]
Edit README.md
- Add instructions for using cargo run with multiple binaries
- Mention cargo-fmt binary
Jan Likar [Mon, 14 Dec 2015 14:50:19 +0000 (15:50 +0100)]
Add cargo-fmt binary
Add a new utility, which formats all readable .rs files in the src
directory of the crate using rustfmt. Both binaries can be installed
using cargo install rustfmt. cargo-fmt can be used as a Cargo
subcommand - cargo fmt.
Jan Likar [Mon, 14 Dec 2015 14:49:46 +0000 (15:49 +0100)]
Update Cargo.lock
Jan Likar [Mon, 14 Dec 2015 14:32:03 +0000 (15:32 +0100)]
Change Cargo.toml
Change Cargo.toml to include cargo-fmt's dependencies and add a
default cargo-fmt feature to enable users to only build rustfmt
if they don't need cargo-fmt.
Marcus Klaas de Vries [Sun, 13 Dec 2015 19:20:29 +0000 (20:20 +0100)]
Merge pull request #697 from rust-lang-nursery/crates
Use crates.io for everything
Nick Cameron [Sun, 13 Dec 2015 19:17:26 +0000 (08:17 +1300)]
Fix the notes on running rustfmt
Nick Cameron [Sun, 13 Dec 2015 19:03:58 +0000 (08:03 +1300)]
Use crates.io for everything
Nick Cameron [Sun, 13 Dec 2015 18:50:56 +0000 (07:50 +1300)]
Merge pull request #695 from marcusklaas/string-rewrite-backslash
Prevent backslash stripping in string literals
Nick Cameron [Sun, 13 Dec 2015 18:50:16 +0000 (07:50 +1300)]
Merge pull request #694 from marcusklaas/master1001
Don't panic on function return type rewrite failure
Marcus Klaas [Sat, 12 Dec 2015 15:20:53 +0000 (16:20 +0100)]
Prevent backslash stripping in string literals
Marcus Klaas [Sat, 12 Dec 2015 14:41:10 +0000 (15:41 +0100)]
Don't panic on function return type rewrite failure
Marcus Klaas de Vries [Sat, 12 Dec 2015 13:44:31 +0000 (14:44 +0100)]
Merge pull request #693 from vincenting/master
add sublime text 3 binding plugin link
vincenting [Sat, 12 Dec 2015 02:11:09 +0000 (10:11 +0800)]
add sublime text 3 binding plugin link
Nick Cameron [Wed, 9 Dec 2015 20:32:11 +0000 (09:32 +1300)]
Merge pull request #681 from rust-lang-nursery/comment-style
Add normalise_comments option.
Nick Cameron [Tue, 8 Dec 2015 04:04:40 +0000 (17:04 +1300)]
Add normalise_comments option.
So block comments are not converted to line comments
Nick Cameron [Tue, 8 Dec 2015 03:19:23 +0000 (16:19 +1300)]
cargo upgrade, bug fix, and prepare for packaging
Nick Cameron [Sun, 6 Dec 2015 20:01:38 +0000 (09:01 +1300)]
Merge pull request #678 from marcusklaas/length-one-tuplez
Fixed named arguments in bare function types
Nick Cameron [Sun, 6 Dec 2015 19:33:02 +0000 (08:33 +1300)]
Merge pull request #664 from marcusklaas/fix-reformat-failurez
Don't include failed item rewrites in missed spans
Nick Cameron [Sun, 6 Dec 2015 19:10:06 +0000 (08:10 +1300)]
Merge pull request #668 from marcusklaas/regression-tests
Regression tests
Nick Cameron [Sun, 6 Dec 2015 19:07:23 +0000 (08:07 +1300)]
Merge pull request #666 from marcusklaas/matches-5000
Break function headers earlier
Nick Cameron [Sun, 6 Dec 2015 18:32:16 +0000 (07:32 +1300)]
Merge pull request #615 from JanLikar/version
Add --version switch
Marcus Klaas [Sun, 6 Dec 2015 00:11:26 +0000 (01:11 +0100)]
Fixed named arguments in bare function types
Marcus Klaas de Vries [Fri, 4 Dec 2015 15:37:59 +0000 (16:37 +0100)]
Merge pull request #674 from Ms2ger/start
Use starts_with to avoid panics.
Marcus Klaas de Vries [Fri, 4 Dec 2015 15:37:32 +0000 (16:37 +0100)]
Merge pull request #673 from Manishearth/clippy
Minor clippy fixes r? @nrc
Ms2ger [Fri, 4 Dec 2015 15:10:14 +0000 (16:10 +0100)]
Use starts_with to avoid panics.