!609 [sync] PR-608: 修复/etc/vimrc配置失效问题

From: @openeuler-sync-bot 
Reviewed-by: @dillon_chen 
Signed-off-by: @dillon_chen
This commit is contained in:
openeuler-ci-bot 2024-07-05 09:24:31 +00:00 committed by Gitee
commit bb1f7cad46
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 39 additions and 1 deletions

View File

@ -0,0 +1,31 @@
From 54a4d7d5afe1157778223c9c97563b115b9341bc Mon Sep 17 00:00:00 2001
From: Zdenek Dohnal <zdohnal@redhat.com>
Date: 2003-08-04 15:38:05.000000000 +0200
Subject: [PATCH] vim-7.0-rclocation.patch
new /usr/share/vim/{vimrc,virc} symlinks are created forloading /etc/{vimrc,virc}.
New symlinks point to original files in /etc.
---
src/os_unix.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/os_unix.h b/src/os_unix.h
index 00ae239..a0c9485 100644
--- a/src/os_unix.h
+++ b/src/os_unix.h
@@ -217,10 +217,10 @@ typedef struct dsc$descriptor DESC;
* Unix system-dependent file names
*/
#ifndef SYS_VIMRC_FILE
-# define SYS_VIMRC_FILE "$VIM/vimrc"
+# define SYS_VIMRC_FILE "/etc/vimrc"
#endif
#ifndef SYS_GVIMRC_FILE
-# define SYS_GVIMRC_FILE "$VIM/gvimrc"
+# define SYS_GVIMRC_FILE "/etc/gvimrc"
#endif
#ifndef DFLT_HELPFILE
# define DFLT_HELPFILE "$VIMRUNTIME/doc/help.txt"
--
2.27.0

View File

@ -14,7 +14,7 @@
Name: vim
Epoch: 2
Version: %{baseversion}.%{patchlevel}
Release: 3
Release: 4
Summary: Vim is a highly configurable text editor for efficiently creating and changing any kind of text.
License: Vim and MIT
URL: http://www.vim.org
@ -39,6 +39,7 @@ Patch6005: backport-patch-9.0.2112-overflow-in-shift_line.patch
Patch6006: backport-patch-9.0.2114-overflow-detection-not-accurate-when-adding.patch
Patch6007: backport-patch-9.0.2121-use-after-free-in-ex_substitute.patch
Patch6008: backport-patch-9.0.2123-Problem-with-initializing-the-length-of-range-lists.patch
Patch6009: backport-vim-7.0-rclocation.patch
Patch9000: bugfix-rm-modify-info-version.patch
@ -446,6 +447,12 @@ LC_ALL=en_US.UTF-8 make -j1 test || echo "Warning: Please check tests."
%{_mandir}/man1/evim.*
%changelog
* Fri Jul 5 2024 Han Jinpeng <hanjinpeng@kylinos.cn> - 2:9.0.2092-4
- Type:bugfix
- ID:NA
- SUG:NA
- DESC: backport patch, so that vim reads /etc/vimrc at startup
* Sat May 11 2024 wangjiang <wangjiang37@h-partners.com> - 2:9.0.2092-3
- Type:bugfix
- ID:NA