移动文件的操作(mmove命令 – 移动文件或目录)
Linux mmove命令用于在MS-DOS文件系统中 ,移动文件或目录 ,或更改名称 。
mmove为mtools工具命令 ,模拟MS-DOS的move命令 ,可在MS-DOS文件系统中移动现有的文件或目录 ,或是更改现有文件或目录的名称 。
语法格式: mmove [源文件或目录] [目标文件或目录]
常用参数:
源文件或目录 执行操作的源文件或目录路径 目标文件或目录 执行操作后的目标文件或目录路径参考实例
使用指令mmove将文件a.txt移动到目录dir中:
[root@linuxcool ~]# mmove a.txt dir使用指令mmove将文件 ”autorun.bat ”移动到目录 ”test ”中 :
[root@linuxcool ~]# mmove autorun.bat test以上命令执行以后 ,指令mmove会将文件 ”autorun.bat ”移动到指定目录 ”test ”中 。
使用指令mmove将文件test移动到目录 ”autorun.bat ”中 :
[root@linuxcool ~]# mmove test autorun.bat注意:用户可以使用mdir指令查看移动后的文件或目录信息 。
使用该命令前先查看原来的目录 ,得到如下结果:
[root@linuxcool ~]# mdir-/a:\* VolumeindriveAhasnolabel#加载信息 VolumeSerialNumberis13D2~055C DirectoryforA:/#以下为目录信息 #文件名目录大小修改时间 ./TEST<DIR>2009-09-2316:59 AUTORUN.INF2652009-09-2316:53 AUTORUN.BAT432009-09-2316:56 3files308bytes#统计总大小 724325bytesfree#剩余空间使用mmove命令 ,并再次查看 ,结果如下:
[root@linuxcool ~]# mmove autorun.bat test [root@linuxcool ~]# mdir-/a:\* VolumeindriveAhasnolabel#加载信息 VolumeSerialNumberis13D2~055C DirectoryforA:/#以下为目录信息 #文件名目录大小修改时间 ./TEST<DIR>2009-09-2316:59 AUTORUN.INF2652009-09-2316:53 2files265bytes#统计总大小 724683bytesfree#剩余空间 cmd@cmd-desktop:~$mdir-/a:\test\*#再次查看test目录中文件 AUTORUN.BAT432009-09-2316:56 1files43bytes#统计总大小创心域SEO版权声明:以上内容作者已申请原创保护,未经允许不得转载,侵权必究!授权事宜、对本内容有异议或投诉,敬请联系网站管理员,我们将尽快回复您,谢谢合作!