Repository navigation
Conversation
* Support drawing tree connectors before file names Add a file_name_tree field to the view column data. When set, the file name column is prefixed with tree connectors rendered according to the line-graphics option, one 4-column cell per depth level. The automatic column width accounts for the connectors. This is a preparation for showing the status view as a directory tree. * status: Read all files of a section before adding lines Collect the parsed entries of a status section in an array and only add them to the view once the section has been read. This makes it possible to reorder the entries before displaying them, and has no visible effect on its own. * status: Add option to show files as a directory tree Add the status-tree option, which is off by default. When enabled, the files of each status view section are shown as a directory tree similar to tree(1) instead of a flat list of paths. Directories are listed before files, and directories only containing a single subdirectory are collapsed into one line. Directory lines can be staged or unstaged using status-update, which updates all files below the directory. Searching also matches the full path of files shown in the tree. Closes jonas#1441 * status: Bind 't' to toggle the directory tree layout Bind 't' in the status view to `:toggle status-tree`, which also makes the toggle show up on the help page. The binding overrides the generic view-tree binding within the status view only.
When the stage view is open, moving to the next or previous file moves the cursor in the status view and shows the diff of the new line. Directory lines of the status tree have no diff, so the stage view kept showing the previous file. Skip directory lines in this case. Also mention in NEWS that 't' no longer opens the tree view from the status view.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Closes #1441
Bind 't' in the status view to
:toggle status-tree, which also makes the toggle show up on the help page. The binding overrides the generic view-tree binding within the status view only.Add a file_name_tree field to the view column data. When set, the file name column is prefixed with tree connectors rendered according to the line-graphics option, one 4-column cell per depth level. The automatic column width accounts for the connectors.
This is a preparation for showing the status view as a directory tree.
Collect the parsed entries of a status section in an array and only add them to the view once the section has been read. This makes it possible to reorder the entries before displaying them, and has no visible effect on its own.
Add the status-tree option, which is off by default. When enabled, the files of each status view section are shown as a directory tree similar to tree(1) instead of a flat list of paths. Directories are listed before files, and directories only containing a single subdirectory are collapsed into one line.
Directory lines can be staged or unstaged using status-update, which updates all files below the directory. Searching also matches the full path of files shown in the tree.