I'm trying to add elements to a bash array, and I cannot figure out why they are not added:
$ cat /tmp/tmp.bash
#!/bin/bash
declare -a base=(
"python"
"python-setuptools"
)
packages=( "${base[*]}" "tools" "oracle" )
echo "$packages"
$ /tmp/tmp.bash
python python-setuptools
$
In the output, we only see the base array elements, but not the two I added.
Any idea what am I doing wrong?