Search code examples
unixmv

Unix mv command: Incorrectly type '.:' instead of target folder


While moving folders using the mv command (Unix) I incorrectly specified the target folder of the copy with .: instead of the path I wanted.

meaning instead of:

mv ./folder/to/move/ ./target/folder/

I typed:

mv ./folder/to/move/ .:

The command moved the folder somewhere. How can I find this location?


Solution

  • The command created a folder named .: in the current folder. As the name starts with a . it's invisible with a simple ls check. A cd .: move you to it.

    (Note: I used find to look for the folder and found a match with a folder name .:.)