From c6eaf3ae242f0ba5eea595bd87ddb89d919826cc Mon Sep 17 00:00:00 2001 From: Timo Sand Date: Sat, 4 Nov 2017 11:31:27 +0200 Subject: [PATCH] git-diff: Adds comparison of file on current branch to other branch (#1611) --- pages/common/git-diff.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pages/common/git-diff.md b/pages/common/git-diff.md index 19a7ee3c48..e9f69d78f1 100644 --- a/pages/common/git-diff.md +++ b/pages/common/git-diff.md @@ -33,3 +33,7 @@ - Compare a single file between two branches or commits: `git diff {{branch_1}}..{{branch_2}} [--] {{path/to/file}}` + +- Compare different files from the current branch to other branch: + +`git diff {{branch}}:{{path/to/file2}} {{path/to/file}}`