gitui-org / gitui-org/gitui

refactor hunk edit methods to use line edit methods

Open
#1,804 0 comments 0 reactions 0 assignees View on GitHub
feature-request
Dominant language
Rust
Stars
22.5k
Forks
773
PR merge metrics
No merged PRs in 30d

Description

currently (un)staging/reset hunk uses an obscure method that requires specific diff mechanics and therefore broke recently: #1746

the cleaner approach is to use the info about a hunk (what line range is affected) and then use the same code used to do line-specific edits and therefore reduce the necessary code and making it easier to maintain.

this removes also another aspect of current implementation to depend on libgit2 type diffs/hunks, so further unblocks #358

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.