Moving file which it's name contain spaces by command line???
I tried to move file which it's name is "Untitled Theme.emerald"
using this command Code:
mv Untitled Theme.emerald /home/all/Documents Code:
mv: cannot stat `Untitled': No such file or directory How to fix this problem specially if i want to but command like this in a script? |
You can either use \ to escape spaces, or put the filename in double quotes. Both of the following should work:
Code:
mv Untitled\ Theme.emerald /home/all/Documents |
thnk u
but what if the file name is variable or not known? Code:
mv $a /home/all |
You can put it in double quotes:
Code:
mv "$a" /home/all |
Quote:
Code:
mkdir multi result is this error message Code:
mv: cannot stat `bn.png\n586689854.jpg\nnew file home tall.jpg\nThe.Curious.Case.of.Benjamin.Button.DVDSCR.XviD-DEViSE.jpg\nmm.gif': No such file or directory can any body find what is the cause of this error?? |
Code:
for files in *.png *.jpg *.gif |
Quote:
Thank u and thank u all guys... |
All times are GMT -5. The time now is 12:23 PM. |