From 21369326cad2ab09bb10eac46ef60c66f57b8ce7 Mon Sep 17 00:00:00 2001 From: Geoffrey Thomas Date: Fri, 7 Feb 2025 10:42:33 -0500 Subject: [PATCH] uv-python tests: Use #!/bin/sh instead of #!/bin/bash (#11292) NixOS has (and POSIX mandates) a /bin/sh but not a /bin/bash, so this fixes tests on NixOS. --- crates/uv-python/src/interpreter.rs | 4 ++-- crates/uv-python/src/lib.rs | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/crates/uv-python/src/interpreter.rs b/crates/uv-python/src/interpreter.rs index 0689aaff6..90ef7daa7 100644 --- a/crates/uv-python/src/interpreter.rs +++ b/crates/uv-python/src/interpreter.rs @@ -1090,7 +1090,7 @@ mod tests { fs::write( &mocked_interpreter, formatdoc! {r" - #!/bin/bash + #!/bin/sh echo '{json}' "}, ) @@ -1109,7 +1109,7 @@ mod tests { fs::write( &mocked_interpreter, formatdoc! {r" - #!/bin/bash + #!/bin/sh echo '{}' ", json.replace("3.12", "3.13")}, ) diff --git a/crates/uv-python/src/lib.rs b/crates/uv-python/src/lib.rs index 9b54823c7..3f4e24c7f 100644 --- a/crates/uv-python/src/lib.rs +++ b/crates/uv-python/src/lib.rs @@ -292,7 +292,7 @@ mod tests { fs_err::write( path, formatdoc! {r" - #!/bin/bash + #!/bin/sh echo '{json}' "}, )?; @@ -314,7 +314,7 @@ mod tests { fs_err::write( path, formatdoc! {r" - #!/bin/bash + #!/bin/sh echo '{output}' 1>&2 "}, )?; @@ -535,7 +535,7 @@ mod tests { fs_err::write( children[0].join(format!("python{}", env::consts::EXE_SUFFIX)), formatdoc! {r" - #!/bin/bash + #!/bin/sh echo 'foo' "}, )?;