Patch 8.2.2499

8 views
Skip to first unread message

Bram Moolenaar

unread,
Feb 11, 2021, 1:09:14 PM2/11/21
to vim...@googlegroups.com

Patch 8.2.2499
Problem: "vim -g --version" does not redirect output.
Solution: Reset gui.starting when showing version info. (closes #7815)
Files: src/main.c, src/testdir/test_version.vim


*** ../vim-8.2.2498/src/main.c 2020-12-28 18:25:56.796886014 +0100
--- src/main.c 2021-02-11 19:07:34.991992229 +0100
***************
*** 1979,1984 ****
--- 1979,1985 ----
{
Columns = 80; // need to init Columns
info_message = TRUE; // use mch_msg(), not mch_errmsg()
+ gui.starting = FALSE; // not starting GUI, will exit
list_version();
msg_putchar('\n');
msg_didout = FALSE;
*** ../vim-8.2.2498/src/testdir/test_version.vim 2020-08-12 18:50:31.887655765 +0200
--- src/testdir/test_version.vim 2021-02-11 19:06:57.452085537 +0100
***************
*** 1,5 ****
--- 1,8 ----
" Test :version Ex command

+ so check.vim
+ so shared.vim
+
func Test_version()
" version should always return the same string.
let v1 = execute('version')
***************
*** 9,12 ****
--- 12,26 ----
call assert_match("^\n\nVIM - Vi IMproved .*", v1)
endfunc

+ func Test_version_redirect()
+ CheckNotGui
+ CheckCanRunGui
+ CheckUnix
+
+ call RunVim([], [], '--clean -g --version >Xversion 2>&1')
+ call assert_match('Features included', readfile('Xversion')->join())
+
+ call delete('Xversion')
+ endfunc
+
" vim: shiftwidth=2 sts=2 expandtab
*** ../vim-8.2.2498/src/version.c 2021-02-11 18:36:27.584202581 +0100
--- src/version.c 2021-02-11 18:58:39.609285730 +0100
***************
*** 752,753 ****
--- 752,755 ----
{ /* Add new patch number below this line */
+ /**/
+ 2499,
/**/

--
ARTHUR: Then who is your lord?
WOMAN: We don't have a lord.
ARTHUR: What?
DENNIS: I told you. We're an anarcho-syndicalist commune. We take it in
turns to act as a sort of executive officer for the week.
The Quest for the Holy Grail (Monty Python)

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///

Bram Moolenaar

unread,
Feb 11, 2021, 1:19:30 PM2/11/21
to vim...@googlegroups.com

Patch 8.2.2500 (after 8.2.2499)
Problem: Build fails without the GUI feature.
Solution: Add #ifdef.
Files: src/main.c


*** ../vim-8.2.2499/src/main.c 2021-02-11 19:08:01.427926377 +0100
--- src/main.c 2021-02-11 19:16:49.910590385 +0100
***************
*** 1979,1985 ****
--- 1979,1987 ----
{
Columns = 80; // need to init Columns
info_message = TRUE; // use mch_msg(), not mch_errmsg()
+ #if defined(FEAT_GUI) && !defined(ALWAYS_USE_GUI)
gui.starting = FALSE; // not starting GUI, will exit
+ #endif
list_version();
msg_putchar('\n');
msg_didout = FALSE;
*** ../vim-8.2.2499/src/version.c 2021-02-11 19:08:01.431926369 +0100
--- src/version.c 2021-02-11 19:17:31.290484675 +0100
***************
*** 752,753 ****
--- 752,755 ----
{ /* Add new patch number below this line */
+ /**/
+ 2500,
/**/

--
ARTHUR: Be quiet!
DENNIS: --but by a two-thirds majority in the case of more--
ARTHUR: Be quiet! I order you to be quiet!
WOMAN: Order, eh -- who does he think he is?
ARTHUR: I am your king!
Reply all
Reply to author
Forward
0 new messages