查看文件的时间:
stat test.txt
更新目录下面所有文件的时间:
find ./* -type f -exec touch {} \;
更新目录下面所有目录的时间:
find ./* -type d -exec touch {} \;
修改一个文件的日期时间:
touch -d "2020-11-11 11:00:00" test.txt
批量修改:
find ./* -exec touch -t 202011111100.00 {} \;
查看文件的时间:
stat test.txt
更新目录下面所有文件的时间:
find ./* -type f -exec touch {} \;
更新目录下面所有目录的时间:
find ./* -type d -exec touch {} \;
修改一个文件的日期时间:
touch -d "2020-11-11 11:00:00" test.txt
批量修改:
find ./* -exec touch -t 202011111100.00 {} \;