RE: How to handle passing filenames with spaces and wildcards int o bash scripts?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thanks in advance for any hints/help/pointers/tricks that you can provide. 
/Mike

Try using [email protected] in place of $*

For example, consider the script:
echo $#
echo [email protected]

for i in "[email protected]"
do
echo $i
done

######################

say the script was called /tmp/zzzz

run /tmp/zzzz  test1  test2 "test3 test4"
$# should be 3
and the output should be
test1
test2
test3 test4

Hope this helps


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux