ytti / oxidized-script

CLI and LIB for scripting network devices via Oxidized
45 stars 26 forks source link

oxs name of the command #19

Open petoma opened 7 years ago

petoma commented 7 years ago

Hi, is it possible to print a command itself in the output of the commands I asked oxs to pull from the device out? When I asks for lets say "show arp" it gives me this:

pi@raspberrypi:~/.config/oxidized$ oxs -x cmds device Protocol Address Age (min) Hardware Addr Type Interface Internet 192.168.1.1 - 001a.2f65.052b ARPA Vlan10 Internet 192.168.1.14 0 5cf9.3857.2fab ARPA Vlan10 Internet 192.168.1.17 3 848e.dfa1.1c72 ARPA Vlan10 Internet 192.168.1.18 153 84b5.4146.685c ARPA Vlan10

but I would love to have it like this for better view on the output:

pi@raspberrypi:~/.config/oxidized$ oxs -x cmds device Router#show arp Protocol Address Age (min) Hardware Addr Type Interface Internet 192.168.1.1 - 001a.2f65.052b ARPA Vlan10 Internet 192.168.1.14 0 5cf9.3857.2fab ARPA Vlan10 Internet 192.168.1.17 3 848e.dfa1.1c72 ARPA Vlan10 Internet 192.168.1.18 153 84b5.4146.685c ARPA Vlan10

So my question is, is the output customizable?

Thank you

ytti commented 7 years ago

It honors the model, and if model modifies the output, then the output is modified. It wouldn't be hard to add toggle for it. But I'm not planning to work on in in any specific timeframe.