{"id":323,"date":"2019-04-07T00:34:46","date_gmt":"2019-04-06T16:34:46","guid":{"rendered":"https:\/\/www.linuxcool.com\/?p=323"},"modified":"2022-05-06T15:46:17","modified_gmt":"2022-05-06T07:46:17","slug":"touch","status":"publish","type":"post","link":"https:\/\/www.linuxcool.com\/touch","title":{"rendered":"touch\u547d\u4ee4 – \u521b\u5efa\u7a7a\u6587\u4ef6\u4e0e\u4fee\u6539\u65f6\u95f4\u6233"},"content":{"rendered":"\n
touch\u547d\u4ee4\u7684\u529f\u80fd\u662f\u7528\u4e8e\u521b\u5efa\u7a7a\u6587\u4ef6\u4e0e\u4fee\u6539\u65f6\u95f4\u6233\u3002\u5982\u679c\u6587\u4ef6\u4e0d\u5b58\u5728\uff0c\u5219\u4f1a\u521b\u5efa\u51fa\u4e00\u4e2a\u7a7a\u5185\u5bb9\u7684\u6587\u672c\u6587\u4ef6\uff1b\u5982\u679c\u6587\u4ef6\u5df2\u7ecf\u5b58\u5728\uff0c\u5219\u4f1a\u5bf9\u6587\u4ef6\u7684Atime\uff08\u8bbf\u95ee\u65f6\u95f4\uff09\u548cCtime\uff08\u4fee\u6539\u65f6\u95f4\uff09\u8fdb\u884c\u4fee\u6539\u64cd\u4f5c\uff0c\u7ba1\u7406\u5458\u53ef\u4ee5\u5b8c\u6210\u6b64\u9879\u5de5\u4f5c\uff0c\u800c\u666e\u901a\u7528\u6237\u53ea\u80fd\u7ba1\u7406\u4e3b\u673a\u7684\u6587\u4ef6\u3002<\/p>\n\n\n\n
\u8bed\u6cd5\u683c\u5f0f\uff1a<\/strong>touch [\u53c2\u6570] \u6587\u4ef6<\/p>\n\n\n\n \u5e38\u7528\u53c2\u6570\uff1a\ufeff<\/strong><\/p>\n\n\n\n \ufeff\u53c2\u8003\u5b9e\u4f8b<\/strong><\/p>\n\n\n\n \u521b\u5efa\u51fa\u4e00\u4e2a\u6307\u5b9a\u540d\u79f0\u7684\u7a7a\u6587\u4ef6\uff1a<\/p>\n\n\n\n \u7ed3\u5408\u901a\u914d\u7b26\uff0c\u521b\u5efa\u51fa\u591a\u4e2a\u6307\u5b9a\u540d\u79f0\u7684\u7a7a\u6587\u4ef6\uff1a<\/p>\n\n\n\n \u4fee\u6539\u6307\u5b9a\u6587\u4ef6\u7684\u67e5\u770b\u65f6\u95f4\u548c\u4fee\u6539\u65f6\u95f4\uff1a<\/p>\n\n\n\n touch\u547d\u4ee4\u7684\u529f\u80fd\u662f\u7528\u4e8e\u521b\u5efa\u7a7a\u6587\u4ef6\u4e0e\u4fee\u6539\u65f6\u95f4\u6233\u3002\u5982\u679c\u6587\u4ef6\u4e0d\u5b58\u5728\uff0c\u5219\u4f1a\u521b\u5efa\u51fa\u4e00\u4e2a\u7a7a\u5185\u5bb9\u7684\u6587\u672c\u6587\u4ef6\uff1b\u5982\u679c\u6587\u4ef6\u5df2\u7ecf […]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/323"}],"collection":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/comments?post=323"}],"version-history":[{"count":18,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/323\/revisions"}],"predecessor-version":[{"id":9288,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/323\/revisions\/9288"}],"wp:attachment":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/media?parent=323"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/categories?post=323"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/tags?post=323"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}-a<\/td> \u6539\u53d8\u6863\u6848\u7684\u8bfb\u53d6\u65f6\u95f4\u8bb0\u5f55<\/td><\/tr> -m <\/td> \u6539\u53d8\u6863\u6848\u7684\u4fee\u6539\u65f6\u95f4\u8bb0\u5f55<\/td><\/tr> -r<\/td> \u4f7f\u7528\u53c2\u8003\u6863\u7684\u65f6\u95f4\u8bb0\u5f55\uff0c\u4e0e --file \u7684\u6548\u679c\u4e00\u6837<\/td><\/tr> -c<\/td> \u4e0d\u521b\u5efa\u65b0\u6587\u4ef6 <\/td><\/tr> -d<\/td> \u8bbe\u5b9a\u65f6\u95f4\u4e0e\u65e5\u671f\uff0c\u53ef\u4ee5\u4f7f\u7528\u5404\u79cd\u4e0d\u540c\u7684\u683c\u5f0f<\/td><\/tr> -t<\/td> \u8bbe\u5b9a\u6863\u6848\u7684\u65f6\u95f4\u8bb0\u5f55\uff0c\u683c\u5f0f\u4e0e date \u547d\u4ee4\u76f8\u540c<\/td><\/tr> --no-create <\/td> \u4e0d\u521b\u5efa\u65b0\u6587\u4ef6<\/td><\/tr> --help<\/td> \u663e\u793a\u5e2e\u52a9\u4fe1\u606f<\/td><\/tr> --version<\/td> \u5217\u51fa\u7248\u672c\u8baf\u606f<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n [root@linuxcool ~]# touch File.txt<\/strong>\r<\/pre>\n\n\n\n
[root@linuxcool ~]# touch File{1..5}.txt<\/strong><\/pre>\n\n\n\n
[root@linuxcool ~]# touch -d \"2022-05-08 15:44\" anaconda-ks.cfg <\/strong>\n[root@linuxcool ~]# stat anaconda-ks.cfg <\/strong>\r\n File: anaconda-ks.cfg\r\n Size: 1256 \tBlocks: 8 IO Block: 4096 regular file\r\nDevice: fd00h\/64768d\tInode: 35319937 Links: 1\r\nAccess: (0600\/-rw-------) Uid: ( 0\/ root) Gid: ( 0\/ root)\r\nContext: system_u:object_r:admin_home_t:s0\r\nAccess: 2022-05-08 15:44:00.000000000 +0800\r\nModify: 2022-05-08 15:44:00.000000000 +0800\r\nChange: 2022-05-06 15:43:47.843170709 +0800\r\n Birth: -\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"