mirror of
https://github.com/pojokcodeid/nvim-lazy.git
synced 2025-06-21 08:35:48 +02:00
enc: testing kotlin on windows
This commit is contained in:
parent
ef6ac90acf
commit
1d622094b9
5 changed files with 31 additions and 19 deletions
|
@ -12,6 +12,7 @@
|
||||||
"cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" },
|
"cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" },
|
||||||
"code_runner.nvim": { "branch": "main", "commit": "6c5bfe44a6c7523350cd706e6b3b8101166eed99" },
|
"code_runner.nvim": { "branch": "main", "commit": "6c5bfe44a6c7523350cd706e6b3b8101166eed99" },
|
||||||
"codeium.nvim": { "branch": "main", "commit": "d3b88eb3aa1de6da33d325c196b8a41da2bcc825" },
|
"codeium.nvim": { "branch": "main", "commit": "d3b88eb3aa1de6da33d325c196b8a41da2bcc825" },
|
||||||
|
"conform.nvim": { "branch": "master", "commit": "60e6fbddbdf37d7790de07dc7420beefaf650e5e" },
|
||||||
"dracula.nvim": { "branch": "main", "commit": "8d8bddb8814c3e7e62d80dda65a9876f97eb699c" },
|
"dracula.nvim": { "branch": "main", "commit": "8d8bddb8814c3e7e62d80dda65a9876f97eb699c" },
|
||||||
"dressing.nvim": { "branch": "master", "commit": "71349f24c6e07b39f33600985843c289ca735308" },
|
"dressing.nvim": { "branch": "master", "commit": "71349f24c6e07b39f33600985843c289ca735308" },
|
||||||
"friendly-snippets": { "branch": "main", "commit": "682157939e57bd6a2c86277dfd4d6fbfce63dbac" },
|
"friendly-snippets": { "branch": "main", "commit": "682157939e57bd6a2c86277dfd4d6fbfce63dbac" },
|
||||||
|
@ -23,7 +24,7 @@
|
||||||
"lualine.nvim": { "branch": "master", "commit": "0a5a66803c7407767b799067986b4dc3036e1983" },
|
"lualine.nvim": { "branch": "master", "commit": "0a5a66803c7407767b799067986b4dc3036e1983" },
|
||||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "9ae570e206360e47d30b4c35a4550c165f4ea7b7" },
|
"mason-lspconfig.nvim": { "branch": "main", "commit": "9ae570e206360e47d30b4c35a4550c165f4ea7b7" },
|
||||||
"mason-null-ls.nvim": { "branch": "main", "commit": "2b8433f76598397fcc97318d410e0c4f7a4bea6a" },
|
"mason-null-ls.nvim": { "branch": "main", "commit": "2b8433f76598397fcc97318d410e0c4f7a4bea6a" },
|
||||||
"mason-nvim-dap.nvim": { "branch": "main", "commit": "f5425eb1d0d794f0305d5eeebddabb74614683ff" },
|
"mason-nvim-dap.nvim": { "branch": "main", "commit": "4ba55f9755ebe8297d92c419b90a946123292ae6" },
|
||||||
"mason.nvim": { "branch": "main", "commit": "c43eeb5614a09dc17c03a7fb49de2e05de203924" },
|
"mason.nvim": { "branch": "main", "commit": "c43eeb5614a09dc17c03a7fb49de2e05de203924" },
|
||||||
"mini.indentscope": { "branch": "main", "commit": "56d42be090e8fcc68eda69cfe55af8c5e562300e" },
|
"mini.indentscope": { "branch": "main", "commit": "56d42be090e8fcc68eda69cfe55af8c5e562300e" },
|
||||||
"neoscroll.nvim": { "branch": "master", "commit": "a731f66f1d39ec6175fd201c5bf849e54abda99c" },
|
"neoscroll.nvim": { "branch": "master", "commit": "a731f66f1d39ec6175fd201c5bf849e54abda99c" },
|
||||||
|
@ -37,6 +38,7 @@
|
||||||
"nvim-dap": { "branch": "master", "commit": "5ba8ceace596360321cf33fa4b56d9d46e057ce9" },
|
"nvim-dap": { "branch": "master", "commit": "5ba8ceace596360321cf33fa4b56d9d46e057ce9" },
|
||||||
"nvim-dap-ui": { "branch": "master", "commit": "f7d75cca202b52a60c520ec7b1ec3414d6e77b0f" },
|
"nvim-dap-ui": { "branch": "master", "commit": "f7d75cca202b52a60c520ec7b1ec3414d6e77b0f" },
|
||||||
"nvim-dap-virtual-text": { "branch": "master", "commit": "d7c695ea39542f6da94ee4d66176f5d660ab0a77" },
|
"nvim-dap-virtual-text": { "branch": "master", "commit": "d7c695ea39542f6da94ee4d66176f5d660ab0a77" },
|
||||||
|
"nvim-lint": { "branch": "master", "commit": "efc6fc83f0772283e064c53a8f9fb5645bde0bc0" },
|
||||||
"nvim-lspconfig": { "branch": "master", "commit": "0b8165cf95806bc4bb8f745bb0c92021b2ed4b98" },
|
"nvim-lspconfig": { "branch": "master", "commit": "0b8165cf95806bc4bb8f745bb0c92021b2ed4b98" },
|
||||||
"nvim-material-icon": { "branch": "main", "commit": "d8b1564a95330a5bfe5ef38defe99b9c440efe7d" },
|
"nvim-material-icon": { "branch": "main", "commit": "d8b1564a95330a5bfe5ef38defe99b9c440efe7d" },
|
||||||
"nvim-navic": { "branch": "master", "commit": "8649f694d3e76ee10c19255dece6411c29206a54" },
|
"nvim-navic": { "branch": "master", "commit": "8649f694d3e76ee10c19255dece6411c29206a54" },
|
||||||
|
|
|
@ -45,6 +45,7 @@ if disable then
|
||||||
local ignore = {
|
local ignore = {
|
||||||
["php"] = "tlint",
|
["php"] = "tlint",
|
||||||
["lua"] = "ast-grep",
|
["lua"] = "ast-grep",
|
||||||
|
["kotlin"] = "ktlint",
|
||||||
}
|
}
|
||||||
|
|
||||||
for _, pkg in pairs(mason_reg.get_installed_packages()) do
|
for _, pkg in pairs(mason_reg.get_installed_packages()) do
|
||||||
|
@ -70,7 +71,7 @@ if disable then
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
-- local listtest = {}
|
local listtest = {}
|
||||||
-- finally add the formatter to it's compatible filetype(s)
|
-- finally add the formatter to it's compatible filetype(s)
|
||||||
for _, ft in pairs(pkg.spec.languages) do
|
for _, ft in pairs(pkg.spec.languages) do
|
||||||
local ftl = string.lower(ft)
|
local ftl = string.lower(ft)
|
||||||
|
@ -84,9 +85,9 @@ if disable then
|
||||||
pkg.spec.name = name_map[pkg.spec.name]
|
pkg.spec.name = name_map[pkg.spec.name]
|
||||||
end
|
end
|
||||||
|
|
||||||
-- if substring(pkg.spec.name, "prettier") then
|
if substring(pkg.spec.name, "ktfmt") then
|
||||||
-- table.insert(listtest, ftl)
|
table.insert(listtest, ftl)
|
||||||
-- end
|
end
|
||||||
|
|
||||||
-- add new mapping language
|
-- add new mapping language
|
||||||
for key, value in pairs(addnew) do
|
for key, value in pairs(addnew) do
|
||||||
|
@ -102,7 +103,7 @@ if disable then
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
-- print(table.concat(listtest, ","))
|
print(table.concat(listtest, ","))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -108,7 +108,7 @@ if pcode.active_kotlin_config or false then
|
||||||
-- setting cek
|
-- setting cek
|
||||||
-- https://stackoverflow.com/questions/9356543/logging-while-testing-through-gradle
|
-- https://stackoverflow.com/questions/9356543/logging-while-testing-through-gradle
|
||||||
{ "<leader>T", "", desc = " Test" },
|
{ "<leader>T", "", desc = " Test" },
|
||||||
{ "<leader>Ta", "<cmd>terminal ./gradlew test<cr>", desc = "Run All" },
|
{ "<leader>Ta", "<cmd>terminal gradle test<cr>", desc = "Run All" },
|
||||||
{
|
{
|
||||||
"<leader>Tu",
|
"<leader>Tu",
|
||||||
function()
|
function()
|
||||||
|
@ -119,7 +119,8 @@ if pcode.active_kotlin_config or false then
|
||||||
current_word = current_word:gsub("fun", "")
|
current_word = current_word:gsub("fun", "")
|
||||||
current_word = current_word:gsub("%(%)", "")
|
current_word = current_word:gsub("%(%)", "")
|
||||||
current_word = current_word:gsub("{", "")
|
current_word = current_word:gsub("{", "")
|
||||||
vim.cmd("terminal ./gradlew test --tests *." .. all_trim(current_word))
|
current_word = current_word:gsub("@Test", "")
|
||||||
|
vim.cmd("terminal gradle test --tests *." .. all_trim(current_word))
|
||||||
end,
|
end,
|
||||||
desc = "Run Under Cursor",
|
desc = "Run Under Cursor",
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,5 +1,9 @@
|
||||||
local M = {}
|
local M = {}
|
||||||
if not (pcode.disable_null_ls or false) then
|
local disable = pcode.disable_null_ls or false
|
||||||
|
if not require("user.utils.cfgstatus").cheack() then
|
||||||
|
disable = true
|
||||||
|
end
|
||||||
|
if disable then
|
||||||
M = {
|
M = {
|
||||||
{
|
{
|
||||||
"nvimtools/none-ls.nvim",
|
"nvimtools/none-ls.nvim",
|
||||||
|
|
|
@ -1,21 +1,25 @@
|
||||||
local M={}
|
local M = {}
|
||||||
|
|
||||||
M.cheack=function ()
|
M.cheack = function()
|
||||||
local sts= false
|
local sts = false
|
||||||
if pcode.active_javascript_config.active or false then
|
if pcode.active_javascript_config.active or false then
|
||||||
sts=true
|
sts = true
|
||||||
elseif pcode.active_rust_config or false then
|
elseif pcode.active_rust_config or false then
|
||||||
sts=true
|
sts = true
|
||||||
elseif pcode.active_php_config or false then
|
elseif pcode.active_php_config or false then
|
||||||
sts=true
|
sts = true
|
||||||
elseif pcode.active_golang_config or false then
|
elseif pcode.active_golang_config or false then
|
||||||
sts=true
|
sts = true
|
||||||
elseif pcode.active_python_config or false then
|
elseif pcode.active_python_config or false then
|
||||||
sts=true
|
sts = true
|
||||||
elseif pcode.active_cpp_config or false then
|
elseif pcode.active_cpp_config or false then
|
||||||
sts=true
|
sts = true
|
||||||
elseif pcode.active_java_config.active or false then
|
elseif pcode.active_java_config.active or false then
|
||||||
sts=true
|
sts = true
|
||||||
|
elseif pcode.active_deno_config or false then
|
||||||
|
sts = true
|
||||||
|
elseif pcode.active_kotlin_config or false then
|
||||||
|
sts = true
|
||||||
end
|
end
|
||||||
return sts
|
return sts
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue