]> git.ipfire.org Git - people/ms/network.git/commitdiff
cli: print the description title
authorJonatan Schlag <jonatan.schlag@ipfire.org>
Mon, 19 Jun 2017 19:20:48 +0000 (21:20 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 22 Jun 2017 14:31:11 +0000 (16:31 +0200)
Signed-off-by: Jonatan Schlag <jonatan.schlag@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/functions/functions.cli

index 5efd923d04c11b8561255ff1a76c79bb7c78a39f..1bd99dd127dc56c7fa1f656f6357cbac2682d10e 100644 (file)
@@ -113,6 +113,17 @@ cli_device_headline() {
        esac
        cli_print_fmt1 1 "Status" "${status}"
 
+       # Print the description title of the device.
+       case "${type}" in
+               port)
+                       cli_print_fmt1 1 "Description" "$(port_get_description_title ${device})"
+                       ;;
+
+               zone)
+                       cli_print_fmt1 1 "Description" "$(zone_get_description_title ${device})"
+                       ;;
+       esac
+
        # Print the color of the device.
        case "${type}" in
                port)