summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKyren223 <contact@kyren.codes>2025-09-15 00:50:07 +0300
committerKyren223 <contact@kyren.codes>2025-09-15 00:50:07 +0300
commit4facf3b949e31dc24f5c7cb35707c1328a8f9298 (patch)
tree5ac1388a9b38a64730b58b287bf43dc72e9abfa1
parent5769657f181f98e835e76e1fe60ee9efa06836b0 (diff)
Add comments to Krypton file type
-rw-r--r--.config/nvim/lua/plugins/krypton.lua7
-rw-r--r--.config/nvim/queries/c/highlights.scm2
2 files changed, 8 insertions, 1 deletions
diff --git a/.config/nvim/lua/plugins/krypton.lua b/.config/nvim/lua/plugins/krypton.lua
index b49c00f..26dc5eb 100644
--- a/.config/nvim/lua/plugins/krypton.lua
+++ b/.config/nvim/lua/plugins/krypton.lua
@@ -24,5 +24,12 @@ return {
-- vim.notify('COLOR: ' .. color)
assert(icon == '')
assert(color == 'DevIconKrypton')
+
+ vim.api.nvim_create_autocmd('FileType', {
+ pattern = 'krypton',
+ callback = function()
+ vim.bo.commentstring = '// %s'
+ end,
+ })
end,
}
diff --git a/.config/nvim/queries/c/highlights.scm b/.config/nvim/queries/c/highlights.scm
index 688bf8f..c5bfbbd 100644
--- a/.config/nvim/queries/c/highlights.scm
+++ b/.config/nvim/queries/c/highlights.scm
@@ -1,6 +1,6 @@
; extends
([(identifier) (type_identifier) (true) (false)] @keyword
- (#any-of? @keyword "fn"
+ (#any-of? @keyword "proc" "inlined"
"u8" "u16" "u32" "u64"
"i8" "i16" "i32" "i64"
"f32" "f64"