From 70df84111de37a0b7f5cc990a8bb6114620fbf72 Mon Sep 17 00:00:00 2001 From: Joe Lauer Date: Sun, 3 Nov 2024 17:46:28 -0500 Subject: [PATCH] Powershell blaze.ps1 to improve ctrl+c not prompting user to terminate a batch file --- .../com/fizzed/blaze/internal/InstallHelper.java | 7 ++++++- blaze-core/src/main/resources/bin/blaze.ps1 | Bin 0 -> 390 bytes 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 blaze-core/src/main/resources/bin/blaze.ps1 diff --git a/blaze-core/src/main/java/com/fizzed/blaze/internal/InstallHelper.java b/blaze-core/src/main/java/com/fizzed/blaze/internal/InstallHelper.java index 7adf2303..96b28a09 100644 --- a/blaze-core/src/main/java/com/fizzed/blaze/internal/InstallHelper.java +++ b/blaze-core/src/main/java/com/fizzed/blaze/internal/InstallHelper.java @@ -38,7 +38,7 @@ static public List installBlazeBinaries(Path installDir) throws MessageOnl } if (!Files.isWritable(installDir)) { - throw new MessageOnlyException("Install directory " + installDir + " is not writable (run this as an Administor or with sudo?)"); + throw new MessageOnlyException("Install directory " + installDir + " is not writable (run this as an Administrator or with sudo?)"); } List installedFiles = new ArrayList<>(); @@ -48,6 +48,11 @@ static public List installBlazeBinaries(Path installDir) throws MessageOnl Path blazeBatFile = installDir.resolve("blaze.bat"); installResource("/bin/blaze.bat", blazeBatFile); installedFiles.add(blazeBatFile); + + // install blaze.ps1 (powershell) + Path blazePs1File = installDir.resolve("blaze.ps1"); + installResource("/bin/blaze.ps1", blazePs1File); + installedFiles.add(blazePs1File); } // for ming32 compat also install the *nix version diff --git a/blaze-core/src/main/resources/bin/blaze.ps1 b/blaze-core/src/main/resources/bin/blaze.ps1 new file mode 100644 index 0000000000000000000000000000000000000000..19a945e37cfc6965b782b540f4e73daad768a245 GIT binary patch literal 390 zcmZ9IyGjE=6o$WA@Ew+63&XmLy$IT*k`S;+Ar@X@jN~F_%&qmrv9-h<3-O2iX5Sfb$N`V6r>kPVGUm!Y*O71&im$lyJS8vYtj(Cp`QPfw zteoGv*|^uQ89Mnw{#Z`Slj$k8d=od;-#y7{%}D2wsAHmL#e=wu&P489b!P2;bjwm^ N-tyAUCVKrp{{@PZJuUzM literal 0 HcmV?d00001