Execute stash pop (apply and delete).
(&self, repo: &mut Repository, stash_ref: Option<&str>)
| 309 | |
| 310 | /// Execute stash pop (apply and delete). |
| 311 | fn run_pop(&self, repo: &mut Repository, stash_ref: Option<&str>) -> CliResult<()> { |
| 312 | let stash = self.parse_stash_ref(repo, stash_ref)?; |
| 313 | |
| 314 | // Apply the stash |
| 315 | self.apply_stash(repo, &stash)?; |
| 316 | |
| 317 | // Delete the stash view |
| 318 | repo.delete_view(&stash.view_name) |
| 319 | .map_err(CliError::Repository)?; |
| 320 | |
| 321 | print_success(&format!("Dropped {}", stash.reference())); |
| 322 | |
| 323 | Ok(()) |
| 324 | } |
| 325 | |
| 326 | /// Execute stash apply (apply without deleting). |
| 327 | fn run_apply(&self, repo: &mut Repository, stash_ref: Option<&str>) -> CliResult<()> { |
no test coverage detected