mirror of
https://github.com/extrawurst/gitui.git
synced 2024-11-27 00:14:52 +03:00
better naming
This commit is contained in:
parent
b71f39fbb3
commit
387b8748b1
@ -56,7 +56,7 @@ fn find_hunk_index(diff: &Diff, hunk_hash: u64) -> Option<usize> {
|
||||
}
|
||||
|
||||
///
|
||||
pub fn revert_hunk(
|
||||
pub fn unstage_hunk(
|
||||
repo_path: &str,
|
||||
file_path: String,
|
||||
hunk_hash: u64,
|
||||
|
@ -6,7 +6,7 @@ mod reset;
|
||||
pub mod status;
|
||||
pub mod utils;
|
||||
|
||||
pub use hunks::{revert_hunk, stage_hunk};
|
||||
pub use hunks::{stage_hunk, unstage_hunk};
|
||||
pub use reset::{reset_stage, reset_workdir};
|
||||
pub use utils::{commit, stage_add};
|
||||
|
||||
|
@ -294,7 +294,7 @@ impl App {
|
||||
InternalEvent::AddHunk(hash) => {
|
||||
if let Some((path, is_stage)) = self.selected_path() {
|
||||
if is_stage {
|
||||
if sync::revert_hunk(CWD, path, *hash) {
|
||||
if sync::unstage_hunk(CWD, path, *hash) {
|
||||
self.update();
|
||||
}
|
||||
} else if sync::stage_hunk(CWD, path, *hash) {
|
||||
|
Loading…
Reference in New Issue
Block a user