Adding --force to reset/switch, to ignore name conflicts

pmeunier
Dec 6, 2021, 9:41 AM
53SC53QW4BFLG7TLT6N7UQJGUOZUKIO7G72Y2IO3VCLN23W4LGMQC

Dependencies

  • [2] I24UEJQL Various post-fire fixes
  • [3] TFK7CYFQ `pijul channel new` to create new, empty channels
  • [4] JL4WKA5P Implement the Sanakirja concurrency model in a cross-process way
  • [5] SXEYMYF7 Fixing the bad changes in history (unfortunately, by rebooting).
  • [6] VQPAUKBQ channel switch as an alias to reset
  • [7] Q4SVMHAE Removing --channel from the changes command
  • [8] 5OGOE4VW Store the current channel in the pristine
  • [9] EUZFFJSO Updating Pijul with the latest changes in Libpijul
  • [10] KWAMD2KR A few fixes in the documentation comments
  • [*] AEPEFS7O Write help for each argument
  • [*] I52XSRUH Massive cleanup, and simplification

Change contents

  • edit in pijul/src/commands/reset.rs at line 25
    [4.384]
    [12.817]
    /// Reset even if there are unrecorded changes.
    #[clap(long = "force", short = 'f')]
    pub force: bool,
  • replacement in pijul/src/commands/reset.rs at line 103
    [2.7141][2.7141:7184]()
    } else if self.channel.is_some() {
    [2.7141]
    [2.7184]
    } else if self.channel.is_some() && !self.force {
  • replacement in pijul/src/commands/channel.rs at line 31
    [4.964][4.964:999]()
    Switch { to: Option<String> },
    [4.964]
    [3.0]
    Switch {
    to: Option<String>,
    #[clap(long = "force", short = 'f')]
    force: bool,
    },
  • replacement in pijul/src/commands/channel.rs at line 71
    [4.188393][4.1410:1459]()
    Some(SubCommand::Switch { to }) => {
    [4.188393]
    [4.1459]
    Some(SubCommand::Switch { to, force }) => {
  • edit in pijul/src/commands/channel.rs at line 77
    [4.1697]
    [13.6379]
    force,