Bug 257458

Summary: efibootmgr(8) does not respect --dry-run for most operations
Product: Base System Reporter: Yang Zhong <yzhong>
Component: binAssignee: Warner Losh <imp>
Status: Open ---    
Severity: Affects Only Me CC: emaste, imp
Priority: ---    
Version: CURRENT   
Hardware: Any   
OS: Any   

Description Yang Zhong 2021-07-27 19:21:24 UTC
When I use efibootmgr to delete boot entries, I expect something like

efibootmgr --dry-run -B -b 0015

to display which entry it would delete, but not actually delete it. In reality, it deletes the entry. Looking at the source, it appears that the dry-run flag is only considered when creating new boot entries, but the man page gives no indication of this.
Comment 1 Warner Losh freebsd_committer freebsd_triage 2021-07-28 17:31:30 UTC
Yes, the current situation isn't as documented. I'll see how
hard it is to make dry-run honored by all the different actions
that can be done.