Package: vim-addon-manager
Version: 0.4.2
Severity: important
Tags: patch
Hi!
If I try to remove any system-wide installed vim addon as root, I get the
following error message:
$ vim-addons -w install latex-suite
$ vim-addons -w remove latex-suite
Info: removing broken addon 'latex-suite' from /var/lib/vim/addons
/usr/lib/ruby/1.8/fileutils.rb:264:in `rmdir': Invalid argument -
/var/lib/vim/addons/. (Errno::EINVAL)
from /usr/lib/ruby/1.8/fileutils.rb:264:in `rmdir'
from /usr/lib/ruby/1.8/fileutils.rb:263:in `each'
from /usr/lib/ruby/1.8/fileutils.rb:263:in `rmdir'
from /usr/lib/ruby/1.8/vim/addon-manager.rb:67:in `remove'
from /usr/lib/ruby/1.8/set.rb:194:in `each'
from /usr/lib/ruby/1.8/set.rb:194:in `each_key'
from /usr/lib/ruby/1.8/set.rb:194:in `each'
from /usr/lib/ruby/1.8/vim/addon-manager.rb:84:in `remove'
from /usr/lib/ruby/1.8/vim/addon-manager.rb:74:in `each'
from /usr/lib/ruby/1.8/vim/addon-manager.rb:74:in `remove'
from /usr/bin/vim-addons:264:in `send'
from /usr/bin/vim-addons:264
The attached patch does not solve this problem, but is just a small workaround.
-- System Information:
Debian Release: squeeze/sid
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: i386 (i686)
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages vim-addon-manager depends on:
ii ruby 4.2 An interpreter of object-oriented
ii vim-common 2:7.2.330-1 Vi IMproved - Common files
Versions of packages vim-addon-manager recommends:
ii vim 2:7.2.330-1 Vi IMproved - enhanced vi editor
ii vim-gnome [vim] 2:7.2.330-1 Vi IMproved - enhanced vi editor -
ii vim-nox [vim] 2:7.2.330-1 Vi IMproved - enhanced vi editor
vim-addon-manager suggests no packages.
-- no debconf information
--- a/src/vim/addon-manager.rb 2010-01-21 01:23:20.000000000 +0100
+++ b/src/vim/addon-manager.rb 2010-01-21 22:07:50.000000000 +0100
@@ -65,6 +65,8 @@
while paths.size
begin
FileUtils.rmdir(File.join(@target_dir, paths))
+ rescue Errno::EINVAL
+ Vim.warn "Can not delete #...@target_dir}: " + $!
rescue Errno::ENOTEMPTY
break
end