On Sat, Mar 9, 2019 at 1:52 PM Elijah Newren <newren@xxxxxxxxx> wrote: > On Fri, Mar 8, 2019 at 2:17 AM Nguyễn Thái Ngọc Duy <pclouds@xxxxxxxxx> wrote: > > + if (!opts->checkout_worktree && !opts->checkout_index) > > + die(_("neither '%s' or '%s' is specified"), > > + "--index", "--worktree"); > > Is this die() or BUG()? I thought --worktree was the default. The user might type "git restore --no-worktree --no-index" which would trigger this error message, so definitely die(), not a BUG().