]> git.ipfire.org Git - people/stevee/network.git/blobdiff - src/functions/functions.dhcpd
bash-completion: Add some basic completion for DHCP servers
[people/stevee/network.git] / src / functions / functions.dhcpd
index 51272e907a7564254d2963514740a53a075bd7f8..f6732db33f5e0539323ede03b6d18005509b2be8 100644 (file)
@@ -332,6 +332,13 @@ function dhcpd_options() {
        return ${EXIT_OK}
 }
 
+function dhcpd_global_settings_list() {
+       local proto="${1}"
+       assert isset proto
+
+       dhcpd_settings "${proto}"
+}
+
 function dhcpd_global_settings_defaults() {
        local proto=${1}
        assert isset proto
@@ -842,21 +849,7 @@ function dhcpd_subnet_options_file() {
 
 function dhcpd_subnet_options_list() {
        local proto=${1}
-
-       case "${proto}" in
-               ipv6)
-                       print "DHCPV6D_SUBNET_OPTIONS"
-                       ;;
-               ipv4)
-                       print "DHCPV4D_SUBNET_OPTIONS"
-                       ;;
-       esac
-
-       return ${EXIT_OK}
-}
-
-function dhcpd_subnet_options() {
-       local proto=${1}
+       assert isset proto
 
        case "${proto}" in
                ipv6)
@@ -931,7 +924,7 @@ function _dhcpd_read_options() {
        local options_list=${2}
        assert isset options_list
 
-       setttings_read_array ${file} options ${!options_list}
+       settings_read_array ${file} options ${!options_list}
 }
 
 function _dhcpd_write_subnet() {