From 4d7e86792892532f05a980fcf446f4497819f4d2 Mon Sep 17 00:00:00 2001 From: Batist Leman Date: Fri, 11 Nov 2016 09:02:20 +0100 Subject: [PATCH] 1. Fix for error when a node module only contains an invisible folder. (bash: line 18: cd: ./*: No such file or directory) --- templates/linux/deploy.sh | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/templates/linux/deploy.sh b/templates/linux/deploy.sh index bbf5c26..bfb0f83 100755 --- a/templates/linux/deploy.sh +++ b/templates/linux/deploy.sh @@ -15,11 +15,13 @@ gyp_rebuild_inside_node_modules () { if [ $isBinaryModule != "yes" ]; then if [ -d ./node_modules ]; then cd ./node_modules - for module in ./*; do - cd $module - check_for_binary_modules - cd .. - done + if [ "$(ls ./ )" ]; then + for module in ./*; do + cd $module + check_for_binary_modules + cd .. + done + fi cd ../ fi fi