Using `--noplugin` fails to suppress package under `~/.vim/pack/...`

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Using `--noplugin` fails to suppress package under `~/.vim/pack/...`

Timothy Rice
Hi there,

Sorry if this is a duplicate, I tried sending to `[hidden email]` but I think
that address is incorrect?

Anyway, I have encountered some unexpected behaviour when using the
`--noplugin` option. Namely, it does not seem to suppress packages
installed under `~/.vim/pack/...`

I have attached my Vim version information. My Vim configuration is stored
at https://github.com/cryptarch/vimfiles.git

Specific steps to reproduce the behaviour I am seeing:

  $ mkdir -pv ~/.vim/pack/git-plugins/start
  $ cd ~/.vim/pack/git-plugins/start
  $ git clone https://github.com/w0rp/ale.git   # A linting plugin
  $ cd /tmp
  $ cat > ./main.c << EOF
  int main(int* argc, char** argv) { /* Note error in first argument */
    return 0;
  }
  EOF
  $ vim --noplugin ./main.c    # ALE still reports error on first line.

Is there something I might have misconfigured? Am I using the new plugin
system incorrectly?

Thanks for your time :)


~ Tim

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

vim-version.txt (4K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Using `--noplugin` fails to suppress package under `~/.vim/pack/...`

Ben Fritz
On Sunday, December 31, 2017 at 4:10:51 AM UTC-6, Tim Rice wrote:

> Hi there,
>
> Sorry if this is a duplicate, I tried sending to `[hidden email]` but I think
> that address is incorrect?
>
> Anyway, I have encountered some unexpected behaviour when using the
> `--noplugin` option. Namely, it does not seem to suppress packages
> installed under `~/.vim/pack/...`
>
> I have attached my Vim version information. My Vim configuration is stored
> at https://github.com/cryptarch/vimfiles.git
>
> Specific steps to reproduce the behaviour I am seeing:
>
>   $ mkdir -pv ~/.vim/pack/git-plugins/start
>   $ cd ~/.vim/pack/git-plugins/start
>   $ git clone https://github.com/w0rp/ale.git   # A linting plugin
>   $ cd /tmp
>   $ cat > ./main.c << EOF
>   int main(int* argc, char** argv) { /* Note error in first argument */
>     return 0;
>   }
>   EOF
>   $ vim --noplugin ./main.c    # ALE still reports error on first line.
>
> Is there something I might have misconfigured? Am I using the new plugin
> system incorrectly?
>
> Thanks for your time :)
>
>
> ~ Tim
It looks at first glance that ALE is (at least partially) a filetype plugin. That is, it has components that are activated for certain filetypes when you edit a file of that type.

The --noplugin option does not prevent filetype plugins from working. It only prevents the plugins loaded on every Vim startup from loading (files in a "plugin" folder). In your .vimrc, you have "filetype plugin on" which enables the filetype plugins.

If you don't want to load filetype plugins, remove that line from your .vimrc.

I'm not sure if it would work (it has potential to have side effects you may not expect and I've never seen it suggested before), but a possible way to let this work as you expected, would be to move "filetype plugin on" from your .vimrc to a file in a plugin directory instead.

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Using `--noplugin` fails to suppress package under `~/.vim/pack/...`

Timothy Rice
Hi Ben,

> It looks at first glance that ALE is (at least partially) a filetype plugin. That is, it has components that are activated for certain filetypes when you edit a file of that type.
>
> The --noplugin option does not prevent filetype plugins from working. It only prevents the plugins loaded on every Vim startup from loading (files in a "plugin" folder). In your .vimrc, you have "filetype plugin on" which enables the filetype plugins.
>
> If you don't want to load filetype plugins, remove that line from your .vimrc.
>
> I'm not sure if it would work (it has potential to have side effects you may not expect and I've never seen it suggested before), but a possible way to let this work as you expected, would be to move "filetype plugin on" from your .vimrc to a file in a plugin directory instead.

Ah, this makes sense. Thanks very much for the reply. I'm not sure whether
or not I will use your suggestion, but at least now I know what is going
on :)

~ Tim

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.