Is there any easy way to “join” the arguments passed to a script? I’d like something similar to $@, but that passes the arguments at once.
For example, consider the following script:
$/bin/bash
./my_program $@
When called as
./script arg1 arg2 arg3
my_program will receive the arguments as 3 separated arguments. What I want, is to pass all the arguments as one argument, joining them — separated by spaces, something like calling:
./my_program arg1\ arg2\ arg3
Use this one: