批处理命令教学之more命令

2019-09-19 06:40:28刘景俊

1.txt
逐屏显示输出。


MORE [/E [/C] [/P] [/S] [/Tn] [+n]] < [drive:][path]filename
command-name | MORE [/E [/C] [/P] [/S] [/Tn] [+n]]
MORE /E [/C] [/P] [/S] [/Tn] [+n] [files]

代码:


more /s +2 1.txt

效果:


[color=Red]空行。[/color]
MORE    [/E [/C] [/P] [/S] [/Tn] [+n]] < [drive:][path]filename
command-name | MORE [/E [/C] [/P] [/S] [/Tn] [+n]]
MORE /E [/C] [/P] [/S] [/Tn] [+n] [files]

显示了1行空行,说明+2先于/s参数运行,因为如果/s参数先运行再跳过2行,那么结果就不会有空行。

8.逐屏显示多个文件。

1.txt


hello

2.txt


world

代码:


more 1.txt 2.txt

效果:


hello
world

9.在显示未完成时(完成度百分比小于100%)的操作命令—— 一般用于命令提示符中


 P n 显示下 n 行(先输入p,然后输入0-9的数字)
    S n 跳过下 n 行(同p,但不是显示而是跳过)
    F 显示下个文件(用于more命令显示多个文件的情况)
    Q 退出
    = 显示当前显示最后一行的行号
    ? 显示帮助
 空格键  显示下一页
回车键  显示下一行

以上所述就是本文的全部内容了,希望大家能够喜欢。

相关文章 大家在看