Fixing a panic with reset --dry-run and no input
[?]
Dec 4, 2020, 9:10 PM
QYY37T6YMICHA57GBXBBR4OYE2A76SFDKXPDKIKSEDDXCNQVC5CACDependencies
- [2]
L4JXJHWXpijul/*: reorganize imports and remove extern crate - [3]
SNZ3OAMCuse native external subcommand support instead of hand-rolled one - [4]
NLGQAH4HCredit and reset relative to current directory instead of the root - [5]
SXEYMYF7Fixing the bad changes in history (unfortunately, by rebooting).
Change contents
- edit in pijul/src/main.rs at line 144
#[error("Cannot dry-reset multiple files")]CannotDryReset, - edit in pijul/src/commands/reset.rs at line 3
use anyhow::bail; - replacement in pijul/src/commands/reset.rs at line 49
if self.files.len() > 1 {return Err(Error::CannotDryReset.into());if self.files.len() != 1 {bail!("reset --dry-run needs exactly one file");