Khurram Khan
2013-03-06 08:24:49 UTC
Hello All,
I've got a device that I'm building a custom command table for and trying
to grep out a ssh key that I don't want displayed in the configuration.
When running the command from cli on the device, the syntax looks like:
show configuration | grep -v "ssh "
and the cli command does what it's supposed to.
How do I incorporate the start/end quotes in the command table? I've tried
a couple of variations and the script errors out.
@commandtable = (
{'no timestamps' => 'DoNothing' },
{'show configuration | grep -v "ssh "' => 'WriteTerm' },
);
Thanks in advance!
I've got a device that I'm building a custom command table for and trying
to grep out a ssh key that I don't want displayed in the configuration.
When running the command from cli on the device, the syntax looks like:
show configuration | grep -v "ssh "
and the cli command does what it's supposed to.
How do I incorporate the start/end quotes in the command table? I've tried
a couple of variations and the script errors out.
@commandtable = (
{'no timestamps' => 'DoNothing' },
{'show configuration | grep -v "ssh "' => 'WriteTerm' },
);
Thanks in advance!