Showing posts from April, 2018

Highlight outputs in karaf gogo shell

The command shell:highlight in mhus-osgi-tools 1.3.5 will provide a command to search and highlight text via pipe: The basic usage are: service:list | highlight bundle The command accept regex expressions and by default the regex is case insensitive, the result is: [org.osgi.service.url.URLStreamHandlerService] ----------------------------------------------  service. bundle id = 51 = 31  service.scope = singleton  url.handler.protocol = [wrap] Provided by :   OPS4J Pax Url - wrap: (51) Used by:   Apache Karaf :: Deployer :: Wrap Non OSGi Jar (28)  System Bundle (0) More complex is the the option to search multiple words and change the color for each finding: service:list | highlight \#blue bundle \#green service The result: [org.osgi. service .url.URLStreamHandler Service ] ----------------------------------------------   service . bundle id = 51   service .id = 31   service .scope = singleton  url.handler