chiark / gitweb /
Move systemctl dot to systemd-analyze dot
[elogind.git] / shell-completion / systemd-zsh-completion.zsh
index a58f4ae0d4c4340dd26ea1d4989df11ce90cb6a0..177a564d3837bb673bdf2308858af7c7f7b23760 100644 (file)
@@ -27,8 +27,6 @@ _ctls()
                 '--no-legend[Do not print a legend, i.e. the column headers and the footer with hints]' \
                 '--no-pager[Do not pipe output into a pager]' \
                 '--no-ask-password[Do not ask for system passwords]' \
-                '--order[When generating graph for dot, show only order]' \
-                '--require[When generating graph for dot, show only requirement]' \
                 '--system[Connect to system manager]' \
                 '--user[Connect to user service manager]' \
                 '--global[Enable/disable unit files globally]' \
@@ -136,6 +134,8 @@ _ctls()
             _arguments \
                 {-h,--help}'[Show help text.]' \
                 '--user[Shows performance data of user sessions instead of the system manager.]' \
+                '--order[When generating graph for dot, show only order]' \
+                '--require[When generating graph for dot, show only requirement]' \
                 '*::systemd-analyze commands:_systemd_analyze_command'
         ;;
         systemd-ask-password)
@@ -293,6 +293,7 @@ _systemd_analyze_command(){
         'time:Print the time taken to start'
         'blame:prints a list of all running units, ordered by the time they took to initialize'
         'plot:prints an SVG graphic detailing which system services have been started at what time'
+        'dot:Dump dependency graph for dot(1)'
     )
 
     if (( CURRENT == 1 )); then
@@ -327,12 +328,15 @@ _outputmodes() {
     "restart:Start or restart one or more units"
     "condrestart:Restart one or more units if active"
     "try-restart:Restart one or more units if active"
-    "reload-or-restart:Reload one or more units is possible, otherwise start or restart"
-    "force-reload:Reload one or more units is possible, otherwise restart if active"
-    "reload-or-try-restart:Reload one or more units is possible, otherwise restart if active"
+    "reload-or-restart:Reload one or more units if possible, otherwise start or restart"
+    "force-reload:Reload one or more units if possible, otherwise restart if active"
+    "hibernate:Hibernate the system"
+    "hybrid-sleep:Hibernate and suspend the system"
+    "reload-or-try-restart:Reload one or more units if possible, otherwise restart if active"
     "isolate:Start one unit and stop all others"
     "kill:Send signal to processes of a unit"
     "is-active:Check whether units are active"
+    "is-failed:Check whether units are failed"
     "status:Show runtime status of one or more units"
     "show:Show properties of one or more units/jobs or the manager"
     "reset-failed:Reset failed state for all, one, or more units"
@@ -349,7 +353,6 @@ _outputmodes() {
     "list-jobs:List jobs"
     "cancel:Cancel all, one, or more jobs"
     "dump:Dump server status"
-    "dot:Dump dependency graph for dot(1)"
     "snapshot:Create a snapshot"
     "delete:Remove one or more snapshots"
     "show-environment:Dump environment"
@@ -455,7 +458,7 @@ _systemctl_disabled_units(){_sys_disabled_units=($(__systemctl list-unit-files
 _systemctl_masked_units()  {_sys_masked_units=(  $(__systemctl list-unit-files     | { while read a b; do [[ $b == "masked" ]] && echo "$a"; done; }) )}
 
 # Completion functions for ALL_UNITS
-for fun in is-active is-enabled status show mask preset ; do
+for fun in is-active is-failed is-enabled status show mask preset ; do
   (( $+functions[_systemctl_$fun] )) || _systemctl_$fun()
   {
     _systemctl_really_all_units
@@ -572,7 +575,7 @@ done
 (( $+functions[_systemctl_link] )) || _systemctl_link() { _files }
 
 # no systemctl completion for:
-#    [STANDALONE]='daemon-reexec daemon-reload default dot dump
+#    [STANDALONE]='daemon-reexec daemon-reload default dump
 #                  emergency exit halt kexec list-jobs list-units
 #                  list-unit-files poweroff reboot rescue show-environment'
 #         [NAME]='snapshot load'