From 34d2a5dee8cc51142dac214a731e20e891ae996b Mon Sep 17 00:00:00 2001 From: Guido Scheffler Date: Thu, 23 Jan 2020 11:24:02 +0100 Subject: [PATCH 1/2] support spaces in path to husky.local.sh added quotes to achieve that --- sh/husky.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sh/husky.sh b/sh/husky.sh index b8d044a73..1b774325d 100644 --- a/sh/husky.sh +++ b/sh/husky.sh @@ -53,7 +53,7 @@ if [ "$HUSKY_SKIP_HOOKS" = "true" ] || [ "$HUSKY_SKIP_HOOKS" = "1" ]; then fi # Source user var and change directory -. "$(dirname $0)/husky.local.sh" +. "$(dirname "$0")/husky.local.sh" debug "Current working directory is $(pwd)" # Skip fast if hookName is not defined From ec77c615796e27f02ada561b6fd6de81d0a8450f Mon Sep 17 00:00:00 2001 From: Guido Scheffler Date: Thu, 23 Jan 2020 12:01:00 +0100 Subject: [PATCH 2/2] updates snapshot test --- src/installer/__tests__/__snapshots__/scripts.ts.snap | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/installer/__tests__/__snapshots__/scripts.ts.snap b/src/installer/__tests__/__snapshots__/scripts.ts.snap index 250abdcfa..410c1a1c0 100644 --- a/src/installer/__tests__/__snapshots__/scripts.ts.snap +++ b/src/installer/__tests__/__snapshots__/scripts.ts.snap @@ -82,7 +82,7 @@ if [ \\"$HUSKY_SKIP_HOOKS\\" = \\"true\\" ] || [ \\"$HUSKY_SKIP_HOOKS\\" = \\"1\ fi # Source user var and change directory -. \\"$(dirname $0)/husky.local.sh\\" +. \\"$(dirname \\"$0\\")/husky.local.sh\\" debug \\"Current working directory is $(pwd)\\" # Skip fast if hookName is not defined