From 07240336bc45246d225027933c275042180e120e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20Garc=C3=ADa=20Crespo?= Date: Wed, 8 May 2024 05:04:16 +0000 Subject: [PATCH] Update transfer.sh to accept number of files --- hack/ccp/hack/transfer.sh | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/hack/ccp/hack/transfer.sh b/hack/ccp/hack/transfer.sh index 39a777305..cf70b5f07 100755 --- a/hack/ccp/hack/transfer.sh +++ b/hack/ccp/hack/transfer.sh @@ -5,7 +5,18 @@ set -x __dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" transfer=$(mktemp -d) + cp $__dir/processingMCP.xml $transfer -touch $transfer/hello.txt -touch $transfer/bye.txt + +num_files=$1 +if [[ ! "$num_files" =~ ^[0-9]+$ ]]; then + touch "$transfer/hello.txt" + touch "$transfer/bye.txt" +else + for (( i=0; i