Some git command likes `git checkout -b` do no update .git/index.
Instead watch the git dir itself to capture all git operations.
Renamed config.watch_index -> config.watch_gitdir
Fixes#377
- Fix duplicate items appearing (#370)
- Make setqflist/setloclist async again
- setqflist('all') now also looks in the current working directory
- Automatically open the quickfix/location list on completion
- Make setloclist an alias of setqflist
- Refactor git.tl so now there is a separate 'Repo' object to allows us
to create git objects for a directory.
Fixes#370
- Provide b:gitsigns_blame_line_dict for blame info for current line.
Require config.current_line_blame = true.
- Added config.current_line_blame_opts
- Added config.current_line_blame_opts.virt_text. Can be disabled to
disable virtual text. Useful if you want b:gitsigns_blame_line_dict
but without the blame annotation.
- Moved config.current_line_blame_delay to
config.current_line_blame_opts.delay
- Moved config.current_line_blame_pos to
config.current_line_blame_opts.virt_text_pos
- Added deprecation handling for old options
Resolve#199
Set the quickfix/location list with hunks from either:
- A specific buffer
- All attached buffers
- All modified files for each gitdir of each attached buffer
Type definitions.
Implement range for reset_hunk. Fix create_patch. Update docs.
Note on the `create_patch` fix: The block header generated by this
function was previously not considering changes made by previously
processed hunks. This was causing patches to be applied incorrectly when
staging multiple hunks.
Update lua files.
Un-async reset_hunk.
Store user provided range in var. Adjustments based on feedback.
Updated lua files.
Removed unused import.
- Callback to set keymaps (instead of config.keymaps) and to control
whether to attach to a buffer.
- Documented how extended table configuation fields work.
- Removed non-buffer mappings and `buffer=true` from the default.
Resolves#155
This allow users to run `lua require"gitsigns".stage_buffer()` to stage
all changes in a buffer and `lua require"gitsigns".reset_buffer_index()` to
unstage all changes in a buffer.
Added `ensure_file_in_index` to make sure files are tracked before
staging hunks.
Added `clear_status` to status, to clear only modifications (added,
changed, removed)
Added tests for `stage_buffer` and `reset_buffer_index`
Closes: #127
Defaults to true (current behaviour). Disabling will cause the staged
file to be only be updated when the index changes resulting in less jobs
and better performance. Marking as undocumented as there *may* be cases
where updates of the staged files don't happen when they should.
Also expose refresh() in case the above issue ever occurs.