diff src/ex_cmds.c @ 14185:20468fb49f9b v8.1.0110

patch 8.1.0110: file name not displayed with ":file" commit https://github.com/vim/vim/commit/fc0896093c3b3e753859a5f929921933e7a2e6cd Author: Bram Moolenaar <Bram@vim.org> Date: Sun Jun 24 16:53:35 2018 +0200 patch 8.1.0110: file name not displayed with ":file" Problem: File name not displayed with ":file" when 'F' is in 'shortmess'. Solution: Always display the file name when there is no argument (Christian Brabandt, closes #3070)
author Christian Brabandt <cb@256bit.org>
date Sun, 24 Jun 2018 17:00:06 +0200
parents 2ad722003b36
children 6fbb8dfb3389
line wrap: on
line diff
--- a/src/ex_cmds.c
+++ b/src/ex_cmds.c
@@ -3094,11 +3094,12 @@ ex_file(exarg_T *eap)
     {
 	if (rename_buffer(eap->arg) == FAIL)
 	    return;
-    }
-    /* print full file name if :cd used */
-    if (!shortmess(SHM_FILEINFO))
+	redraw_tabline = TRUE;
+    }
+
+    // print file name if no argument or 'F' is not in 'shortmess'
+    if (*eap->arg == NUL || !shortmess(SHM_FILEINFO))
 	fileinfo(FALSE, FALSE, eap->forceit);
-    redraw_tabline = TRUE;
 }
 
 /*