Comments (6)
Hello! Cool! Pull requests are always very welcomed to add new packages. If the distribution of the
package is simple, the installation will most likely be so as well (existing package installers may be
used for reference!). Otherwise, @williamboman will get around to looking into this ASAP!
from mason.nvim.
Has this been worked on yet? I need to use Prolog for a College class and I want to use my neovim setup. Can I take this on? @williamboman
from mason.nvim.
@Spaceface16518 I don't know exactly how to tackle this issue.
The way I use to get linting is running
:lua vim.lsp.start { name = 'prolog_lsp', cmd = { 'swipl', '-g', 'use_module(library(lsp_server))', '-g', 'lsp_server:main', '-t', 'halt', '--', 'stdio' } }
Currently I'm not sure of the existence of some autocompletion engine for Prolog
from mason.nvim.
I'd be fine with just linting, maybe with snippets from luasnip or something. Do we discourage adding an lsp server to Mason if it doesn't include proper autocomplete yet?
from mason.nvim.
Has this been worked on yet? I need to use Prolog for a College class and I want to use my neovim setup. Can I take this on? @williamboman
Sure! I see that it's distributed as a SWI-Prolog package, for which there is no manager yet in Mason, so adding this would require some extra additional work (see for example lua/mason-core/managers/npm/init.lua
). A requirement for a "manager" to be supported is that it can ensure that installations can be done entirely locally in a directory managed by Mason - a quick look into pack_install/2
suggests that this is possible.
I'm currently working on migrating things to https://github.com/mason-org/mason-registry, so any new managers and whatnot will need to be ported to a completely new implementation, but that's fine and I'd be happy to do that should it be needed.
from mason.nvim.
This module implements code completion, based on defined predicates in the file & imports.
I just checked and we get auto-completion only for rules defined in the document with the following snippet
require 'lspconfig.configs'['prolog_lsp'] = {
default_config = {
cmd = {
'swipl',
'-g', 'use_module(library(lsp_server)).',
'-g', 'lsp_server:main',
'-t', 'halt',
'--', 'stdio'
},
filetypes = { 'prolog' },
root_dir = require 'lspconfig.util'.root_pattern('pack.pl')
},
docs = {
description = [[
https://github.com/jamesnvc/prolog_lsp
Prolog Language Server
]]
}
}
require 'lspconfig'['prolog_lsp'].setup {}
The tricky part
I'm not sure how could I import the built-in predicated into the LSP scope so that one would get auto-completion when typing, for example, findall
.
It would be nice to have mainly for mason-lspconfig
.
Any idea is appreciated.
from mason.nvim.
Related Issues (20)
- golang packages unable to install HOT 1
- Mason installs x86_64 but should install ARM build HOT 1
- Mason nvim core utils broken HOT 18
- Mason is not updating on nightly HOT 4
- Registry installation failed (failed to fetch latest registry version from GitHub API) HOT 3
- Add hyprls HOT 3
- bad CPU type in executable: selene HOT 5
- [New package]: Terramate-ls HOT 1
- Failed to update registries HOT 1
- LSP components are not loaded through the proxy specified in the configuration HOT 2
- [New package]: autocorrect HOT 2
- Lockfile or ability to freeze a certain package version HOT 2
- Deprecation of vim.tbl_xx functions trigger errors in latest Neovim versions
- Support ensure_installed directly in mason
- Update core utils to have version requirements [wget]
- Mason command is not working HOT 3
- LemMinX on x86_64 Linux HOT 3
- [New package]: Native rust ruff LSP HOT 2
- Couldn't install luacheck, linking issue HOT 2
- Mason won't install Ltex-ls
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mason.nvim.