chiark / gitweb /
hostnamed: introduce new "embedded" chassis type
authorLennart Poettering <lennart@poettering.net>
Thu, 6 Nov 2014 13:37:12 +0000 (14:37 +0100)
committerLennart Poettering <lennart@poettering.net>
Thu, 6 Nov 2014 13:37:12 +0000 (14:37 +0100)
We really don't want to get lost in adding fridge, car, plane, drone, or
whatever else, hence add a generic term "embedded" cover all the cases
where the computer is just part of something bigger, and not at the
focus of things.

man/hostnamectl.xml
shell-completion/bash/hostnamectl
shell-completion/zsh/_hostnamectl
src/hostname/hostnamed.c

index 128d92f57623f8055576e85de3b9737cab68c5f3..ffae5e6b060684857622775f4c4f450e0afe3edc 100644 (file)
                                 <literal>server</literal>,
                                 <literal>tablet</literal>,
                                 <literal>handset</literal>,
-                                <literal>watch</literal>, as well as
+                                <literal>watch</literal>,
+                                <literal>embedded</literal> as well as
                                 the special chassis types
                                 <literal>vm</literal> and
                                 <literal>container</literal> for
index a5e34600c806a07b42fe573e2e6bd7e4343998f0..7a0850dbe44c67c7faa6121cf2e005401b2a737f 100644 (file)
@@ -52,7 +52,7 @@ _hostnamectl() {
         if [[ -z $verb ]]; then
                 comps=${VERBS[*]}
         elif __contains_word "$verb" ${VERBS[CHASSIS]}; then
-                comps='desktop laptop server tablet handset watch vm container'
+                comps='desktop laptop server tablet handset watch embedded vm container'
         elif __contains_word "$verb" ${VERBS[STANDALONE]} ${VERBS[ICONS]} ${VERBS[NAME]}; then
                 comps=''
         fi
index e02f6de30edb9512041123de41ea2eb7685b029c..a7217a1999e14a28860dec1b79c5be6d2da3945f 100644 (file)
@@ -18,7 +18,7 @@ _hostnamectl_set-icon-name() {
 
 _hostnamectl_set-chassis() {
     if (( CURRENT <= 3 )); then
-        _chassis=( desktop laptop server tablet handset watch vm container )
+        _chassis=( desktop laptop server tablet handset watch embedded vm container )
         _describe chassis _chassis
     else
         _message "no more options"
index a449610bb86c2593c3d0408ebab2dc82990b2293..0123922c4a2f185583e42ae3f1b8939914e1f136 100644 (file)
@@ -138,7 +138,8 @@ static bool valid_chassis(const char *chassis) {
                         "server\0"
                         "tablet\0"
                         "handset\0"
-                        "watch\0",
+                        "watch\0"
+                        "embedded\0",
                         chassis);
 }