Commit Briefs

eaeaa612f1 Thomas Adam

tog: blame view keymap to open log of annotated line

As per stsp's TODO item: open a log view of the selected line with 'L'. helped by and ok stsp@


777aae211a Thomas Adam

tog: alias J and K to > and < keybindings for diff view

Use J and K to move to the next and previous commits, respectively, when the diff is loaded from the log or blame views. Patch by Mikhail ok stsp@


f69c5a468f Thomas Adam

tog: add key to toggle author/committer in log view

improvements and ok by jamsek and stsp


ea0bff0410 Thomas Adam

tog: always request commits if log height is increased

Includes style improvements prompted by stsp. Previously, we would only call request_log_commits() when terminal height is increased in a splitscreen view. This fixes the case when a log view with no children is resized that can lead to empty lines: $ tog # 80x24 23j # move down to the last commit *increase terminal height to ~30 lines then reduce back to 80x24* ~5j # move down to the _last_ commit *increase terminal height to ~33 lines* *new lines are empty* ok stsp@


8b925c6ccd Thomas Adam

portable: add back sys/queue.h

Now that the handling of including sys/queue.h is better, there's no need to remove those lines from the source. Copy the location of those original sys/queue.h lines from upstream at the same line number, so as to avoid any conflicts in the future.


47f5fcf413 Thomas Adam

style(9) whitespace fix


fe731b51aa Thomas Adam

tog: fix sticky "loading..." status in log view hsplit

Don't request commits if the log has completed loading all commits. While here, ensure the correct parent/child view requests commits when resizing a hsplit. Reported by stsp: $ tog S # switch into hsplit mode G # move to bottom and load all commits Enter # open a diff showing the initial import commit - # shrink the diff view by one line; alternatively use + to grow it *log status stuck with "loading..." in the header* ok stsp@


ae98518f6b Thomas Adam

tog: only request commits when child hsplit increases

Fix bug introduced in 3c1dfe12b3 that fails to properly populate child log views due to incorrect request_log_commits() calls: (1) when increasing the bottom hsplit in a ref/log splitscreen; and (2) when reopening a child log view after closing a resized child log view: $ TOG_VIEW_SPLIT_MODE=h tog ref return # open log view in bottom split 4+ # increase log (child/bottom) split *new log lines are not populated* q # close log view return *commits are not loaded* ok stsp@


97cb21cdfa Thomas Adam

tog: adjust view line offset when resizing hsplit

Squish bug that can move the selection cursor offscreen when resizing horizontal splits due to bogus offset: $ TOG_VIEW_SPLIT_MODE=h tog # 80x24 22j return # open diff view in a hsplit tab # focus log (top) split 10+ # increase top split by 10 lines 22j return # open diff view in a hsplit F # toggle fullscreen diff view tab # focus log (parent) view in fullscreen *selection cursor will be off the bottom of the screen* ok stsp@


4fc71f3b76 Thomas Adam

tog: enable moving to prev/next blame line in diff view

Blame/diff view counterpart of log/diff <,.> key maps to traverse commits corresponding to each line of the annotated file from the diff view. Includes fix from stsp@ to work while the file is still annotating. ok stsp@


ddbc4d37d0 Thomas Adam

tog: make 'S' switch split mode irrespective of the view

Always switch internal split state and redraw view according to the constraints of the new mode. suggested by and ok stsp@


f2d749db68 Thomas Adam

make 'tog log' error out in shallow Git repositories instead of hanging

ok op@


b9e3c50406 Thomas Adam

portable: remove stale comments

Remove comments which are no longer required.


53d2bdd3e3 Thomas Adam

tog: implement +/- keymaps to resize the focussed split

Increase/decrease the currently active split. New dimensions persist for the tog session, irrespective of subsequent closures and new child views. suggested by and ok stsp@


6448669271 Thomas Adam

tog: implement global 'S' key map to switch split mode

If in a vertical (horizontal) split, switch to horizontal (vertical), and make new split mode persist. ok op@


634cb45445 Thomas Adam

tog: add C-g/backspace key map to abort compound cmds

Problem reported by stsp: 9999j would tie up tog till completed. While here, trim trailing whitespace in tog.1 and make C-g alias existing backspace abort key map for search and G in log view. ok op@ and stsp@


444d532558 Thomas Adam

tog: expand horizontal split support to all views

With this, hsplits are now available to the same parent/child view combinations as vsplits. Includes OB1 log truncation fix from op@ that was reported by stsp. ok stsp@


fa502711bb Thomas Adam

tog: remove count prefix timeout and bold output

Suggested by naddy. block till non-numeric input is entered, and don't echo in bold. ok naddy@ op@ and stsp@


244157854d Thomas Adam

unconditionally set x/y pointers in view_get_split()

suggested by and ok op@


adf4c9e089 Thomas Adam

make the diff algorithm used by 'tog diff' and 'tog blame' configurable

ok jamsek


25ec70067d Thomas Adam

switch 'tog diff' and 'tog blame' to Myers diff for speed

Make the choice of diff algorithm configurable by diff API users. The got and gotweb programs keep using Patience diffs which are prettier than Myers. But tog should be as fast as possible since it is being used interactively. If performance of Patience diff gets improved later we can consider switching tog back over to it. ok tracey jamsek


068ab281f5 Thomas Adam

tog: fix C-d and G log view keymaps in horizontal split

Account for the border so we don't scroll offscreen, and don't unset the load_all flag till all commits have been loaded so we take the correct path in log_move_cursor_down(). ok stsp@


e44940c3e5 Thomas Adam

fix fullscreen / split-screen toggle in tog

ok jamsek


9117a7b739 Thomas Adam

move remaining got_opentemp's out of blame. ok op@


a5d43cac4c Thomas Adam

tog: implement support for horizontal splitscreens

Enable all main views to open primary child views in a horizontal split: log -> diff tree -> blame blame -> diff ref -> log Support is yet to be expanded to nested child views and key maps for manipulating split type and size. ok op@ and stsp@