> ls -alt # 按修改时间排序
> ls --sort=time -la # 等价于> ls -alt
> ls -alc # 按创建时间排序
> ls -alu # 按访问时间排序 # 以上均可使用-r实现逆序排序
> ls -alrt # 按修改时间排序
> ls --sort=time -lra # 等价于> ls -alrt
> ls -alrc # 按创建时间排序
> ls -alru # 按访问时间排序

实例:按文件生成时间倒序排列

[root@ log]# ls -alt
总用量
drwxr-x---. root root 10月 : ..
drwxr-x---. root root 10月 : .
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt
-rw-r----- root root 10月 : result-.txt

参考文档:LINUX的文件按时间排序

【linux】的文件按时间排序的更多相关文章

  1. LINUX的文件按时间排序

    转载 2014年12月29日 00:49:23 20298 > ls -alt # 按修改时间排序 > ls --sort=time -la # 等价于> ls -alt > ...

  2. linux_常用命令_(ls, lsof,nslookup)_查看文件按照时间排序

    平时收集些用到的命令 方便使用 1:  ls -lrt 按时间排序  展示 2:nslookup  查看dns解析 3:lsof -p 进程号 lsof `which httpd` //那个进程在使用 ...

  3. linux中文件的时间属性atime/mtime/ctime

    文件的时间属性的概念 上图第7-9是时间,默认是ctime(文件修改时间),有三种时间属性: modify time        mtime       (文件内容被修改的时间) change ti ...

  4. linux 修改文件的时间属性

    二.修改文件时间 创建文件我们可以通过touch来创建.同样,我们也可以使用touch来修改文件时间.touch的相关参数如下: -a : 仅修改access time. -c : 仅修改时间,而不建 ...

  5. linux查看文件具体时间和大小

    查看具体时间 ll --full-time 查看文件大小: ll -ht 或者du -sh *

  6. Linux中ls对文件进行按大小排序和按时间排序,设置ls时间格式

    1 按文件大小排序 使用 ll -S | grep '^[^d]' // 格式化文件大小形式 ll -Sh | grep '^[^d]' 2 按文件修改时间排序显示 使用 ll -rt 3 设置ls ...

  7. 目录和文件 按创建时间排序du -h --time --max-depth=1 . |sort -r -t $'\t' -k 2 Linux查看文件夹大小,并按文件夹创建时间排序

    目录和文件 按创建时间排序 # du -h --time --max-depth=1 . |sort -r -t $'\t' -k 230M 2020-04-01 14:54 .28K 2020-04 ...

  8. 如何对sharepoint图片库的文件夹的图片按照时间排序并分页显示

    /// <summary> /// 获取图片库第一层文件夹--根据文件夹名称排序 /// </summary> /// <param name="siteUrl ...

  9. Linux的文件时间

    在windows下,一个文件有:创建时间.修改时间.访问时间.而在Linux下,一个文件也有三种时间,分别是:访问时间.修改时间.状态改动时间. 1.访问时间,读一次这个文件的内容,这个时间就会更新. ...

随机推荐

  1. 使用elasticdump导入导出数据

    一.安装elasticdump 终端中输入 npm install elasticdump -g -g表示全局可用,直接在终端输入 elasticdump --version,出现版本信息即表示安装成 ...

  2. 关于Vue父子组件传值(复杂数据类型的值)的细节点

    vue 父子组件传值是很常见的,多数情况下都是父传递给子的值是基础数据类型,如string,number,boolean, 当父组件值被修改时,子组件能够实时的作出改变. 如果父子传值的类型是复杂数据 ...

  3. div悬浮在屏幕的中间及点击按钮关闭弹出框

    #fd { position: fixed; z-index: 999; width: 109px; height: 323px; top: 71%; right: 1%; margin: -50px ...

  4. UIWebView与JS的交互

    IOS-的UIWebView UIWebVew是ios开发中较为常用的一个控件.其可以打开网页,加载html,打开文档等.当我们在开发中需要用到一些显示页面时,UIWebView是一个很好的选择. 创 ...

  5. Error:Unexpected lock protocol found in lock file. Expected 3, found 49.

    关于这个错误,今天研究了两三个小时的时间,查看网上的教程都解决不了问题,后来发现是自己的文件目录导入的有问题. 现在把自己关于解决这个问题的详细步骤说明一下. (1)首先,你先查看一下自己导入文件的目 ...

  6. Windows Server IIS设置计划任务重启

    Windows Server ,IIS设置计划任务重启. echo ----->>c:\log_iisreset.txt &&  echo %date% %time% &g ...

  7. Linux系统,无法收到组播消息的问题

    解决办法: 做以下3个修改 1. /etc/sysctl.conf 文件中的 net.ipv4.conf.all.rp_filter 设置成0 2. sysctl -w net.ipv4.conf.a ...

  8. 指数家族-Beta分布

    2. Beta分布 2.1 Beta分布 我们将由几个问题来得引出几个分布: 问题一:1:  2:把这个  个随机变量排序后得到顺序统计量  3:问  是什么分布 首先我们尝试计算  落在一个区间   ...

  9. Python----webserver项目2

    # 编码问题 - 为什么需要编码问题 - 本质上计算机只能识别01代码 - 如何用一长串01代码表示复杂的信息 - encode:编码  decode:解码 - 编码简史 - 二进制 - bit: 一 ...

  10. Raspberry Pi3驱动Oled ssh1106屏

    Raspberry Pi3可以直接使用GPIO接口驱动OLED屏 一.接线 根据网上随便找的图可以看到树莓派3的GPIO接口引脚顺序 PS:26pin的GPIO为前26针 根据OLED屏的引脚说明,如 ...