New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[RFC] Add "Don't give the file editing message" flag in shortmess option. #4446
Conversation
fileinfo(FALSE, FALSE, eap->forceit); | ||
|
||
if (!shortmess(SHM_FILEINFO)) { | ||
/* print full file name if :cd used */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
\\
comment
Thank you. Fixed. |
does it mean ,when I start vim like , |
Yes. |
I think I have search for |
I have did it. But it is nothing. So I have implemented. |
Is it possible to make tests for this, or does the message get lost in a redraw? I think this would be the only thing missing from this PR. |
I don't know about the UI tests. |
I'm not an expert, but this seems enough: local helpers = require('test.functional.helpers')
local Screen = require('test.functional.ui.screen')
local clear, feed, execute = helpers.clear, helpers.feed, helpers.execute
describe("'shortmess'", function()
local screen
before_each(function()
clear()
screen = Screen.new(25, 5)
screen:attach()
execute('set shortmess&')
end)
after_each(function()
screen:detach()
end)
describe("=F", function()
it(':hides messages about the files read', function()
execute('e test')
screen:expect([[
^ |
~ |
~ |
~ |
"test" is a directory |
]])
execute('set shortmess=F')
execute('e test')
screen:expect([[
^ |
~ |
~ |
~ |
:e test |
]])
end)
end)
end) I created this in |
Thank you! |
I have added the tests by @fmoralesc |
I suggest sending this to Vim first, so that we don't have to do double-work if Bram changes something. At least confirm that |
OK. I will do it. |
I have sent it to vim_dev. |
The patch is merged in Vim 7.4.1570. |
Looking good, and the vim compat detail is solved. 👍 |
@Shougo Just a couple fixes needed for appeasing clint.py. Other than that, this seems ready. |
I have fixed the code style. |
Excellent. Can you squash so we can merge it cleanly? |
Add the UI tests by @fmoralesc Fix the changes for Vim 7.4.1570
I have squashed. |
flags | READ_NEW); | ||
msg_silent = old_msg_silent; | ||
|
||
// Help buffer is filtered. | ||
if (curbuf->b_help) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clint.py is complaining about the lack of braces in this conditional. :(
clear() | ||
screen = Screen.new(25, 5) | ||
screen:attach() | ||
execute('set shortmess&') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clear()
guarantees defaults for all options.
Merged |
Add "Don't give the file editing message" flag in shortmess option. Add the UI tests by @fmoralesc Fix the changes for Vim 7.4.1570
Thank you! |
Add "Don't give the file editing message" flag in shortmess option. Add the UI tests by @fmoralesc Fix the changes for Vim 7.4.1570
Features: f2ae5a9 Add TextYankPost and TextDeletePost autocmds 44b2cef bufhl: new mechanism for plugins to add highlights to a buffer 39c3842 Make set{qf,loc}list() take {title} 77a7ca4 'shortmess': Add "F" flag. #4446 99d4c8c keymap: Support <D-...> (super/command key). Fixes: 14c9b30 terminal.c: temporary fix for incorrect paste handling Notable changes: 50e129f defaults: Enable syntax and filetype plugins. 4e39eee upgrade libvterm (improves terminal reflow)
Features: f2ae5a9 Add TextYankPost and TextDeletePost autocmds 44b2cef bufhl: new mechanism for plugins to add highlights to a buffer 39c3842 Make set{qf,loc}list() take {title} 77a7ca4 'shortmess': Add "F" flag. neovim#4446 99d4c8c keymap: Support <D-...> (super/command key). Fixes: 14c9b30 terminal.c: temporary fix for incorrect paste handling Notable changes: 50e129f defaults: Enable syntax and filetype plugins. 4e39eee upgrade libvterm (improves terminal reflow)
Features: f2ae5a9 Add TextYankPost and TextDeletePost autocmds 44b2cef bufhl: new mechanism for plugins to add highlights to a buffer 39c3842 Make set{qf,loc}list() take {title} 77a7ca4 'shortmess': Add "F" flag. neovim#4446 99d4c8c keymap: Support <D-...> (super/command key). Fixes: 14c9b30 terminal.c: temporary fix for incorrect paste handling Notable changes: 50e129f defaults: Enable syntax and filetype plugins. 4e39eee upgrade libvterm (improves terminal reflow)
Add "Don't give the file editing message" flag in shortmess option. Add the UI tests by @fmoralesc Fix the changes for Vim 7.4.1570
Features: f2ae5a9 Add TextYankPost and TextDeletePost autocmds 44b2cef bufhl: new mechanism for plugins to add highlights to a buffer 39c3842 Make set{qf,loc}list() take {title} 77a7ca4 'shortmess': Add "F" flag. neovim#4446 99d4c8c keymap: Support <D-...> (super/command key). Fixes: 14c9b30 terminal.c: temporary fix for incorrect paste handling Notable changes: 50e129f defaults: Enable syntax and filetype plugins. 4e39eee upgrade libvterm (improves terminal reflow)
Add "Don't give the file editing message" flag in shortmess option. Add the UI tests by @fmoralesc Fix the changes for Vim 7.4.1570
It adds F flag in shortmess option.
It is "Don't give the file editing message" flag.
Because, it is useless if you use statusline feature.
Note: I will create the patch for Vim after it is merged.