2016-04-22 02:19:09 -05:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
# Make sure you double check the diffs after running this script - with great
|
|
|
|
# power comes great responsibility.
|
|
|
|
# We deliberately avoid reformatting files with rustfmt comment directives.
|
|
|
|
|
2017-03-27 17:20:11 -05:00
|
|
|
cargo build --release
|
2016-04-22 02:19:09 -05:00
|
|
|
|
2018-05-12 21:13:24 -05:00
|
|
|
target/release/rustfmt src/lib.rs
|
|
|
|
target/release/rustfmt src/bin/main.rs
|
|
|
|
target/release/rustfmt src/cargo-fmt/main.rs
|
2016-04-22 02:19:09 -05:00
|
|
|
|
|
|
|
for filename in tests/target/*.rs; do
|
|
|
|
if ! grep -q "rustfmt-" "$filename"; then
|
2018-05-12 21:13:24 -05:00
|
|
|
target/release/rustfmt $filename
|
2016-04-22 02:19:09 -05:00
|
|
|
fi
|
|
|
|
done
|