Execute stash show.
(&self, repo: &Repository, stash_ref: Option<&str>, patch: bool)
| 633 | |
| 634 | /// Execute stash show. |
| 635 | fn run_show(&self, repo: &Repository, stash_ref: Option<&str>, patch: bool) -> CliResult<()> { |
| 636 | let stash = self.parse_stash_ref(repo, stash_ref)?; |
| 637 | |
| 638 | println!("{}", stash.reference()); |
| 639 | println!(" Source view: {}", style_view(&stash.source_view)); |
| 640 | println!(" Message: {}", stash.message); |
| 641 | println!( |
| 642 | " Created: {}", |
| 643 | format_timestamp_relative(&stash.created_at) |
| 644 | ); |
| 645 | |
| 646 | // Get view info |
| 647 | let info = repo |
| 648 | .get_view_info(&stash.view_name) |
| 649 | .map_err(CliError::Repository)?; |
| 650 | |
| 651 | println!(" Changes: {}", info.change_count); |
| 652 | |
| 653 | if patch { |
| 654 | // TODO: Implement full diff output |
| 655 | print_blank(); |
| 656 | print_hint("Full diff output not yet implemented"); |
| 657 | } |
| 658 | |
| 659 | Ok(()) |
| 660 | } |
| 661 | |
| 662 | /// Execute stash drop. |
| 663 | fn run_drop(&self, repo: &mut Repository, stash_ref: Option<&str>) -> CliResult<()> { |
no test coverage detected