论坛: UNIX系统 标题: find后-exec多命令问题[已解决] 复制本贴地址    
作者: TecZm [teczm]    版主   登录
目的:找到某目录下test文件后修改日期为2005年01月01日01时01秒,然后将其拷贝到/teczm下:

现在能做到:
%find . -type f -name "test" -exec touch -t 0501010101 {} \;
但不能一步完成目的操作。

how to?



[此贴被 TecZm(teczm) 在 05月21日14时39分 编辑过]


[此贴被 TecZm(teczm) 在 05月23日08时23分 编辑过]

地主 发表时间: 05-05-21 14:38

回复: TecZm [teczm]   版主   登录
CU icesummit回答
引用:

%find . -type f -name "test" -exec touch -t 0501010101 {} \; -exec cp {} /teczm \;



B1层 发表时间: 05-05-23 08:23

论坛: UNIX系统

20CN网络安全小组版权所有
Copyright © 2000-2010 20CN Security Group. All Rights Reserved.
论坛程序编写:NetDemon

粤ICP备05087286号