From b59756173dba028b72c307d31f607a6f1429f9b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BA=90=E6=96=87=E9=9B=A8?= <41315874+fumiama@users.noreply.github.com> Date: Thu, 18 Apr 2024 01:59:11 +0900 Subject: [PATCH] fix(shell): bash error --- pckcfg.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pckcfg.sh b/pckcfg.sh index 3dafb6e..d0642cc 100755 --- a/pckcfg.sh +++ b/pckcfg.sh @@ -1,7 +1,10 @@ #!/bin/sh # Should be run by go generate. DO NOT run it directly. -files=($(find $@ | grep -v .DS_Store | sort)) +files=() +while IFS= read -r line; do + files+=("$line") +done <<< "$(find "$@" | grep -v .DS_Store | sort)" rm -rf cfg.zip zip -9 cfg.zip "${files[@]}"