migrate config form function to global variable

This commit is contained in:
asep komarudin 2023-03-05 17:34:12 +07:00
parent b6f0601d3d
commit 38d2c29a95
24 changed files with 248 additions and 245 deletions

View file

@ -1,10 +1,8 @@
local M = {}
-- Untuk Ubah Dashboard
-- 1. Buka remark dash board dibawah
-- 2. Ubah dashboard sesuai keinginan dan kebutuhan
-- M.dashboard1 = {
-- vim.g.pcode_dashboard1 = {
-- [[ _ __ __ ]],
-- [[ ___ ___ (____ / /__ _______ ___/ ___ ]],
-- [[ / _ / _ \ / / _ \/ '_/ / __/ _ / _ / -_) ]],
@ -12,7 +10,7 @@ local M = {}
-- [[ /_/ |___/ ]],
-- }
-- M.dashboard2 = {
-- vim.g.pcode_dashboard2 = {
-- [[ __ ]],
-- [[ ___ ___ ___ __ __ /\_\ ___ ___ ]],
-- [[ / _ `\ / __`\ / __`\/\ \/\ \\/\ \ / __` __`\ ]],
@ -20,8 +18,6 @@ local M = {}
-- [[\ \_\ \_\ \____\ \____/\ \___/ \ \_\ \_\ \_\ \_\]],
-- [[ \/_/\/_/\/____/\/___/ \/__/ \/_/\/_/\/_/\/_/]],
-- }
-- M.footer = "PCode"
-- vim.g.pcode_footer = "PCode"
M.model = 1 -- isi dengan 1 atau 2 untuk model dashboard
return M
vim.g.pcode_model = 2 -- isi dengan 1 atau 2 untuk model dashboard

115
lua/custom/default.lua Normal file
View file

@ -0,0 +1,115 @@
-- custom colorscheme
-- colorscheme ready :
-- tokyonight, tokyonight-night, tokyonight-storm, tokyonight-day, tokyonight-moon
-- gruvbox-baby (default)
-- sonokai, sonokai_atlantis,
-- sonokai_andromeda,sonokai_shusia,sonokai_maia,sonokai_espresso
-- material, material_deepocean, material_palenight, material_lighter, material_darker
-- onedark, onedark_darker, onedark_cool, onedark_deep,onedark_warm,
-- onedark_warmer, onedark_light
-- lunar
-- nord
-- catppuccin, catppuccin-latte, catppuccin-frappe, catppuccin-macchiato, catppuccin-mocha
-- dracula
-- nightfox, dayfox, dawnfox, duskfox, nordfox, terafox, carbonfox
vim.g.pcode_colorscheme = "gruvbox-baby"
-- custom transparent mode
-- only support
-- gruvbox-baby,
-- tokyonight,
-- sonokai,
-- material
-- onedark
-- catppuccin
-- nord
-- dracula
-- nightfox
-- 0 =off 1= on
vim.g.pcode_transparent_mode = 0
-- 0 disable progress
-- 1 lualine lsp progress
-- 2 fidget progress
vim.g.pcode_progress = 1
-- style
-- 0 = default
-- 1 = { left = "", right = "" },
-- 2 = { left = " ", right = " " },
-- 3 = { left = "", right = "" },
vim.g.pcode_lualine_style = 0
-- style status icon
-- 0 = default
-- 1 = vim icon " "
-- 2 = vim icon " "
vim.g.pcode_status_icon = 0
-- start custom lualine style
-- contoh style
-- {
-- { left = "│", right = "│" },
-- { left = " ", right = " " },
-- },
-- {
-- { left = " ", right = " " },
-- { left = " ", right = "" },
-- },
-- {
-- { left = " ", right = " " },
-- { left = "", right = "" },
-- },
-- {
-- { left = "", right = "" },
-- { left = "", right = "" },
-- },
-- {
-- { left = " ", right = " " },
-- { left = "", right = "" },
-- },
-- }
vim.g.pcode_custom_lualine = false
vim.g.pcode_component_separators = { left = " ", right = " " }
vim.g.pcode_section_separators = { left = "", right = "" }
-- 0 ( format jalan) 1 (fromat off)
vim.g.pcode_format_on_save = 1
-- ini hanya untuk lsp yg tidak support masson
-- untuk referesi support language kunjungi link dibawah
-- https://github.com/neovim/nvim-lspconfig/blob/master/doc/server_configurations.md
vim.g.pcode_lsp_installer = {
"yamlls",
-- tambahkan di bawah sini setelah melakukan :masoninstall
}
-- untuk referesi support language kunjungi link dibawah
-- https://github.com/neovim/nvim-lspconfig/blob/master/doc/server_configurations.md
vim.g.pcode_register_lsp = {
"yamlls",
"intelephense",
"marksman",
"csharp_ls",
"clangd",
"dartls",
"kotlin_language_server",
-- tambahkan di bawah sini setelah melakukan :masoninstall
}
vim.g.pcode_unregister_lsp = {
"jdtls", -- tambahkan di bawah ini
}
-- https://github.com/jose-elias-alvarez/null-ls.nvim/blob/main/doc/BUILTINS.md
local formatting = {}
local diagnostics = {}
vim.g.pcode_null_ls_sources = {
formatting.stylua, -- tambahkan di bawah sini
diagnostics.flake8, -- tambahkan di bawah sini
}
-- https://github.com/folke/which-key.nvim
vim.g.pcode_whichkey = {
-- contoh penambahan
-- ["k"] = {
-- name = "Example",
-- k = { '<cmd>lua print("Testing")<cr>', "Example" },
-- },
["r"] = {
name = "Run",
j = { "<cmd>Jaq float<CR>", "Run With Jaq" },
},
["o"] = { "<cmd>SymbolsOutline<cr>", "Symbol Outline" },
}

View file

@ -1,5 +0,0 @@
local M = {
disable = 0, -- 0 ( format jalan) 1 (fromat off)
}
return M

View file

@ -1,10 +0,0 @@
-- ini hanya untuk lsp yg tidak support masson
-- untuk referesi support language kunjungi link dibawah
-- https://github.com/neovim/nvim-lspconfig/blob/master/doc/server_configurations.md
local m = {
lspinstall = {
"yamlls",
-- tambahkan di bawah sini setelah melakukan :masoninstall
},
}
return m

View file

@ -1,10 +0,0 @@
local null_ls = require("null-ls")
local formatting = null_ls.builtins.formatting
local diagnostics = null_ls.builtins.diagnostics
local m = {
sources = {
formatting.stylua, -- tambahkan di bawah sini
diagnostics.flake8, -- tambahkan di bawah sini
},
}
return m

View file

@ -1,18 +0,0 @@
-- untuk referesi support language kunjungi link dibawah
-- https://github.com/neovim/nvim-lspconfig/blob/master/doc/server_configurations.md
local m = {
lspreg = {
"yamlls",
"intelephense",
"marksman",
"csharp_ls",
"clangd",
"dartls",
"kotlin_language_server",
-- tambahkan di bawah sini setelah melakukan :masoninstall
},
skipreg = {
"jdtls", -- tambahkan di bawah ini
},
}
return m

View file

@ -1,73 +0,0 @@
local m = {}
-- 0 disable progress
-- 1 lualine lsp progress
-- 2 fidget progress
m.progress = 1
-- style
-- 0 = default
-- 1 = { left = "", right = "" },
-- 2 = { left = " ", right = " " },
-- 3 = { left = "", right = "" },
m.lualine_style = 0
-- style status icon
-- 0 = default
-- 1 = vim icon " "
-- 2 = vim icon " "
m.status_icon = 0
-- start custom lualine style
-- contoh style
-- {
-- { left = "│", right = "│" },
-- { left = " ", right = " " },
-- },
-- {
-- { left = " ", right = " " },
-- { left = " ", right = "" },
-- },
-- {
-- { left = " ", right = " " },
-- { left = "", right = "" },
-- },
-- {
-- { left = "", right = "" },
-- { left = "", right = "" },
-- },
-- {
-- { left = " ", right = " " },
-- { left = "", right = "" },
-- },
-- }
m.custom_lualine = false
m.component_separators = { left = " ", right = " " }
m.section_separators = { left = "", right = "" }
-- end custom lualine style
-- custom colorscheme
-- colorscheme ready :
-- tokyonight, tokyonight-night, tokyonight-storm, tokyonight-day, tokyonight-moon
-- gruvbox-baby (default)
-- sonokai, sonokai_atlantis,
-- sonokai_andromeda,sonokai_shusia,sonokai_maia,sonokai_espresso
-- material, material_deepocean, material_palenight, material_lighter, material_darker
-- onedark, onedark_darker, onedark_cool, onedark_deep,onedark_warm,
-- onedark_warmer, onedark_light
-- lunar
-- nord
-- catppuccin, catppuccin-latte, catppuccin-frappe, catppuccin-macchiato, catppuccin-mocha
-- dracula
-- nightfox, dayfox, dawnfox, duskfox, nordfox, terafox, carbonfox
m.colorscheme = "gruvbox-baby"
-- custom transparent mode
-- only support
-- gruvbox-baby,
-- tokyonight,
-- sonokai,
-- material
-- onedark
-- catppuccin
-- nord
-- dracula
-- nightfox
-- 0 =off 1= on
m.transparent_mode = 0
return m

View file

@ -1,12 +0,0 @@
return {
-- contoh penambahan
-- ["k"] = {
-- name = "Example",
-- k = { '<cmd>lua print("Testing")<cr>', "Example" },
-- },
["r"] = {
name = "Run",
j = { "<cmd>Jaq float<CR>", "Run With Jaq" },
},
["o"] = { "<cmd>SymbolsOutline<cr>", "Symbol Outline" },
}