Giter Site home page Giter Site logo

Install local `paq` plugins? about paq-nvim HOT 7 CLOSED

savq avatar savq commented on August 16, 2024
Install local `paq` plugins?

from paq-nvim.

Comments (7)

savq avatar savq commented on August 16, 2024 2

You can change the directory where Paq downloads stuff with the setup function, but that won't change neovim's runtime path.

Under.local/site/nvim/pack, I keep three directories:

  • paqs, the usual paq-directory
  • local, where I put the plugins I develop
  • test, where Paq puts plugins when running the "test" suite

I have my term-multiplexer set-up so I can open new a terminal in .local/site/nvim/pack/local/start, and get to work quickly.

The only risk with putting your plugin in paqs is that if it isn't listed in your config, Paq will delete it. Once I accidentally let Paq delete itself that way, without pushing the latest commits, true story. 🤦‍♂️

from paq-nvim.

aca avatar aca commented on August 16, 2024 1

+1 for something like paq '~/vim/personal'
Maybe can we just create symbolic link when local filesystem is used?

Paq is best plugin manager. Thanks @savq

from paq-nvim.

savq avatar savq commented on August 16, 2024 1

I was a bit busy when I wrote the first answer so that was phrased wrong.

My point was that Paq doesn't modify the runtimepath, and that neovim has easier ways to track a local plugin, namely:

  • Add it to a directory in packpath (different from the one Paq uses)
  • Modify the runtimepath directly

I sorta explained the first option in the first comment (at least how I use it), but honestly, the best way to understand is to read :h packages.

The alternative, just requires you to concatenate the path to the plugin to your runtimepath:

vim.o.runtimepath = vim.o.runtimepath .. ",~/vim/personal"

Yes, it looks clunky because Lua doesn't have a concat-assignment operator (you can write it in VimL if you prefer), but it is a one liner solution that doesn't require adding anything to Paq.


Paq is best plugin manager. Thanks @savq

I wish. Thank you for using it 😄

from paq-nvim.

savq avatar savq commented on August 16, 2024 1

I've added this to the docs. Gotta keep that readme lean.

from paq-nvim.

megalithic avatar megalithic commented on August 16, 2024

👍 to this idea.

from paq-nvim.

megalithic avatar megalithic commented on August 16, 2024

Thank you so much @savq !! Learned a lot with this!

from paq-nvim.

megalithic avatar megalithic commented on August 16, 2024

@savq it might be worth adding a small blurb to this explanation you gave on the readme.

from paq-nvim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.