Windows equivalent of the 'tail' command

前端 未结 21 2970
长情又很酷
长情又很酷 2020-11-28 01:48

Is there a way to simulate the *nix tail command on the Windows command line? I have a file and I want a way to snip off the first n lines of text. For example:

21条回答
  •  难免孤独
    2020-11-28 02:40

    Here is a fast native head command that gives you the first 9 lines in DOS.

    findstr /n "." myfile.txt | findstr "^.:"
    

    The first 2 characters on each line will be the line number.

提交回复
热议问题