Closed github-actions[bot] closed 1 year ago
Der skal være "double quotes" omkring variablerne:
cd samples/animals
for id in "${ANIMALS[@]}"
do
echo $id >> "$id.txt"
done
cd countries
for id in "${COUNTRIES[@]}"
do
echo $id >> "$id.txt"
done
cd movies
for id in "${MOVIES[@]}"
do
echo $id >> "$id.txt"
done
Apparently the script itself i broken. It doesn't handle whitespaces that well.
We had expected a file called
Sex And The City.txt
but instead we gotSex.txt
,And.txt
,The.txt
andCity.txt
. Same withElephant babies
Fix that in the script.
Hint: you need to use quotes
"
here and there to make it work