Updated 6. Configurations (markdown)

Asep Komarudin 2023-12-31 13:54:10 +07:00
parent df6301066a
commit 71cce6f75b

@ -224,25 +224,25 @@ For a list of all supported language servers, see the Mason.nvim documentation:
# Comfig Treesitter # Comfig Treesitter
- Jalankan Code Berikut pada command - Run the following code on the command
```lua ```lua
:TSInstall html css javascript ..... dst :TSInstall html css javascript ..... dst
``` ```
- Rujukan Language Support <br> - Language Support Reference <br>
https://github.com/nvim-treesitter/nvim-treesitter#supported-languages https://github.com/nvim-treesitter/nvim-treesitter#supported-languages
# Ubah Dashboard # Change Dashboard
- Cari File lua/custom/dashboard.lua - Find the File lua/custom/dashboard.lua
- Edit Bagian ini - Edit this part
```lua ```lua
-- Untuk Ubah Dashboard -- Change the Dashboard
-- 1. Buka remark dash board dibawah -- 1. Open the remark on bellow
-- 2. Ubah dashboard sesuai keinginan dan kebutuhan -- 2. Change the dashboard ASCII art
-- vim.g.pcode_dashboard1 = { -- vim.g.pcode_dashboard1 = {
-- [[ _ __ __ ]], -- [[ _ __ __ ]],
@ -262,14 +262,14 @@ For a list of all supported language servers, see the Mason.nvim documentation:
-- } -- }
-- vim.g.pcode_footer = "PCode" -- vim.g.pcode_footer = "PCode"
vim.g.pcode_model = 2 -- isi dengan 1 atau 2 untuk model dashboard vim.g.pcode_model = 2 -- input 1 or 2 for dashboard model
``` ```
- Link Generate Dasboard - Link Generate Dasboard
https://patorjk.com/software/taag/ https://patorjk.com/software/taag/
# Custom User Config # Custom User Config
- cari file lua/custom/default.lua - Find the file lua/custom/default.lua
```lua ```lua
-- custom colorscheme -- custom colorscheme
-- colorscheme ready : -- colorscheme ready :
@ -395,9 +395,9 @@ vim.g.pcode_coderunner = {
} }
``` ```
# Custom Autocommand # Custom Autocommand
- cari file lua/default/autocommand.lua - Find the file lua/default/autocommand.lua
- Lakukan config sesuai kebutuhan - Configure according to your needs
- Contoh : - Example :
```lua ```lua
vim.cmd([[ vim.cmd([[
augroup _markdown augroup _markdown
@ -408,8 +408,8 @@ vim.cmd([[
]]) ]])
``` ```
# Cutom Default Option # Cutom Default Option
- cari file lua/default/options.lua - Find the file lua/default/options.lua
- Contoh Config: - Example :
```lua ```lua
vim.g.mapleader = " " vim.g.mapleader = " "
vim.g.maplocalleader = " " vim.g.maplocalleader = " "
@ -467,31 +467,31 @@ end
vim.g.markdown_recommended_style = 0 vim.g.markdown_recommended_style = 0
``` ```
# Custom Key Mapping # Custom Key Mapping
- cari file lua/dafault/keymaps.lua - Find the file lua/dafault/keymaps.lua
``` ```
-- custom key maps disini -- custom key maps here
local function map(mode, l, r, desc) local function map(mode, l, r, desc)
vim.keymap.set(mode, l, r, { desc = desc }) vim.keymap.set(mode, l, r, { desc = desc })
end end
-- ini adalah contoh -- this is an example
map("n", "]h", '<cmd>lua print("Testing")<cr>', "Testing Mapping") map("n", "]h", '<cmd>lua print("Testing")<cr>', "Testing Mapping")
``` ```
# Custom Plugins # Custom Plugins
- cari file lua/plugin/* - Find the file lua/plugin/*
- masukan semua plugin pada folder tersebut - Create file plgins in folder lua/plugin
- disable plugins - Disable plugins
``` ```
{ "folke/trouble.nvim", enabled = false }, -- ini untuk disable plugin { "folke/trouble.nvim", enabled = false }, -- ini untuk disable plugin
``` ```
- tambah plugins - Add new custom plugins
``` ```
{"nvim-treesitter/nvim-treesitter"}, {"nvim-treesitter/nvim-treesitter"},
``` ```
untuk panduan silahkan cek <br> For exaple refer to <br>
https://github.com/folke/lazy.nvim#Examples https://github.com/folke/lazy.nvim#Examples
# Custom-Snippets # Custom-Snippets
- Cari File nvim/my-snippet/package.json - Find the File nvim/my-snippet/package.json
- tambahkan custom snippets pada bagian berikut - Add custom snippets in the part
```json ```json
"contributes": { "contributes": {
"snippets": [ "snippets": [
@ -506,8 +506,8 @@ https://github.com/folke/lazy.nvim#Examples
] ]
} }
``` ```
## Load Sendiri Custom Snippets ## Manually load custom snippets
- buat file lua/default/snippets.lua - Crate file lua/default/snippets.lua
```lua ```lua
local status_ok = pcall(require, "luasnip") local status_ok = pcall(require, "luasnip")
if not status_ok then if not status_ok then
@ -529,12 +529,12 @@ require("luasnip.loaders.from_vscode").lazy_load({
require("luasnip.loaders.from_vscode").load({ paths = lpath .. "/html" }) require("luasnip.loaders.from_vscode").load({ paths = lpath .. "/html" })
require("luasnip.loaders.from_vscode").load({ paths = lpath .. "/javascript-snippet" }) require("luasnip.loaders.from_vscode").load({ paths = lpath .. "/javascript-snippet" })
``` ```
- panggil config dari lua/default/init.lua - Call the config from lua/default/init.lua
```lua ```lua
require("default.snippets") require("default.snippets")
``` ```
# Config Neovide # Neovide Configuration
- buka file lua/default/options.lua - Open the file lua/default/options.lua
```lua ```lua
if vim.g.neovide then if vim.g.neovide then
vim.g.neovide_input_use_logo = 1 -- enable use of the logo (cmd) key vim.g.neovide_input_use_logo = 1 -- enable use of the logo (cmd) key