Auto-complete for grub-reboot provides invalid options, most of which fail silently
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
grub2 (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
Hitting tab on `grub-reboot` gives:
```
$ grub-reboot [tab]
--id
Advanced options for Ubuntu
Ubuntu
Ubuntu, with Linux 4.15.0-108-generic
Ubuntu, with Linux 4.15.0-108-generic (recovery mode)
Ubuntu, with Linux 4.15.0-109-generic
Ubuntu, with Linux 4.15.0-109-generic (recovery mode)
```
But
```
$ grub-reboot --id
Unrecognized option `--id'
[...]
```
And the menu items starting with "Ubuntu, with Linux 4.15.0-" are actually in the submenu "Advanced options for Ubuntu". So, saying `grub-reboot "Ubuntu, with Linux 4.15.0-
Additionally, `grub-reboot` accepts those and other meaningless parameters without complaint:
```
$ sudo grub-reboot nonsense && echo success
success
```
ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: grub2-common 2.02-2ubuntu8.15
ProcVersionSign
Uname: Linux 4.15.0-109-generic x86_64
ApportVersion: 2.20.9-0ubuntu7.15
Architecture: amd64
Date: Fri Jul 3 16:35:28 2020
ProcEnviron:
TERM=xterm
PATH=(custom, no user)
XDG_RUNTIME_
LANG=C.UTF-8
SHELL=/bin/bash
SourcePackage: grub2
UpgradeStatus: No upgrade log present (probably fresh install)