class documentation

Manages the git-rebase-todo file for interactive rebase.

Class Method from_commits Create a todo list from a list of commits.
Class Method from_string Parse a git-rebase-todo file.
Method __init__ Initialize RebaseTodo.
Method add_entry Add an entry to the todo list.
Method advance Move to the next todo entry.
Method get_current Get the current todo entry.
Method is_complete Check if all entries have been processed.
Method to_string Convert to git-rebase-todo file format.
Instance Variable current_index Undocumented
Instance Variable entries Undocumented
def from_commits(cls, commits: Sequence[Commit]) -> RebaseTodo:

Create a todo list from a list of commits.

Parameters
commits:Sequence[Commit]List of commits to rebase (in chronological order)
Returns
RebaseTodoRebaseTodo instance with pick commands for each commit
def from_string(cls, content: str) -> RebaseTodo:

Parse a git-rebase-todo file.

Parameters
content:strContent of todo file
Returns
RebaseTodoRebaseTodo instance
def __init__(self, entries: list[RebaseTodoEntry] | None = None):

Initialize RebaseTodo.

Parameters
entries:list[RebaseTodoEntry] | NoneList of todo entries
def add_entry(self, entry: RebaseTodoEntry):

Add an entry to the todo list.

def advance(self):

Move to the next todo entry.

def get_current(self) -> RebaseTodoEntry | None:

Get the current todo entry.

def is_complete(self) -> bool:

Check if all entries have been processed.

def to_string(self, include_comments: bool = True) -> str:

Convert to git-rebase-todo file format.

Parameters
include_comments:boolInclude helpful comments
Returns
strString content for todo file
current_index: int =

Undocumented

entries =

Undocumented