how to move a file in a directory code example Example 1: how to move file in directory in linux mv file dir Example 2: how to move file from one directory to another in linux mv file1 /tmp