aaaa
This commit is contained in:
parent
2ea210b1df
commit
70e29843db
|
@ -94,8 +94,6 @@ return {
|
|||
{ 'nvim-telescope/telescope-fzf-native.nvim', build = 'make' },
|
||||
{ "nvim-telescope/telescope-file-browser.nvim" },
|
||||
|
||||
-- Treesitter
|
||||
{ 'nvim-treesitter/nvim-treesitter', build = ':TSUpdate' },
|
||||
|
||||
-- Registry history
|
||||
{
|
||||
|
|
|
@ -0,0 +1,52 @@
|
|||
local M = {
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
build = ":TSUpdate",
|
||||
event = "BufReadPost",
|
||||
dependencies = {
|
||||
"nvim-treesitter/nvim-treesitter-refactor",
|
||||
},
|
||||
opts = {
|
||||
highlight = {
|
||||
enable = true,
|
||||
disable = function(lang, buf)
|
||||
local max_filesize = 100 * 1024 -- 100 KB
|
||||
local ok, stats = pcall(vim.loop.fs_stat, vim.api.nvim_buf_get_name(buf))
|
||||
if ok and stats and stats.size > max_filesize then
|
||||
return true
|
||||
end
|
||||
end,
|
||||
additional_vim_regex_highlighting = false,
|
||||
},
|
||||
autopairs = { enable = true },
|
||||
autotag = { enable = true },
|
||||
indent = { enable = true },
|
||||
ensure_installed = {
|
||||
"json",
|
||||
"yaml",
|
||||
"html",
|
||||
"css",
|
||||
"markdown",
|
||||
"bash",
|
||||
"lua",
|
||||
"vim",
|
||||
"dockerfile",
|
||||
"gitignore",
|
||||
"python"
|
||||
},
|
||||
sync_install = true,
|
||||
ignore_install = {}, -- List of parsers to ignore installation
|
||||
refactor = {
|
||||
highlight_definitions = {
|
||||
enable = true,
|
||||
-- Set to false if you have an `updatetime` of ~100.
|
||||
clear_on_cursor_move = true,
|
||||
},
|
||||
highlight_current_scope = { enable = false },
|
||||
},
|
||||
},
|
||||
config = function(_, opts)
|
||||
require("nvim-treesitter.configs").setup(opts)
|
||||
end,
|
||||
}
|
||||
|
||||
return M
|
|
@ -11,7 +11,7 @@ def add(x, y):
|
|||
|
||||
print(f"{x} + {y} = {x+y}\n")
|
||||
|
||||
def subtract(x, y) -> int:
|
||||
def subtract(x: int, y: int) -> int:
|
||||
"""
|
||||
Very cool function that will subtract two ints
|
||||
return: int
|
||||
|
|
Loading…
Reference in New Issue