From c630ef12f388ecb40834d9b4456ce80fc499dedf Mon Sep 17 00:00:00 2001 From: Jonas Fonseca Date: Mon, 17 Mar 2008 14:58:51 +0100 Subject: [PATCH] Refresh the index when opening the status view to avoid "empty diffs" --- tig.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tig.c b/tig.c index 8f78697..71ddbb5 100644 --- a/tig.c +++ b/tig.c @@ -3324,7 +3324,7 @@ error_out: /* Don't show unmerged entries in the staged section. */ #define STATUS_DIFF_INDEX_CMD "git diff-index -z --diff-filter=ACDMRTXB --cached -M HEAD" -#define STATUS_DIFF_FILES_CMD "git diff-files -z" +#define STATUS_DIFF_FILES_CMD "git update-index -q --refresh && git diff-files -z" #define STATUS_LIST_OTHER_CMD \ "git ls-files -z --others --exclude-per-directory=.gitignore" -- 2.32.0.93.g670b81a890