From 758ff779a01df9e1560210b08c0dccb3fff312a3 Mon Sep 17 00:00:00 2001 From: Bryson Steck Date: Sun, 5 Jun 2022 02:13:36 -0600 Subject: add cmd for wit --- patch_iso.sh | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/patch_iso.sh b/patch_iso.sh index 5609176..0b5d82c 100755 --- a/patch_iso.sh +++ b/patch_iso.sh @@ -143,8 +143,13 @@ fi # start extract ----------------------------------------------------------------- -wit extract $1 RMCE01 -ERROR="$?" +if [[ $CYGWIN ]]; then + cmd /C wit extract $1 RMCE01 + ERROR="$?" +else + wit extract $1 RMCE01 + ERROR="$?" +fi if [[ ERROR -ne 0 ]]; then echo "ERROR: wit has returned non-zero exit code $ERROR. Please check that your disc image is authentic and valid." @@ -315,8 +320,13 @@ fi # build ------------------------------------------------------------------------- -wit mix RMCE01/ -B --dest riibalanced.wbfs -wit edit riibalanced.wbfs --name MarioKartRiibalanced +if [[ $CYGWIN ]]; then + cmd /C wit mix RMCE01\ -B --dest riibalanced.wbfs + cmd /C wit edit riibalanced.wbfs --name MarioKartRiibalanced +else + wit mix RMCE01/ -B --dest riibalanced.wbfs + wit edit riibalanced.wbfs --name MarioKartRiibalanced +fi rm -rf RMCE01/ echo "The patch is now complete. The resulting file is 'riibalanced.wbfs'. Enjoy!" -- cgit v1.2.3