bash: array - Copy an array.



  • Take into account the main readme for this section. README first.

    An array called planet.

    $ declare -a planet=(earth wind fire)
    

    Copy array planet to array environment.

    $ environment=("${planet[@]}")
    $ echo "${environment[@]}"
    earth wind fire
    

Log in to reply
 

© Lightnetics 2024