107 lines
3.4 KiB
Lua
107 lines
3.4 KiB
Lua
|
local TOOLCHAINS = {}
|
||
|
|
||
|
local config = require('toolchain.config')
|
||
|
local database = require('toolchain.database')
|
||
|
local frontend = require('toolchain.frontend')
|
||
|
local generic = require('toolchain.generic')
|
||
|
local git = require('toolchain.git')
|
||
|
local go = require('toolchain.go')
|
||
|
local lua = require('toolchain.lua')
|
||
|
local php = require('toolchain.php')
|
||
|
local scripts = require('toolchain.scripts')
|
||
|
local text = require('toolchain.text')
|
||
|
local web = require('toolchain.web')
|
||
|
|
||
|
TOOLCHAINS.plugins = {
|
||
|
table.unpack(config.requirements.plugins),
|
||
|
table.unpack(database.requirements.plugins),
|
||
|
table.unpack(frontend.requirements.plugins),
|
||
|
table.unpack(generic.requirements.plugins),
|
||
|
table.unpack(git.requirements.plugins),
|
||
|
table.unpack(go.requirements.plugins),
|
||
|
table.unpack(lua.requirements.plugins),
|
||
|
table.unpack(php.requirements.plugins),
|
||
|
table.unpack(scripts.requirements.plugins),
|
||
|
table.unpack(text.requirements.plugins),
|
||
|
table.unpack(web.requirements.plugins),
|
||
|
}
|
||
|
|
||
|
TOOLCHAINS.highlighters = {
|
||
|
table.unpack(config.requirements.highlighters),
|
||
|
table.unpack(database.requirements.highlighters),
|
||
|
table.unpack(frontend.requirements.highlighters),
|
||
|
table.unpack(generic.requirements.highlighters),
|
||
|
table.unpack(git.requirements.highlighters),
|
||
|
table.unpack(go.requirements.highlighters),
|
||
|
table.unpack(lua.requirements.highlighters),
|
||
|
table.unpack(php.requirements.highlighters),
|
||
|
table.unpack(scripts.requirements.highlighters),
|
||
|
table.unpack(text.requirements.highlighters),
|
||
|
table.unpack(web.requirements.highlighters),
|
||
|
}
|
||
|
|
||
|
TOOLCHAINS.language_servers = {
|
||
|
table.unpack(config.language_servers),
|
||
|
table.unpack(database.language_servers),
|
||
|
table.unpack(frontend.language_servers),
|
||
|
table.unpack(generic.language_servers),
|
||
|
table.unpack(git.language_servers),
|
||
|
table.unpack(go.language_servers),
|
||
|
table.unpack(lua.language_servers),
|
||
|
table.unpack(php.language_servers),
|
||
|
table.unpack(scripts.language_servers),
|
||
|
table.unpack(text.language_servers),
|
||
|
table.unpack(web.language_servers),
|
||
|
}
|
||
|
|
||
|
TOOLCHAINS.diagnostics = {
|
||
|
table.unpack(config.diagnostics),
|
||
|
table.unpack(database.diagnostics),
|
||
|
table.unpack(frontend.diagnostics),
|
||
|
table.unpack(generic.diagnostics),
|
||
|
table.unpack(git.diagnostics),
|
||
|
table.unpack(go.diagnostics),
|
||
|
table.unpack(lua.diagnostics),
|
||
|
table.unpack(php.diagnostics),
|
||
|
table.unpack(scripts.diagnostics),
|
||
|
table.unpack(text.diagnostics),
|
||
|
table.unpack(web.diagnostics),
|
||
|
}
|
||
|
|
||
|
return TOOLCHAINS
|
||
|
|
||
|
--Type Definitions
|
||
|
|
||
|
---@class Toolchain
|
||
|
---@field requirements ToolchainRequirements
|
||
|
---@field formatters ToolchainFormatters
|
||
|
---@field language_servers ToolchainLanguageServers
|
||
|
---@field actions ToolchainActions
|
||
|
---@field diagnostics ToolchainDiagnostics
|
||
|
---@field debuggers ToolchainDebuggers
|
||
|
|
||
|
---@class ToolchainRequirements
|
||
|
---@field plugins LazySpec[]
|
||
|
---@field highlighters table
|
||
|
---@field language_servers table
|
||
|
|
||
|
---@class ToolchainLanguageServers
|
||
|
---@field requirements string[]
|
||
|
---@field setup fun(lspconfig:any, capabilities: any)
|
||
|
|
||
|
---@class ToolchainFormatters
|
||
|
---@field plugins LazySpec[]
|
||
|
---@field setup fun(null_ls: any):table
|
||
|
|
||
|
---@class ToolchainActions
|
||
|
---@field plugins LazySpec[]
|
||
|
---@field setup fun(null_ls: any):table
|
||
|
|
||
|
---@class ToolchainDiagnostics
|
||
|
---@field plugins LazySpec[]
|
||
|
---@field setup fun(null_ls: any):table
|
||
|
|
||
|
---@class ToolchainDebuggers
|
||
|
---@field plugins LazySpec[]
|
||
|
|