diff options
Diffstat (limited to 'shell-completion')
-rw-r--r-- | shell-completion/bash/hostnamectl | 2 | ||||
-rw-r--r-- | shell-completion/bash/journalctl | 2 | ||||
-rw-r--r-- | shell-completion/bash/systemctl.in | 12 | ||||
-rw-r--r-- | shell-completion/bash/systemd-run | 5 | ||||
-rw-r--r-- | shell-completion/zsh/_journalctl | 1 | ||||
-rw-r--r-- | shell-completion/zsh/_sd_unit_files | 2 | ||||
-rw-r--r-- | shell-completion/zsh/_systemctl.in | 11 | ||||
-rw-r--r-- | shell-completion/zsh/_systemd-run | 16 |
8 files changed, 27 insertions, 24 deletions
diff --git a/shell-completion/bash/hostnamectl b/shell-completion/bash/hostnamectl index 9ad52e03b4..6a252188ea 100644 --- a/shell-completion/bash/hostnamectl +++ b/shell-completion/bash/hostnamectl @@ -38,7 +38,7 @@ _hostnamectl() { local -A VERBS=( [STANDALONE]='status' [ICONS]='set-icon-name' - [NAME]='set-hostname set-deployment' + [NAME]='set-hostname set-deployment set-location' [CHASSIS]='set-chassis' ) diff --git a/shell-completion/bash/journalctl b/shell-completion/bash/journalctl index 056cdbce70..4a7e0da1ab 100644 --- a/shell-completion/bash/journalctl +++ b/shell-completion/bash/journalctl @@ -51,7 +51,7 @@ _journalctl() { [ARG]='-b --boot --this-boot -D --directory --file -F --field -o --output -u --unit --user-unit -p --priority --vacuum-size --vacuum-time' - [ARGUNKNOWN]='-c --cursor --interval -n --lines --since --until + [ARGUNKNOWN]='-c --cursor --interval -n --lines -S --since -U --until --after-cursor --verify-key -t --identifier --root -M --machine' ) diff --git a/shell-completion/bash/systemctl.in b/shell-completion/bash/systemctl.in index 29bb41c436..d80d8f02a8 100644 --- a/shell-completion/bash/systemctl.in +++ b/shell-completion/bash/systemctl.in @@ -106,6 +106,8 @@ _systemctl () { if __contains_word "--user" ${COMP_WORDS[*]}; then mode=--user + elif __contains_word "--global" ${COMP_WORDS[*]}; then + mode=--user else mode=--system fi @@ -159,7 +161,7 @@ _systemctl () { fi local -A VERBS=( - [ALL_UNITS]='is-active is-failed is-enabled status show cat mask preset help list-dependencies edit' + [ALL_UNITS]='is-active is-failed is-enabled status show cat mask preset help list-dependencies edit set-property' [ENABLED_UNITS]='disable' [DISABLED_UNITS]='enable' [REENABLABLE_UNITS]='reenable' @@ -172,14 +174,12 @@ _systemctl () { [TARGET_AND_UNITS]='add-wants add-requires' [MASKED_UNITS]='unmask' [JOBS]='cancel' - [SNAPSHOTS]='delete' [ENVS]='set-environment unset-environment' [STANDALONE]='daemon-reexec daemon-reload default emergency exit halt hibernate hybrid-sleep kexec list-jobs list-sockets list-timers list-units list-unit-files poweroff reboot rescue show-environment suspend get-default is-system-running' - [NAME]='snapshot' [FILE]='link switch-root' [TARGETS]='set-default' ) @@ -257,16 +257,12 @@ _systemctl () { fi compopt -o filenames - elif __contains_word "$verb" ${VERBS[STANDALONE]} ${VERBS[NAME]}; then + elif __contains_word "$verb" ${VERBS[STANDALONE]}; then comps='' elif __contains_word "$verb" ${VERBS[JOBS]}; then comps=$( __systemctl $mode list-jobs | { while read -r a b; do echo " $a"; done; } ) - elif __contains_word "$verb" ${VERBS[SNAPSHOTS]}; then - comps=$( __systemctl $mode list-units --type snapshot --full --all \ - | { while read -r a b; do echo " $a"; done; } ) - elif __contains_word "$verb" ${VERBS[ENVS]}; then comps=$( __systemctl $mode show-environment \ | while read -r line; do echo " ${line%%=*}=";done ) diff --git a/shell-completion/bash/systemd-run b/shell-completion/bash/systemd-run index b1387a28b6..8152b021e7 100644 --- a/shell-completion/bash/systemd-run +++ b/shell-completion/bash/systemd-run @@ -83,7 +83,10 @@ _systemd_run() { LimitMEMLOCK= LimitLOCKS= LimitSIGPENDING= LimitMSGQUEUE= LimitNICE= LimitRTPRIO= LimitRTTIME= PrivateTmp= PrivateDevices= PrivateNetwork= NoNewPrivileges= WorkingDirectory= RootDirectory= - TTYPath= SyslogIdentifier= SyslogLevelPrefix=' + TTYPath= SyslogIdentifier= SyslogLevelPrefix= SyslogLevel= + SyslogFacility= TimerSlackNSec= OOMScoreAdjust= ReadWriteDirectories= + ReadOnlyDirectories= InaccessibleDirectories= EnvironmentFile= + ProtectSystem= ProtectHome= RuntimeDirectory= PassEnvironment=' COMPREPLY=( $(compgen -W '$comps' -- "$cur") ) return 0 diff --git a/shell-completion/zsh/_journalctl b/shell-completion/zsh/_journalctl index 863348e050..b50f0cafc9 100644 --- a/shell-completion/zsh/_journalctl +++ b/shell-completion/zsh/_journalctl @@ -69,6 +69,7 @@ _arguments -s \ {-u+,--unit=}'[Show data only from the specified unit]:units:_journal_fields _SYSTEMD_UNIT' \ '--user-unit=[Show data only from the specified user session unit]:units:_journal_fields USER_UNIT' \ {-p+,--priority=}'[Show only messages within the specified priority range]:priority:_journal_fields PRIORITY' \ + {-t+,--identifier=}'[Show only messages with the specified syslog identifier]:identifier:_journal_fields SYSLOG_IDENTIFIER' \ {-c+,--cursor=}'[Start showing entries from the specified cursor]:cursors:_journal_fields __CURSORS' \ '--after-cursor=[Start showing entries from after the specified cursor]:cursors:_journal_fields __CURSORS' \ '--since=[Start showing entries on or newer than the specified date]:YYYY-MM-DD HH\:MM\:SS' \ diff --git a/shell-completion/zsh/_sd_unit_files b/shell-completion/zsh/_sd_unit_files index 4778a0420d..3e7a4ee803 100644 --- a/shell-completion/zsh/_sd_unit_files +++ b/shell-completion/zsh/_sd_unit_files @@ -5,5 +5,5 @@ _sd_unit_files() { files=( '*:files:->files' ) _description files expl 'unit file' - _files "$expl[@]" -g '*.(automount|busname|device|mount|path|service|snapshot|socket|swap|target|timer)' + _files "$expl[@]" -g '*.(automount|busname|device|mount|path|service|socket|swap|target|timer)' } diff --git a/shell-completion/zsh/_systemctl.in b/shell-completion/zsh/_systemctl.in index 96f51a0ee0..58c88c9d98 100644 --- a/shell-completion/zsh/_systemctl.in +++ b/shell-completion/zsh/_systemctl.in @@ -43,8 +43,6 @@ "is-enabled:Check whether unit files are enabled" "list-jobs:List jobs" "cancel:Cancel all, one, or more jobs" - "snapshot:Create a snapshot" - "delete:Remove one or more snapshots" "show-environment:Dump environment" "set-environment:Set one or more environment variables" "unset-environment:Unset one or more environment variables" @@ -268,14 +266,6 @@ done _message "no jobs found" } -# Completion functions for SNAPSHOTS -(( $+functions[_systemctl_delete] )) || _systemctl_delete() -{ - _wanted systemd-snapshots expl snapshot \ - compadd "$@" - ${${(f)"$(__systemctl list-units --type snapshot --all)"}%% *} || - _message "no snapshots found" -} - # Completion functions for TARGETS (( $+functions[_systemctl_set-default] )) || _systemctl_set-default() { @@ -310,7 +300,6 @@ done # [STANDALONE]='daemon-reexec daemon-reload default # emergency exit halt kexec list-jobs list-units # list-unit-files poweroff reboot rescue show-environment' -# [NAME]='snapshot' _systemctl_caching_policy() { diff --git a/shell-completion/zsh/_systemd-run b/shell-completion/zsh/_systemd-run index 8d6957fa9b..c425085cd8 100644 --- a/shell-completion/zsh/_systemd-run +++ b/shell-completion/zsh/_systemd-run @@ -26,7 +26,21 @@ _arguments \ {-M+,--machine=}'[Operate on local container]:machines:_sd_machines' \ '--scope[Run this as scope rather than service]' \ '--unit=[Run under the specified unit name]:unit name' \ - {-p+,--property=}'[Set unit property]:NAME=VALUE' \ + {-p+,--property=}'[Set unit property]:NAME=VALUE:(( \ + CPUAccounting= MemoryAccounting= BlockIOAccounting= SendSIGHUP= \ + SendSIGKILL= MemoryLimit= CPUShares= BlockIOWeight= User= Group= \ + DevicePolicy= KillMode= DeviceAllow= BlockIOReadBandwidth= \ + BlockIOWriteBandwidth= BlockIODeviceWeight= Nice= Environment= \ + KillSignal= LimitCPU= LimitFSIZE= LimitDATA= LimitSTACK= \ + LimitCORE= LimitRSS= LimitNOFILE= LimitAS= LimitNPROC= \ + LimitMEMLOCK= LimitLOCKS= LimitSIGPENDING= LimitMSGQUEUE= \ + LimitNICE= LimitRTPRIO= LimitRTTIME= PrivateTmp= PrivateDevices= \ + PrivateNetwork= NoNewPrivileges= WorkingDirectory= RootDirectory= \ + TTYPath= SyslogIdentifier= SyslogLevelPrefix= SyslogLevel= \ + SyslogFacility= TimerSlackNSec= OOMScoreAdjust= ReadWriteDirectories= \ + ReadOnlyDirectories= InaccessibleDirectories= EnvironmentFile= \ + ProtectSystem= ProtectHome= RuntimeDirectory= PassEnvironment= \ + ))' \ '--description=[Description for unit]:description' \ '--slice=[Run in the specified slice]:slices:__slices' \ {-r,--remain-after-exit}'[Leave service around until explicitly stopped]' \ |