Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Eetrey

macrumors newbie
Original poster
Apr 20, 2010
5
0
For the life of me I cannot move a file in a terminal. I have seen every example online and when I try my own version I get this response:

usage: mv [-f | -i | -n] [-v] source target
mv [-f | -i | -n] [-v] source ... directory

I have tried "man mv" but the manual was not much help can anyone give me some suggestions. I want to be able to manipulate my files using a terminal. Thanks in advance.
 
sure this is what i gather should work:


mv missed notes 1.pdf /Users/edenpreciado/documents/cee163/missed notes 1.pdf
 
You have to escape the spaces. And Documents needs to be capitalized, the paths are case sensitive.

So that would actually be:

Code:
mv missed\ notes\ 1.pdf /Users/edenpreciado/Documents/cee163/missed\ notes\ 1.pdf

Also, to make things easier, take advantage of tab completion. For example assuming missed notes was the only file in the current directory that began with mis, typing

Code:
mv mis

And and then typing tab, terminal would autocomplete the path for you. You could then do this throughout the target path as well.

So, /U tab, e tab, Doc tab, etc.
 
nicely done kind sir. Seriously though, thank you very much. I want to become somewhat familiar with the terminal and this really helps.
 
i have an error when trying to move a file and i want you guys to kindly assist in solving it.
this is what i get
usage: mv [-f | -i | -n] [-v] source target

mv [-f | -i | -n] [-v] source ... directory
this is the command i typed in

sudo mv composer.phar /usr/local/bin folder/composer

 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.