在Ubuntu Linux中获取上次访问的文件时间

Ubuntu Linux has a rich set of commands for manipulating and accessing files. The stat utility gives detailed access to file information, including last accessed and last modified file time.

Ubuntu Linux具有一组丰富的用于操作和访问文件的命令。 stat实用程序可提供对文件信息的详细访问,包括上次访问和上次修改的文件时间。

From the terminal window, run the command with this syntax:

在终端窗口中,使用以下语法运行命令:

stat filename

统计文件名

Here’s an example of checking the last time I’ve run Firefox on one of my machines:

这是检查我上次在其中一台计算机上运行Firefox的示例:

[geek@ubuntu firefox]# stat firefox-bin
  File: `firefox-bin'
  Size: 9781136         Blocks: 19136      IO Block: 4096   Regular File
Device: 302h/770d       Inode: 555615      Links: 1    
Access: (0755/-rwxr-xr-x)  Uid: (  500/  geek)   Gid: (  500/  geek)
Access: 2006-01-14 17:41:15.000000000 -0500
Modify: 2005-05-11 14:17:00.000000000 -0400
Change: 2005-05-13 23:31:44.000000000 -0400
[geek@ubuntu firefox]# stat firefox-bin
  File: `firefox-bin'
  Size: 9781136         Blocks: 19136      IO Block: 4096   Regular File
Device: 302h/770d       Inode: 555615      Links: 1    
Access: (0755/-rwxr-xr-x)  Uid: (  500/  geek)   Gid: (  500/  geek)
Access: 2006-01-14 17:41:15.000000000 -0500
Modify: 2005-05-11 14:17:00.000000000 -0400
Change: 2005-05-13 23:31:44.000000000 -0400

I guess I haven’t used that box in a while… last time I used firefox was january 14th.

我想我已经有一段时间没用那个盒子了……上一次我使用Firefox是1月14日。

翻译自: https://www.howtogeek.com/howto/ubuntu/get-last-accessed-file-time-in-ubuntu-linux/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值