Is there a way to customize ubuntu terminal in such a way that output of the any command is colorized according to some patterns. In .bashrc I can customize prompt, but I am looking for something similar to what MobaXTerm does on windows: when I cat file and there is some specific word, like false, error or failure it is colored red. Words: success, true are colored green. It really helps reading logs, configurations etc. Is there a way to achieve this in terminal?
You could use colorizer tools, see e.g. https://superuser.com/q/602294.
I'm not aware of any terminal emulator for Linux that offers such coloring (syntax highlighting) on its own. If there exists one, someone will sure correct me.
There's a proof of concept patch for VTE with hardwired words, you can modify them or add new ones by changing the source. VTE is used by several terminal emulators, including e.g. GNOME Terminal, Tilix or Xfce Terminal; thus if you patch, compile and install VTE, you can use this feature in any of these.