Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RFC] Smarter package management #1293

Open
Jint-lzxy opened this issue Jun 17, 2024 · 7 comments
Open

[RFC] Smarter package management #1293

Jint-lzxy opened this issue Jun 17, 2024 · 7 comments
Labels
complexity:high High-risk, potential for delicate/cascading effects enhancement New feature or request help wanted Extra attention is needed packaging Lazy.nvim or mason.nvim related issues

Comments

@Jint-lzxy
Copy link
Collaborator

Feature description

As briefly discussed in #1252, there are several cases where Mason is simply dead and can't be used at all. My specific situation is that most of the pre-built binaries can't run on FreeBSD (of course), and Linux-emulation mode doesn't really help either. I need to constantly symlink the "correct" executables to Mason's bin directory to make things work, but that's laborious, and I really don't wanna do that anymore. imo we need a way to either bypass Mason completely or make it optional for OSs like NixOS and the BSDs.

Additional information

No response

@Jint-lzxy Jint-lzxy added enhancement New feature or request help wanted Extra attention is needed complexity:high High-risk, potential for delicate/cascading effects packaging Lazy.nvim or mason.nvim related issues labels Jun 17, 2024
@vollowx
Copy link

vollowx commented Jun 18, 2024

The LSP servers, linters and formatters can actually be installed in system-wide on most systems, which means they are executable everywhere and maybe we just don't need mason at all?

@Jint-lzxy Jint-lzxy changed the title Smarter package management [RFC] Smarter package management Jun 19, 2024
@Jint-lzxy
Copy link
Collaborator Author

The LSP servers, linters and formatters can actually be installed in system-wide on most systems, which means they are executable everywhere and maybe we just don't need mason at all?

Exactly! Initially, I was thinking of completely removing Mason, but without it, we'd lose the ability to automatically install those dependencies on a freshly installed system, which is kinda like the two sides of the same coin lol

@vollowx
Copy link

vollowx commented Jun 19, 2024

Maybe ask user whether to install stuffs manually or by mason, store the choice and enable mason if that is true ?

@Jint-lzxy
Copy link
Collaborator Author

Maybe ask user whether to install stuffs manually or by mason, store the choice and enable mason if that is true?

Yeah that's what I meant by "optional," but ideally, I'd like to find a way to automatically bypass Mason without any user interaction. In my case, I'd love Mason to be available on my Mac, but to be automatically disabled on my FreeBSD workstation. Especially in jails when I'm doing certain experimentation, I certainly don't wanna specify that option manually lmao

@CharlesChiuGit
Copy link
Collaborator

CharlesChiuGit commented Jun 19, 2024

In my case, I'd love Mason to be available on my Mac, but to be automatically disabled on my FreeBSD workstation.

Maybe we can add an option as "platform" in our custom lazy.nvim loader and utilized the enabled flag in lazy.nvim?
If platform = {"XXX OS" = false} is not set, then it will default to install the plugin on whatever OS it's on.
I personally would like to disable sniprun on windows since it could not be installed on windows lol

https://github.com/folke/lazy.nvim?tab=readme-ov-file#-plugin-spec

@Jint-lzxy
Copy link
Collaborator Author

Maybe we can add an option as "platform" in our custom lazy.nvim loader and utilized the enabled flag in lazy.nvim? If platform = {"XXX OS" = false} is not set, then it will default to install the plugin on whatever OS it's on. I personally would like to disable sniprun on windows since it could not be installed on windows lol

lol that's a great idea! Tho we'll need a way to automatically register those sources with lspconfig/none-ls/dap then.

@Jint-lzxy
Copy link
Collaborator Author

After some consideration, I've decided to create a plugin that automates the control of those "bridging plugins" (like mason-null-ls.nvim). I'll share the link to the Reddit post here once it's completed lol

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
complexity:high High-risk, potential for delicate/cascading effects enhancement New feature or request help wanted Extra attention is needed packaging Lazy.nvim or mason.nvim related issues
Projects
None yet
Development

No branches or pull requests

3 participants