Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Vim : Can't open file /usr/share/vim/vim82/syntax/syntax.vim
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index French
View previous topic :: View next topic  
Author Message
y351
Apprentice
Apprentice


Joined: 21 May 2017
Posts: 195

PostPosted: Thu Aug 18, 2022 2:49 pm    Post subject: Vim : Can't open file /usr/share/vim/vim82/syntax/syntax.vim Reply with quote

Bonjour,

J'ai un souci après une màj de vim quand j'ouvre un fichier en tant que root.
Je n'ai pas de fichier ~/.vimrc sur le profile de l'utilisateur root.
Quote:

Error detected while processing /etc/vim/vimrc:
line 92:
E484: Can't open file /usr/share/vim/vim82/syntax/syntax.vim
Press ENTER or type command to continue


Code:
ll /usr/share/vim/vim82/syntax/syntax.vim

Quote:

ls: cannot access '/usr/share/vim/vim82/syntax/syntax.vim': No such file or directory

Code:
ll /usr/share/vim/

Quote:

total 0
drwxr-xr-x. 1 root root 580 16 août 18:42 vim90
drwxr-xr-x. 1 root root 104 10 mai 13:17 vimfiles


Code:
vim --version

Quote:

VIM - Vi IMproved 9.0 (2022 Jun 28, compiled Aug 16 2022 18:44:52)
Included patches: 1-99
Modified by Gentoo-9.0.0099
Compiled by toto@localhost
Huge version without GUI. Features included (+) or not (-):
+acl +file_in_path +mouse_urxvt -tag_any_white
+arabic +find_in_path +mouse_xterm -tcl
+autocmd +float +multi_byte +termguicolors
+autochdir +folding +multi_lang -terminal
-autoservername -footer -mzscheme +terminfo
-balloon_eval +fork() +netbeans_intg +termresponse
+balloon_eval_term +gettext +num64 +textobjects
-browse -hangul_input +packages +textprop
++builtin_terms +iconv +path_extra +timers
+byte_offset +insert_expand +perl +title
+channel +ipv6 +persistent_undo -toolbar
+cindent +job +popupwin +user_commands
+clientserver +jumplist +postscript +vartabs
+clipboard +keymap +printer +vertsplit
+cmdline_compl +lambda +profile +vim9script
+cmdline_hist +langmap -python +viminfo
+cmdline_info +libcall +python3 +virtualedit
+comments +linebreak +quickfix +visual
+conceal +lispindent +reltime +visualextra
+cryptv +listcmds +rightleft +vreplace
-cscope +localmap -ruby +wildignore
+cursorbind -lua +scrollbind +wildmenu
+cursorshape +menu +signs +windows
+dialog_con +mksession +smartindent +writebackup
+diff +modify_fname +sodium +X11
+digraphs +mouse -sound +xfontset
-dnd -mouseshape +spell -xim
-ebcdic +mouse_dec +startuptime -xpm
+emacs_tags -mouse_gpm +statusline +xsmp_interact
+eval -mouse_jsbterm -sun_workshop +xterm_clipboard
+ex_extra +mouse_netterm +syntax -xterm_save
+extra_search +mouse_sgr +tag_binary
-farsi -mouse_sysmouse -tag_old_static
system vimrc file: "/etc/vim/vimrc"
user vimrc file: "$HOME/.vimrc"
2nd user vimrc file: "~/.vim/vimrc"
user exrc file: "$HOME/.exrc"
defaults file: "$VIMRUNTIME/defaults.vim"
fall-back for $VIM: "/usr/share/vim"
Compilation: x86_64-pc-linux-gnu-gcc -c -I. -Iproto -DHAVE_CONFIG_H -march=skylake -O2 -fforce-addr -pipe -D_REENTRANT -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: x86_64-pc-linux-gnu-gcc -Wl,-E -Wl,-O1 -Wl,--as-needed -L/usr/local/lib -o vim -lSM -lICE -lXpm -lXt -lX11 -lXdmcp -lSM -lICE -lm -ltinfo -lelf -lselinux -lsodium -lrt -lacl -lattr -Wl,-E -Wl,-O1 -Wl,--as-needed -L/usr/lib64/perl5/5.34/x86_64-linux/CORE -lperl -ldl -lm -lcrypt -lutil -lc -lpython3.10 -ldl -lm -lm


J'avais fait un lien pour ce même soucis auparavant.
Mais je souhaiterais le résoudre définitivement.

Tout retour serait apprécié.
Back to top
View user's profile Send private message
ghoti
Advocate
Advocate


Joined: 30 Dec 2002
Posts: 3634
Location: Belgium

PostPosted: Thu Aug 18, 2022 3:54 pm    Post subject: Reply with quote

Hello,
Ton fichier de config fait référence à une ancienne version de vim.
Un petit dispatch-conf, peut-être ?
Back to top
View user's profile Send private message
y351
Apprentice
Apprentice


Joined: 21 May 2017
Posts: 195

PostPosted: Thu Aug 18, 2022 4:02 pm    Post subject: Reply with quote

ghoti wrote:
Hello,
Ton fichier de config fait référence à une ancienne version de vim.
Un petit dispatch-conf, peut-être ?

Bonjour,

Il n'y a pas de fichiers en attente pour une màj.
Back to top
View user's profile Send private message
netfab
Veteran
Veteran


Joined: 03 Mar 2005
Posts: 1897
Location: 127.0.0.1

PostPosted: Thu Aug 18, 2022 7:09 pm    Post subject: Reply with quote

Salut,

Essaye ceci alors pour forcer la réinstallation du fichier de configuration de vim dans /etc :
Code:

# emerge -av1 --noconfmem app-editors/vim-core
Back to top
View user's profile Send private message
ghoti
Advocate
Advocate


Joined: 30 Dec 2002
Posts: 3634
Location: Belgium

PostPosted: Thu Aug 18, 2022 10:15 pm    Post subject: Reply with quote

Le chemin /usr/share/vim/vimXX figure dans la variable VIM $VIMRUNTIME.
En principe, l'utilisateur ne doit pas définir cette variable, VIM la (re)crée tout seul lors de chaque démarrage.
Par contre, si l'utilisateur la définit, par exemple, en l'exportant comme variable d'environnement, VIM conserve cette valeur et ne cherche pas à corriger.

Tu peux vérifier dans un shell :
Code:
printenv VIMRUNTIME    ==> affiche sa valeur si définie
export -n VIMRUNTIME      ==> pour "oublier" la variable
VIM
:echo $VIMRUNTIME    ==> valeur définie automatiquement par VIM

Reste à trouver où tu as bien pu "fixer" cette valeur dans le passé.
Tu sembles dire que c'est uniquement pour root ? ~/.bashrc ?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index French All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum