From c94564f908187f29de60f968c9dae8b4661e4bf8 Mon Sep 17 00:00:00 2001 From: rami3l Date: Fri, 12 Jul 2024 16:56:56 +0800 Subject: [PATCH] style: reformat all TOMLs with `taplo` --- .cargo/config.toml | 1 - .taplo.toml | 8 ++ Cargo.toml | 47 ++++---- download/Cargo.toml | 5 +- .../tests/channel-rust-nightly-example.toml | 105 +++++++++--------- .../rustup_check_cmd_help_flag_stdout.toml | 2 +- .../rustup_override_cmd_help_flag_stdout.toml | 2 +- ...verride_cmd_list_cmd_help_flag_stdout.toml | 2 +- ..._self_cmd_update_cmd_help_flag_stdout.toml | 2 +- .../rustup_set_cmd_help_flag_stdout.toml | 2 +- ...active-toolchain_cmd_help_flag_stdout.toml | 2 +- .../rustup_show_cmd_help_flag_stdout.toml | 2 +- ...up_show_cmd_home_cmd_help_flag_stdout.toml | 2 +- ...show_cmd_profile_cmd_help_flag_stdout.toml | 2 +- .../rustup_target_cmd_help_flag_stdout.toml | 2 +- ...rustup_toolchain_cmd_help_flag_stdout.toml | 2 +- ...olchain_cmd_list_cmd_help_flag_stdout.toml | 2 +- ...in_cmd_uninstall_cmd_help_flag_stdout.toml | 2 +- .../rustup_up_cmd_help_flag_stdout.toml | 2 +- .../rustup_update_cmd_help_flag_stdout.toml | 2 +- .../rustup_upgrade_cmd_help_flag_stdout.toml | 2 +- triagebot.toml | 14 ++- 22 files changed, 116 insertions(+), 96 deletions(-) create mode 100644 .taplo.toml diff --git a/.cargo/config.toml b/.cargo/config.toml index 610dd9189fb..f229a1ae508 100644 --- a/.cargo/config.toml +++ b/.cargo/config.toml @@ -1,3 +1,2 @@ [alias] dev-install = "run -- --no-modify-path -y" - diff --git a/.taplo.toml b/.taplo.toml new file mode 100644 index 00000000000..f93aa067fe5 --- /dev/null +++ b/.taplo.toml @@ -0,0 +1,8 @@ +include = ["**/*.toml"] + +[[rule]] +include = ["**/Cargo.toml"] +keys = ["dependencies"] + +[rule.formatting] +column_width = 160 diff --git a/Cargo.toml b/Cargo.toml index 8c992eb2d56..352894dca9b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -13,10 +13,10 @@ build = "build.rs" [features] curl-backend = ["download/curl-backend"] default = [ - "curl-backend", - "reqwest-backend", - "reqwest-native-tls", - "reqwest-rustls-tls", + "curl-backend", + "reqwest-backend", + "reqwest-native-tls", + "reqwest-rustls-tls", ] reqwest-backend = ["download/reqwest-backend"] @@ -30,10 +30,10 @@ no-self-update = [] # Include an Opentelemetry sink for tracing events otel = [ - "dep:opentelemetry-otlp", - "dep:tracing-opentelemetry", - "dep:opentelemetry", - "dep:opentelemetry_sdk", + "dep:opentelemetry-otlp", + "dep:tracing-opentelemetry", + "dep:opentelemetry", + "dep:opentelemetry_sdk", ] # Exports code dependent on private interfaces for the integration test suite @@ -100,19 +100,19 @@ winreg = "0.52" [target."cfg(windows)".dependencies.windows-sys] features = [ - "Win32_Foundation", - "Win32_Security", - "Win32_Storage_FileSystem", - "Win32_System_Diagnostics_ToolHelp", - "Win32_System_IO", - "Win32_System_Ioctl", - "Win32_System_JobObjects", - "Win32_System_Kernel", - "Win32_System_LibraryLoader", - "Win32_System_SystemInformation", - "Win32_System_SystemServices", - "Win32_System_Threading", - "Win32_System_WindowsProgramming", + "Win32_Foundation", + "Win32_Security", + "Win32_Storage_FileSystem", + "Win32_System_Diagnostics_ToolHelp", + "Win32_System_IO", + "Win32_System_Ioctl", + "Win32_System_JobObjects", + "Win32_System_Kernel", + "Win32_System_LibraryLoader", + "Win32_System_SystemInformation", + "Win32_System_SystemServices", + "Win32_System_Threading", + "Win32_System_WindowsProgramming", ] version = "0.52.0" @@ -143,7 +143,10 @@ proptest = "1.1.0" tempfile = "3.8" termcolor = "1.2" thiserror = "1.0" -tokio = { version = "1.26.0", default-features = false, features = ["macros", "rt-multi-thread"] } +tokio = { version = "1.26.0", default-features = false, features = [ + "macros", + "rt-multi-thread", +] } tokio-retry = { version = "0.3.0" } tokio-stream = { version = "0.1.14" } tracing = "0.1" diff --git a/download/Cargo.toml b/download/Cargo.toml index 4d599607702..c40b4d671dd 100644 --- a/download/Cargo.toml +++ b/download/Cargo.toml @@ -31,6 +31,9 @@ url.workspace = true [dev-dependencies] http-body-util = "0.1.0" -hyper = { version = "1.0", default-features = false, features = ["server", "http1"] } +hyper = { version = "1.0", default-features = false, features = [ + "server", + "http1", +] } hyper-util = { version = "0.1.1", features = ["tokio"] } tempfile.workspace = true diff --git a/src/dist/manifest/tests/channel-rust-nightly-example.toml b/src/dist/manifest/tests/channel-rust-nightly-example.toml index bc78c286231..86297b5ab70 100644 --- a/src/dist/manifest/tests/channel-rust-nightly-example.toml +++ b/src/dist/manifest/tests/channel-rust-nightly-example.toml @@ -1,60 +1,59 @@ manifest-version = "2" date = "2015-10-10" [pkg.rust] - version = "rustc 1.3.0 (9a92aaf19 2015-09-15)" - [pkg.rust.target.x86_64-unknown-linux-gnu] - available = true - url = "example.com" - hash = "..." - [[pkg.rust.target.x86_64-unknown-linux-gnu.components]] - pkg = "rustc" - target = "x86_64-unknown-linux-gnu" - [[pkg.rust.target.x86_64-unknown-linux-gnu.components]] - pkg = "rust-docs" - target = "x86_64-unknown-linux-gnu" - [[pkg.rust.target.x86_64-unknown-linux-gnu.components]] - pkg = "cargo" - target = "x86_64-unknown-linux-gnu" - [[pkg.rust.target.x86_64-unknown-linux-gnu.components]] - pkg = "rust-std" - target = "x86_64-unknown-linux-gnu" - # extensions are rust-std or rust-docs that aren't in the rust tarball's component list - [[pkg.rust.target.x86_64-unknown-linux-gnu.extensions]] - pkg = "rust-std" - target = "x86_64-unknown-linux-musl" - [[pkg.rust.target.x86_64-unknown-linux-gnu.extensions]] - pkg = "rust-std" - target = "i686-unknown-linux-gnu" +version = "rustc 1.3.0 (9a92aaf19 2015-09-15)" +[pkg.rust.target.x86_64-unknown-linux-gnu] +available = true +url = "example.com" +hash = "..." +[[pkg.rust.target.x86_64-unknown-linux-gnu.components]] +pkg = "rustc" +target = "x86_64-unknown-linux-gnu" +[[pkg.rust.target.x86_64-unknown-linux-gnu.components]] +pkg = "rust-docs" +target = "x86_64-unknown-linux-gnu" +[[pkg.rust.target.x86_64-unknown-linux-gnu.components]] +pkg = "cargo" +target = "x86_64-unknown-linux-gnu" +[[pkg.rust.target.x86_64-unknown-linux-gnu.components]] +pkg = "rust-std" +target = "x86_64-unknown-linux-gnu" +# extensions are rust-std or rust-docs that aren't in the rust tarball's component list +[[pkg.rust.target.x86_64-unknown-linux-gnu.extensions]] +pkg = "rust-std" +target = "x86_64-unknown-linux-musl" +[[pkg.rust.target.x86_64-unknown-linux-gnu.extensions]] +pkg = "rust-std" +target = "i686-unknown-linux-gnu" [pkg.rustc] - version = "rustc 1.3.0 (9a92aaf19 2015-09-15)" - [pkg.rustc.target.x86_64-unknown-linux-gnu] - available = true - url = "example.com" - hash = "..." +version = "rustc 1.3.0 (9a92aaf19 2015-09-15)" +[pkg.rustc.target.x86_64-unknown-linux-gnu] +available = true +url = "example.com" +hash = "..." [pkg.cargo] - version = "cargo 0.4.0-nightly (553b363 2015-08-03)" - [pkg.cargo.target.x86_64-unknown-linux-gnu] - available = true - url = "example.com" - hash = "..." +version = "cargo 0.4.0-nightly (553b363 2015-08-03)" +[pkg.cargo.target.x86_64-unknown-linux-gnu] +available = true +url = "example.com" +hash = "..." [pkg.rust-std] - version = "rustc 1.3.0 (9a92aaf19 2015-09-15)" - [pkg.rust-std.target.x86_64-unknown-linux-gnu] - available = true - url = "example.com" - hash = "..." - [pkg.rust-std.target.x86_64-unknown-linux-musl] - available = true - url = "example.com" - hash = "..." - [pkg.rust-std.target.i686-unknown-linux-gnu] - available = true - url = "example.com" - hash = "..." +version = "rustc 1.3.0 (9a92aaf19 2015-09-15)" +[pkg.rust-std.target.x86_64-unknown-linux-gnu] +available = true +url = "example.com" +hash = "..." +[pkg.rust-std.target.x86_64-unknown-linux-musl] +available = true +url = "example.com" +hash = "..." +[pkg.rust-std.target.i686-unknown-linux-gnu] +available = true +url = "example.com" +hash = "..." [pkg.rust-docs] - version = "rustc 1.3.0 (9a92aaf19 2015-09-15)" - [pkg.rust-docs.target.x86_64-unknown-linux-gnu] - available = true - url = "example.com" - hash = "..." - +version = "rustc 1.3.0 (9a92aaf19 2015-09-15)" +[pkg.rust-docs.target.x86_64-unknown-linux-gnu] +available = true +url = "example.com" +hash = "..." diff --git a/tests/suite/cli-ui/rustup/rustup_check_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_check_cmd_help_flag_stdout.toml index 86cc59070be..2ff2f744e5f 100644 --- a/tests/suite/cli-ui/rustup/rustup_check_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_check_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["check","--help"] +args = ["check", "--help"] stdout = """ ... Check for updates to Rust toolchains and rustup diff --git a/tests/suite/cli-ui/rustup/rustup_override_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_override_cmd_help_flag_stdout.toml index 27bc0713a41..66546023a03 100644 --- a/tests/suite/cli-ui/rustup/rustup_override_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_override_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["override","--help"] +args = ["override", "--help"] stdout = """ ... Modify toolchain overrides for directories diff --git a/tests/suite/cli-ui/rustup/rustup_override_cmd_list_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_override_cmd_list_cmd_help_flag_stdout.toml index 8d90aca23eb..1a1e7353673 100644 --- a/tests/suite/cli-ui/rustup/rustup_override_cmd_list_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_override_cmd_list_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["override","list","--help"] +args = ["override", "list", "--help"] stdout = """ ... List directory toolchain overrides diff --git a/tests/suite/cli-ui/rustup/rustup_self_cmd_update_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_self_cmd_update_cmd_help_flag_stdout.toml index e5472f27830..90ffe32d710 100644 --- a/tests/suite/cli-ui/rustup/rustup_self_cmd_update_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_self_cmd_update_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["self","update","--help"] +args = ["self", "update", "--help"] stdout = """ ... Download and install updates to rustup diff --git a/tests/suite/cli-ui/rustup/rustup_set_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_set_cmd_help_flag_stdout.toml index 3d5ffe91f55..938b8ab0d3d 100644 --- a/tests/suite/cli-ui/rustup/rustup_set_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_set_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["set","--help"] +args = ["set", "--help"] stdout = """ ... Alter rustup settings diff --git a/tests/suite/cli-ui/rustup/rustup_show_cmd_active-toolchain_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_show_cmd_active-toolchain_cmd_help_flag_stdout.toml index 006f8e3f7fb..d06aab867e2 100644 --- a/tests/suite/cli-ui/rustup/rustup_show_cmd_active-toolchain_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_show_cmd_active-toolchain_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["show","active-toolchain","--help"] +args = ["show", "active-toolchain", "--help"] stdout = """ ... Show the active toolchain diff --git a/tests/suite/cli-ui/rustup/rustup_show_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_show_cmd_help_flag_stdout.toml index 4291fc5a337..6f2e81e48e4 100644 --- a/tests/suite/cli-ui/rustup/rustup_show_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_show_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["show","--help"] +args = ["show", "--help"] stdout = """ ... Show the active and installed toolchains or profiles diff --git a/tests/suite/cli-ui/rustup/rustup_show_cmd_home_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_show_cmd_home_cmd_help_flag_stdout.toml index b98cb165c3b..6283c5e97a3 100644 --- a/tests/suite/cli-ui/rustup/rustup_show_cmd_home_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_show_cmd_home_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["show","home","--help"] +args = ["show", "home", "--help"] stdout = """ ... Display the computed value of RUSTUP_HOME diff --git a/tests/suite/cli-ui/rustup/rustup_show_cmd_profile_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_show_cmd_profile_cmd_help_flag_stdout.toml index b0449e26701..e814a1f9c33 100644 --- a/tests/suite/cli-ui/rustup/rustup_show_cmd_profile_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_show_cmd_profile_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["show","profile","--help"] +args = ["show", "profile", "--help"] stdout = """ ... Show the default profile used for the `rustup install` command diff --git a/tests/suite/cli-ui/rustup/rustup_target_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_target_cmd_help_flag_stdout.toml index a1b723e37c8..c5ed7dca271 100644 --- a/tests/suite/cli-ui/rustup/rustup_target_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_target_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["target","--help"] +args = ["target", "--help"] stdout = """ ... Modify a toolchain's supported targets diff --git a/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_help_flag_stdout.toml index 87bcb893b64..9485b6323b4 100644 --- a/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["toolchain","--help"] +args = ["toolchain", "--help"] stdout = """ ... Modify or query the installed toolchains diff --git a/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_list_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_list_cmd_help_flag_stdout.toml index 8669885d014..ea6eff1bfd8 100644 --- a/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_list_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_list_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["toolchain","list","--help"] +args = ["toolchain", "list", "--help"] stdout = """ ... List installed toolchains diff --git a/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_uninstall_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_uninstall_cmd_help_flag_stdout.toml index d79a2a20157..42be34c34a2 100644 --- a/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_uninstall_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_toolchain_cmd_uninstall_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["toolchain","uninstall","--help"] +args = ["toolchain", "uninstall", "--help"] stdout = """ ... Uninstall a toolchain diff --git a/tests/suite/cli-ui/rustup/rustup_up_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_up_cmd_help_flag_stdout.toml index 58aa50511e7..2710d20a559 100644 --- a/tests/suite/cli-ui/rustup/rustup_up_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_up_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["up","--help"] +args = ["up", "--help"] stdout = """ ... Update Rust toolchains and rustup diff --git a/tests/suite/cli-ui/rustup/rustup_update_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_update_cmd_help_flag_stdout.toml index 59294d8dca6..ce1a69e5fdf 100644 --- a/tests/suite/cli-ui/rustup/rustup_update_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_update_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["update","--help"] +args = ["update", "--help"] stdout = """ ... Update Rust toolchains and rustup diff --git a/tests/suite/cli-ui/rustup/rustup_upgrade_cmd_help_flag_stdout.toml b/tests/suite/cli-ui/rustup/rustup_upgrade_cmd_help_flag_stdout.toml index 94d10f9f448..1c91e425a58 100644 --- a/tests/suite/cli-ui/rustup/rustup_upgrade_cmd_help_flag_stdout.toml +++ b/tests/suite/cli-ui/rustup/rustup_upgrade_cmd_help_flag_stdout.toml @@ -1,5 +1,5 @@ bin.name = "rustup" -args = ["upgrade","--help"] +args = ["upgrade", "--help"] stdout = """ ... Update Rust toolchains and rustup diff --git a/triagebot.toml b/triagebot.toml index 1bbac476e99..b70ca8996f8 100644 --- a/triagebot.toml +++ b/triagebot.toml @@ -1,9 +1,17 @@ [relabel] allow-unauthenticated = [ - "bug", "duplicate", "enhancement", "forwarded", - "performance", "question", "security", "tracking", "website", - "O-*", "A-*" + "bug", + "duplicate", + "enhancement", + "forwarded", + "performance", + "question", + "security", + "tracking", + "website", + "O-*", + "A-*", ] [assign]