Search code examples
linuxterminalcolorssyntaxcat

How to make cat command to view file content with syntax highlights in terminal


In the following screenshot, on executing the cat command it display the horizontal line then file info with name and then file content.

Is this feature from cat or any external lib?

I have found one python lib Pygments

Could some geek tell me how to achieve this? enter image description here


Solution

  • After an hour of search on google, I found that eventually.

    It is not a cat command. It is bat that is making all the things pretty.