From 60cf7613510b319bb80dbd317ba4a7c8da7b1c49 Mon Sep 17 00:00:00 2001 From: md_5 Date: Mon, 30 Jan 2017 08:35:51 +1100 Subject: BUILDTOOLS-301: Use sh for all scripts. --- src/main/java/org/spigotmc/builder/Builder.java | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) (limited to 'src') diff --git a/src/main/java/org/spigotmc/builder/Builder.java b/src/main/java/org/spigotmc/builder/Builder.java index c7e4c39..1ff6d78 100644 --- a/src/main/java/org/spigotmc/builder/Builder.java +++ b/src/main/java/org/spigotmc/builder/Builder.java @@ -143,18 +143,13 @@ public class Builder System.err.println( "*** WARNING *** Use java -version to check your version and update as soon as possible." ); } - String shell = System.getenv().get( "SHELL" ); - if ( shell == null || shell.trim().isEmpty() ) + try { - shell = "bash"; - try - { - runProcess( CWD, shell, "-c", "exit" ); - } catch ( Exception ex ) - { - System.out.println( "You must run this jar through bash (msysgit)" ); - System.exit( 1 ); - } + runProcess( CWD, "sh", "-c", "exit" ); + } catch ( Exception ex ) + { + System.out.println( "You must run this jar through bash (msysgit)" ); + System.exit( 1 ); } try @@ -431,7 +426,7 @@ public class Builder try { - runProcess( spigot, shell, "applyPatches.sh" ); + runProcess( spigot, "sh", "applyPatches.sh" ); System.out.println( "*** Spigot patches applied!" ); if ( !skipCompile ) -- cgit v1.2.3