4

I just downloaded and installed vim-addon-manager using sudo apt-get install. I'm not sure what to do next, I entered vim-addon-manager at the bash prompt (Ubuntu 14.04). Here is the output:

~$ vim-addon-manager
# Name                     User Status  System Status 
align                       removed       removed       
alternate                   removed       removed       
bufexplorer                 removed       removed       
calendar                    removed       removed       
closetag                    removed       removed       
colors-sampler-pack         removed       removed       
cvsmenu                     removed       removed       
debPlugin                   removed       removed       
detectindent                removed       removed       
doxygen-toolkit             removed       removed       
editexisting                removed       removed       
enhanced-commentify         removed       removed       
gnupg                       removed       removed       
info                        removed       removed       
justify                     removed       removed       
lbdbq                       removed       removed       
matchit                     removed       removed       
minibufexplorer             removed       removed       
nerd-commenter              removed       removed       
omnicppcomplete             removed       removed       
po                          removed       removed       
project                     removed       removed       
python-indent               removed       removed       
secure-modelines            removed       removed       
snippetsEmu                 removed       removed       
sokoban                     removed       removed       
supertab                    removed       removed       
surround                    removed       removed       
taglist                     removed       removed       
tetris                      removed       removed       
utl                         removed       removed       
vcscommand                  removed       removed       
vimplate                    removed       removed       
whatdomain                  removed       removed       
winmanager                  removed       removed       
xmledit                     removed       removed  
~$

I don't think these are the results that I want.

This started because I was trying to install something called nibble, and it doesn't look like this is it. Actually at this point I would settle for anything fun. Being unfamiliar with vi/vim's plugin system. I have looked at the man pages but I'm still at a loss where to begin.

I could really use the steps spelled out for me. Thanks!

  • 1
    Did you look at the man page or the --help output? – jamessan Apr 7 '16 at 14:26
  • Yes. Still not sure where to start. Also modified the question somewhat. – gracious1 Apr 7 '16 at 14:29
  • 1
    This nibble? vi.stackexchange.com/a/7123/205 – muru Apr 7 '16 at 15:27
  • 1
    1. Why did you install that thing? 2. How is that linked in any way with that silly plugin? 3. Why did you install it without reading up on it? 4. Vi doesn't have a plugin system. 5. What is your ultimate goal? – romainl Apr 7 '16 at 15:39
  • 2
    I've never used this package, but if you're new to Vim I would recommend that you read this question about (good) plugin managers. Most of them are linked to their github repo containing a simple installation procedure. For example with Vim-plug you just have to do a curl, add two lines to your .vimrc and you're ready to have fun with plugins :-) – statox Apr 7 '16 at 15:42
5

Disclaimer This answer contains comments that are based on my experience and on the opinion that I got with the time, it might not be universal. I wrote this answer with keeping in mind the experience of a new Vim user.


EDIT The package vim-addon-manager installed by OP is a command-line plugin manager that you run outside of Vim. It was created to install plugin packaged as debian packages (See this question about its creation). It is pretty useful to solve some specific problems but it is less flexible than others plugin managers which directly fetch plugin from github or other sources.

I think that to let a new comer achieve the goal stated by the question the package is not the easiest tool to use, that is why I made this answer detailing an easy way to install new plugins.

Now if I understood correctly the documentation of the package and OP really wants to use it:

  • To install a new plugin with vim-addon-manager, the user should use vim-addons install <plugin> with <plugin> being one of the entries shown by the command vim-addon.
  • As the nibble requested by OP is not in the list posted in the question, it will be necessary to package the plugin as a debian package and I think the instructions to do so are beyond the scope of this site.

I have tested several plugin managers but never vim-addon-manager. The main reason is because the minimum configuration that you need to make it work seems a little bit too long and messy for me and thus not adapted for a new comer to Vim. Also several opinions in this reddit thread made me think that it wasn't for me.

I think that if you're a new user who just want to easily and quickly get ready to discover the power of Vim plugins, you should choose another plugin manager and I would strongly recommend Vim-plug for its ease of use and its power. (Of course one can always argue for another plugin manager, I choose to use this one in this answer to provide a minimal and easy set of instructions to get ready to use a plugin)

As you was mentioning apt-get I assume that you are on a Unix system, so this installation process is pretty straight-forward:

  • First in your favorite terminal use this command:

    curl -fLo ~/.vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
    

    It will automatically download the plugin manager and put it in the right place so you'll be able to use it right after the download.

  • Once the download is over, simply add theses lines in your .vimrc (If you don't have a .vimrc file you can simply create it:

    touch ~/.vimrc
    

    In this file you'll need to add the following lines to be able to start adding new plugins:

    call plug#begin('~/.vim/plugged')
    " You'll replace this line with your plugin installations
    call plug#end()
    
  • You're now ready to install new plugins. To do so, find a github repo of your plugin: if you wanted a nibble you can look at this repo. To install a plugin from github you'll have to add a line like the following one in your .vimrc between the lines call plug#begin('~/.vim/plugged') and call plug#end():

    Plug 'username/repo-name'
    

    (The username/repo-name are the end of the github url and can also be found on the top of the github webpage of the repo)

    For the nibble I linked you'll have to write 2 lines because the plugin has a dependecy:

    Plug 'vim-scripts/Nibble'
    Plug 'vim-scripts/genutils'
    
  • Remember to save your .vimrc with its new lines with :w (Press on : to enter the command mode, write w and validate with enter) and to source it so Vim is aware that you added new lines: :source $MYVIMRC

  • Now comes the final step: tell to Vim-plug to fetch the source files of the plugin and install it. To do so in Vim simply use the command :PlugInstall

    A new window with a buffer will appear showing you the progress of the install process. Once it's done you can close this buffer with :bd and you're ready to use your plugins.

  • You can then use the command :Nibble and start enjoying your game.

As I said Vim-plug is a pretty easy to use and still powerful plugin manager, use it for a while learn how to use it and then when you'll be comfortable enough with it, give another try to vim-addon-manager if you really feel like it.

  • I believe the OP has been using vim-addon-manager from debian which is different from Marc Webers VAM (vim-addon-manager) – Christian Brabandt Apr 8 '16 at 11:01
  • @ChristianBrabandt is correct. However, I never quite figured out how to actually use it. Not familiar with curl, not installed on my system. Willing to do so, just wondering is there a reason that is preferable to apt-get? – gracious1 Apr 8 '16 at 11:57
  • Should clarify I am assuming that it is debian too given the repositories I have installed on my Ubuntu system. – gracious1 Apr 8 '16 at 12:04
  • I understood that OP wanted to install this package but I was sure that this package was just an external plugin manager (since the presentation says install or uninstall each of [the addons] in [the user] configuration directory (~/.vim)). Also as OP said he wanted to install nibble I thought that he was simply not using the appropriate tool. My bad if I didn't understood the question correctly. – statox Apr 8 '16 at 12:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.