Part of bzrlib.shelf_ui View In Hierarchy
Known subclasses: bzrlib.tests.test_shelf_ui.ExpectShelver
| Method | __init__ | Constructor. |
| Class Method | from_args | Create a shelver from commandline arguments. |
| Method | run | Interactively shelve the changes. |
| Method | finalize | Undocumented |
| Method | get_parsed_patch | Return a parsed version of a file's patch. |
| Method | prompt | Undocumented |
| Method | prompt_bool | Prompt the user with a yes/no question. |
| Method | handle_modify_text | Handle modified text, by using hunk selection or file editing. |
| Method | _select_hunks | Provide diff hunk selection for modified text. |
| Method | _edit_file | |
| Static Method | _count_changed_regions | Undocumented |
| Parameters | work_tree | The working tree to shelve changes from. |
| target_tree | The "unchanged" / old tree to compare the work_tree to. | |
| auto | If True, shelve each possible change. | |
| auto_apply | If True, shelve changes with no final prompt. | |
| file_list | If supplied, only files in this list may be shelved. | |
| message | The message to associate with the shelved changes. | |
| destroy | Change the working tree without storing the shelved changes. | |
| manager | The shelf manager to use. | |
| reporter | Object for reporting changes to user. |
The returned shelver wil have a work_tree that is locked and should be unlocked.
| Parameters | revision | RevisionSpec of the revision to compare to. |
| all | If True, shelve all changes without prompting. | |
| file_list | If supplied, only files in this list may be shelved. | |
| message | The message to associate with the shelved changes. | |
| directory | The directory containing the working tree. | |
| destroy | Change the working tree without storing the shelved changes. |
| Parameters | file_id | The id of the file to generate a patch for. |
| invert | If True, provide an inverted patch (insertions displayed as removals, removals displayed as insertions). | |
| Returns | A patches.Patch. | |
This may be overridden by self.auto. It may also set self.auto. It may also raise UserAbort. :param question: The question to ask the user. :return: True or False
| Parameters | creator | A ShelfCreator. |
| file_id | The id of the file that was modified. | |
| Returns | The number of changes. | |
If self.reporter.invert_diff is True, the diff is inverted so that insertions are displayed as removals and vice versa.
| Parameters | creator | a ShelfCreator |
| file_id | The id of the file to shelve. | |
| work_tree_lines | Line contents of the file in the working tree. | |
| Returns | number of shelved hunks. | |