Whether this invocation must be blocked until `--force` is supplied. Only a whole-working-copy restore (no paths named) is guarded, because it would discard *all* uncommitted work. Naming specific files is explicit consent (like `git restore `), and `--force` / `--dry-run` always bypass the guard.
(&self, has_changes: bool)
| 161 | /// explicit consent (like `git restore <file>`), and `--force` / |
| 162 | /// `--dry-run` always bypass the guard. |
| 163 | fn requires_force(&self, has_changes: bool) -> bool { |
| 164 | !self.is_partial() && has_changes && !self.force && !self.dry_run |
| 165 | } |
| 166 | |
| 167 | /// Message shown when there is nothing to restore. |
| 168 | /// |