better
This commit is contained in:
parent
2fb5e97e4f
commit
a2f972c52c
4 changed files with 19 additions and 6 deletions
|
|
@ -1 +0,0 @@
|
||||||
autocmd VimEnter,BufWinEnter,BufRead,BufNewFile *.pg setlocal filetype=perga
|
|
||||||
|
|
@ -1,6 +1,10 @@
|
||||||
local M = {}
|
local M = {}
|
||||||
|
|
||||||
function M.setup(opts)
|
function M.setup(opts)
|
||||||
|
vim.filetype.add({
|
||||||
|
extension = { pg = 'perga' }
|
||||||
|
})
|
||||||
|
|
||||||
local parser_config = require "nvim-treesitter.parsers".get_parser_configs()
|
local parser_config = require "nvim-treesitter.parsers".get_parser_configs()
|
||||||
parser_config.perga = {
|
parser_config.perga = {
|
||||||
install_info = {
|
install_info = {
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,17 @@
|
||||||
[ "fun" "λ" "forall" "∏" ] @keyword
|
[ "fun" "λ" "forall" "∏" ] @keyword
|
||||||
[ "->" "=>" "→" "⇒" "," ":=" ";" ":" ] @punctuation.delimiter
|
[ "->" "=>" "→" "⇒" "," ":=" ";" ":" ] @punctuation.delimiter
|
||||||
[ "(" ")" ] @punctuation.bracket
|
|
||||||
;[ "*" "□" "[]" ] @constant.builtin
|
[(star) (square)] @constant.builtin
|
||||||
|
|
||||||
(comment) @comment
|
(comment) @comment
|
||||||
(identifier) @variable
|
|
||||||
;(param) @variable.parameter
|
[ "(" ")" ] @punctuation.bracket
|
||||||
;(type) @type
|
|
||||||
|
(definition
|
||||||
|
name: (identifier) @function)
|
||||||
|
|
||||||
|
(param_block
|
||||||
|
param: (identifier)+ @variable.parameter)
|
||||||
|
|
||||||
|
(param_block
|
||||||
|
type: (expr) @type)
|
||||||
|
|
|
||||||
1
queries/rainbow-delimiters.scm
Normal file
1
queries/rainbow-delimiters.scm
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
["(" ")"] @delimiter
|
||||||
Loading…
Reference in a new issue