diff options
author | Dave Reisner <dreisner@archlinux.org> | 2014-08-29 20:35:15 -0400 |
---|---|---|
committer | Dave Reisner <dreisner@archlinux.org> | 2014-08-29 20:40:38 -0400 |
commit | ec15977a3cd82eff6c94bb13db72195f7cd512e8 (patch) | |
tree | bffae386d8a113eda7cef7961df65b4db533564d | |
parent | f2e104d3e0c43e4efd7c1952065bd4b79eefa427 (diff) |
completion: filter templates from restartable units
Since c6a373a2634854, we might encounter unit templates via the
'list-units' verb. These aren't restartable (and we throw errors), so
make sure they're filtered out of the completion options.
fixes downstream bug: https://bugs.archlinux.org/task/41719
-rw-r--r-- | shell-completion/bash/systemctl.in | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/shell-completion/bash/systemctl.in b/shell-completion/bash/systemctl.in index 64b15df462..015001815f 100644 --- a/shell-completion/bash/systemctl.in +++ b/shell-completion/bash/systemctl.in @@ -182,7 +182,7 @@ _systemctl () { comps=$( __filter_units_by_property $mode CanStart yes \ $( __get_all_units $mode \ | while read -r line; do \ - [[ "$line" =~ \.(device|snapshot|socket|timer)$ ]] || echo " $line"; \ + [[ "$line" =~ @\.|\.(device|snapshot|socket|timer)$ ]] || echo " $line"; \ done )) compopt -o filenames |