diff --git a/src/main.rs b/src/main.rs index 7b1b96b079..9169e2dba3 100644 --- a/src/main.rs +++ b/src/main.rs @@ -222,7 +222,7 @@ fn main() { lhs_path, rhs_path, display_path, - old_path, + renamed, } => { if lhs_path == rhs_path { let is_dir = match &lhs_path { @@ -297,7 +297,7 @@ fn main() { _ => { let diff_result = diff_file( &display_path, - old_path, + renamed, &lhs_path, &rhs_path, &display_options, diff --git a/src/options.rs b/src/options.rs index 09a530a435..43f3908e6e 100644 --- a/src/options.rs +++ b/src/options.rs @@ -376,8 +376,8 @@ pub(crate) enum Mode { rhs_path: FileArgument, /// The path that we show to the user. display_path: String, - /// If this file has been renamed, the name it had previously. - old_path: Option, + /// If this file has been renamed, a description of the change. + renamed: Option, }, DiffFromConflicts { diff_options: DiffOptions, @@ -635,7 +635,7 @@ pub(crate) fn parse_args() -> Mode { info!("CLI arguments: {:?}", args); // TODO: document these different ways of calling difftastic. - let (display_path, lhs_path, rhs_path, old_path) = match &args[..] { + let (display_path, lhs_path, rhs_path, renamed) = match &args[..] { [lhs_path, rhs_path] => { let lhs_arg = FileArgument::from_cli_argument(lhs_path); let rhs_arg = FileArgument::from_cli_argument(rhs_path); @@ -725,7 +725,7 @@ pub(crate) fn parse_args() -> Mode { lhs_path, rhs_path, display_path, - old_path, + renamed, } }