[vim] 02/03: vim-tiny: Disable loading of defaults.vim when invoked as vi

James McCoy jamessan at debian.org
Wed Oct 5 01:50:07 UTC 2016


This is an automated email from the git hooks/post-receive script.

jamessan pushed a commit to branch debian/sid
in repository vim.

commit 1db7f61f26867d70da5cc4c956745f77efd32a8a
Author: James McCoy <jamessan at debian.org>
Date:   Tue Oct 4 21:00:18 2016 -0400

    vim-tiny: Disable loading of defaults.vim when invoked as vi
    
    Signed-off-by: James McCoy <jamessan at debian.org>
---
 debian/changelog                                         |  2 ++
 ...sourcing-a-vimrc.tiny-when-Vim-is-invoked-as-vi.patch | 16 +++++++++++++---
 2 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 9966875..9cbc708 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -4,6 +4,8 @@ vim (2:8.0.0003-2) UNRELEASED; urgency=medium
     patch!
   * Add information about defaults.vim to NEWS.Debian and /etc/vim/vimrc.
     (Closes: #837761)
+  * Update vim-tiny patch to not source defaults.vim when vim.tiny is invoked
+    as vi.
 
  -- James McCoy <jamessan at debian.org>  Tue, 27 Sep 2016 22:02:22 -0400
 
diff --git a/debian/patches/debian/Support-sourcing-a-vimrc.tiny-when-Vim-is-invoked-as-vi.patch b/debian/patches/debian/Support-sourcing-a-vimrc.tiny-when-Vim-is-invoked-as-vi.patch
index 07bbd25..4bf71ea 100644
--- a/debian/patches/debian/Support-sourcing-a-vimrc.tiny-when-Vim-is-invoked-as-vi.patch
+++ b/debian/patches/debian/Support-sourcing-a-vimrc.tiny-when-Vim-is-invoked-as-vi.patch
@@ -11,13 +11,13 @@ Closes: #222138
 Signed-off-by: Stefano Zacchiroli <zack at debian.org>
 Signed-off-by: James Vega <jamessan at debian.org>
 ---
- src/main.c    | 11 ++++++++++-
+ src/main.c    | 14 +++++++++++++-
  src/os_unix.h |  3 +++
  src/structs.h |  3 +++
- 3 files changed, 16 insertions(+), 1 deletion(-)
+ 3 files changed, 19 insertions(+), 1 deletion(-)
 
 diff --git a/src/main.c b/src/main.c
-index acc51f1..50dbff8 100644
+index acc51f1..3c47df2 100644
 --- a/src/main.c
 +++ b/src/main.c
 @@ -1729,6 +1729,10 @@ parse_command_name(mparm_T *parmp)
@@ -45,6 +45,16 @@ index acc51f1..50dbff8 100644
  #endif
  #ifdef MACOS_X
  	(void)do_source((char_u *)"$VIMRUNTIME/macmap.vim", FALSE, DOSO_NONE);
+@@ -3003,6 +3012,9 @@ source_startup_scripts(mparm_T *parmp)
+ #ifdef USR_EXRC_FILE2
+ 		&& do_source((char_u *)USR_EXRC_FILE2, FALSE, DOSO_NONE) == FAIL
+ #endif
++#if defined(SYS_TINYRC_FILE) && defined(TINY_VIMRC)
++		&& !parmp->vi_mode
++#endif
+ 		&& !has_dash_c_arg)
+ 	    {
+ 		/* When no .vimrc file was found: source defaults.vim. */
 diff --git a/src/os_unix.h b/src/os_unix.h
 index 1070746..0020c58 100644
 --- a/src/os_unix.h

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-vim/vim.git



More information about the pkg-vim-maintainers mailing list