Syntax highlighting/colorizing cat

前端 未结 18 1915
不思量自难忘°
不思量自难忘° 2020-12-02 03:39

Is there a method to colorize the output of cat, the way grep does.

For grep, in most consoles it displays a colored output hi

18条回答
  •  旧巷少年郎
    2020-12-02 04:22

    vimcat is single-file (shell script) and works good:

    http://www.vim.org/scripts/script.php?script_id=4325

    Last update is from December 2013. Hint: you can force file type recognition by vimcat -c "set ft=".

提交回复
热议问题