To: vim_dev@googlegroups.com Subject: Patch 9.0.1653 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 9.0.1653 Problem: Amiga: default 'viewdir' may not work. Solution: Use "home:" instead of "$VIM". Add a test. (Christian Brabandt, closes #12576) Files: runtime/doc/options.txt, src/os_amiga.h, src/testdir/setup.vim, src/testdir/test_mksession.vim *** ../vim-9.0.1652/runtime/doc/options.txt 2023-06-23 16:15:07.469504475 +0100 --- runtime/doc/options.txt 2023-06-23 22:17:31.957277077 +0100 *************** *** 8843,8851 **** displayed when 'verbosefile' is set. *'viewdir'* *'vdir'* ! 'viewdir' 'vdir' string (default for Amiga "$VIM/vimfiles/view", for Win32: "$HOME/vimfiles/view", ! for Unix: "~/.vim/view", for macOS: "$VIM/vimfiles/view" for VMS: "sys$login:vimfiles/view") global --- 8912,8920 ---- displayed when 'verbosefile' is set. *'viewdir'* *'vdir'* ! 'viewdir' 'vdir' string (default for Amiga "home:vimfiles/view", for Win32: "$HOME/vimfiles/view", ! for Unix: "$HOME/.vim/view", for macOS: "$VIM/vimfiles/view" for VMS: "sys$login:vimfiles/view") global *** ../vim-9.0.1652/src/os_amiga.h 2023-06-08 22:16:19.688379704 +0100 --- src/os_amiga.h 2023-06-23 22:01:54.977471370 +0100 *************** *** 199,205 **** #endif #ifndef DFLT_VDIR ! # define DFLT_VDIR "$VIM/vimfiles/view" // default for 'viewdir' #endif #ifndef DFLT_MAXMEM --- 199,205 ---- #endif #ifndef DFLT_VDIR ! # define DFLT_VDIR "home:vimfiles/view" // default for 'viewdir' #endif #ifndef DFLT_MAXMEM *** ../vim-9.0.1652/src/testdir/setup.vim 2023-01-28 19:18:56.725720605 +0000 --- src/testdir/setup.vim 2023-06-23 22:14:19.333366654 +0100 *************** *** 30,35 **** --- 30,39 ---- " Avoid storing shell history. let $HISTFILE = "" + " Have current $HOME available as $ORIGHOME. $HOME is used for option + " defaults before we get here, and test_mksession checks that. + let $ORIGHOME = $HOME + " Make sure $HOME does not get read or written. " It must exist, gnome tries to create $HOME/.gnome2 let $HOME = getcwd() . '/XfakeHOME' *** ../vim-9.0.1652/src/testdir/test_mksession.vim 2022-09-29 21:37:19.321641591 +0100 --- src/testdir/test_mksession.vim 2023-06-23 22:15:59.397324768 +0100 *************** *** 1262,1265 **** --- 1262,1278 ---- bw! endfunc + " Test default 'viewdir' value + func Test_mkview_default_home() + if has('win32') + call assert_match('^' .. $ORIGHOME .. '/vimfiles', &viewdir) + elseif has('unix') + call assert_match('^' .. $ORIGHOME .. '/.vim', &viewdir) + elseif has('amiga') + call assert_match('^home:vimfiles', &viewdir) + elseif has('mac') + call assert_match('^' .. $VIM .. '/vimfiles', &viewdir) + endif + endfunc + " vim: shiftwidth=2 sts=2 expandtab *** ../vim-9.0.1652/src/version.c 2023-06-23 21:36:27.364304002 +0100 --- src/version.c 2023-06-23 22:18:53.045229395 +0100 *************** *** 697,698 **** --- 697,700 ---- { /* Add new patch number below this line */ + /**/ + 1653, /**/ -- How do I set this laser printer to stun? /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// \\\ \\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///