cmd move file code example

Example 1: cmd move file to folder

move filename directoryname

Example 2: move into folder cmd

The cd command can be used to change into a subdirectory,

cd subdirectory_name						-> To go one level into subdir
cd subdirectory_name/subsubdirectory_name	-> To go two levels into subdir

move back into the parent directory,

cd ..\       -> To go back one level
cd ..\..\    -> To go back two levels

move to previos directory,

cd -

move all the way back to the root directory or move to any
given directory

cd C:/Give_Path_to_directory

Example 3: how to move file in the command line

% mv ~/Downloads/MyFile.txt ~/Documents/Work/MyFile.txt

Example 4: move files command line windows

move "%USERPROFILE%\Downloads\Test.exe" "%USERPROFILE%\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup"

Example 5: move files command line windows

move "full_path" "new_full_Path"

Example 6: command line move file

mv file.txt ~/Desktop/Folder

Tags:

Misc Example