I do this in BASH
echo test "$1" ..expecting to get..
test test ..but I get..
test Is this something possible to do? It would make my life easier since having a list files I could do something like mv a/b/test.py proj_copy/$1
You can use history expansion
$ echo test !#:^ echo test test test test $ echo a/b/test.py proj_copy/!#:^ echo a/b/test.py proj_copy/a/b/test.py a/b/test.py proj_copy/a/b/test.py !#
The entire command line typed so far.:^
The first argument
You could also use brace expansion
$echo test{,} test test $echo {,proj_copy}/a/b/test.py /a/b/test.py proj_copy/a/b/test.py
echo test{,}?