Thanks for your reply. I tried using regular string but it seems it doesn’t work as i expected.
Device(config)# system notes "Location: San Jose\nContact: John Smith\n"
Device(config)# do show running-config system notes
system notes "Location: San Jose\nContact: John Smith\n"
What i expect is
Device(config)# system notes "Location: San Jose
Contact: John Smith"
Device(config)# do show running-config system notes
system notes "Location: San Jose
Contact: John Smith"
leaf notes {
type string {
length "0..4000";
}
tailf:info "
Custom free form notes providing device information";
}
Can you explain more with an example on what you mentioned about addressing “special” format
I confused some things when answering originally, sorry for that…
You could try CLI annotations for the target leaf to achieve similar/almost same behavior:
I tested by editing/adding leaf to confd’s example.confd/intro/1-2-3... example
YANG model:
leaf long {
tailf:cli-multi-line-prompt;
tailf:cli-preformatted;
type string;
}
These are described in e.g. bash man tailf_yang_cli_extensions (man pages) output…
And CLI session example:
DEV(config)# dhcp long
(<string>):
[Multiline mode, exit with ctrl-D.]
> one
> two
>
> two
> two
>
DEV(config)#
DEV(config)#
DEV(config)#
DEV(config)# show full-configuration dhcp long
dhcp long one
two
two
two
DEV(config)#
Hmm, i observe the same, and i didn’t find any usable/helpful annotation that could allow copy&pasting the config in multi-line mode (not sure if/how the “^D” can be applied)…
Maybe someone else has experience with multi-line solutions and can chime in?