Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
djc committed Jun 12, 2024
1 parent dfc9205 commit 84e01b5
Show file tree
Hide file tree
Showing 30 changed files with 651 additions and 500 deletions.
6 changes: 3 additions & 3 deletions src/bin/rustup-init.rs
Original file line number Diff line number Diff line change
Expand Up @@ -98,11 +98,11 @@ async fn maybe_trace_rustup() -> Result<utils::ExitCode> {

#[cfg_attr(feature = "otel", tracing::instrument)]
async fn run_rustup() -> Result<utils::ExitCode> {
if let Ok(dir) = process().var("RUSTUP_TRACE_DIR") {
if let Ok(dir) = process.var("RUSTUP_TRACE_DIR") {
open_trace_file!(dir)?;
}
let result = run_rustup_inner().await;
if process().var("RUSTUP_TRACE_DIR").is_ok() {
if process.var("RUSTUP_TRACE_DIR").is_ok() {
close_trace_file!();
}
result
Expand All @@ -121,7 +121,7 @@ async fn run_rustup_inner() -> Result<utils::ExitCode> {
.context(RustupError::LocatingWorkingDir)?;
utils::current_exe()?;

match process().name().as_deref() {
match process.name().as_deref() {
Some("rustup") => rustup_mode::main(current_dir).await,
Some(n) if n.starts_with("rustup-setup") || n.starts_with("rustup-init") => {
// NB: The above check is only for the prefix of the file
Expand Down
Loading

0 comments on commit 84e01b5

Please sign in to comment.