new feature: import/export marked commit lists #915
+580
−4
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When doing large backports or similar work that involves a lot of
cherry picking, it can be useful to maintain lists of commits. While
in the main view, Tig can mark commits via the toggle-bp-mark action,
which is bound to C-b by default. Marked commits title will be
displayed using an alternative style (main-bp-mark).
If a path is specified when running Tig (see
-l
option). Tig canread and write marked commits. Tig tries to import that file on
startup if it exists, and writes to that file on exit.
The format of this file is simple, each line must have the following format:
Tig tries to keep the content of each line when it imports
it. Additional commits added during the Tig session will use the
commit title as text when exporting.
On exit, Tig sorts the marked commits by commit date (not author date)
and exports the marked lists to the file specified by the
-l
option.-l
to specify location to import/export marked list toCurrently tig has one global bplist, but the implementation is generic
enough and works on bplist instances so that in the future we could
have multiple bplists.
A bplist holds a list of lines and a hashtable that maps fully-expanded revs to lines.