Initial Commit
This commit is contained in:
commit
f2ff7bda11
18 changed files with 342 additions and 0 deletions
4
after/ftplugin/html.lua
Executable file
4
after/ftplugin/html.lua
Executable file
|
|
@ -0,0 +1,4 @@
|
|||
vim.opt.tabstop = 2
|
||||
vim.opt.softtabstop = 2
|
||||
vim.opt.shiftwidth = 2
|
||||
|
||||
7
after/plugin/colors.lua
Executable file
7
after/plugin/colors.lua
Executable file
|
|
@ -0,0 +1,7 @@
|
|||
vim.o.background = "dark"
|
||||
|
||||
local c = require("vscode.colors").get_colors()
|
||||
require("vscode").setup({
|
||||
transparent = true
|
||||
})
|
||||
|
||||
9
after/plugin/comment.lua
Executable file
9
after/plugin/comment.lua
Executable file
|
|
@ -0,0 +1,9 @@
|
|||
require("Comment").setup()
|
||||
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"<C-_>",
|
||||
function() require("Comment.api").toggle.linewise.current() end,
|
||||
{ noremap = true, silent = true }
|
||||
)
|
||||
|
||||
18
after/plugin/firenvim.lua
Executable file
18
after/plugin/firenvim.lua
Executable file
|
|
@ -0,0 +1,18 @@
|
|||
vim.g.firenvim_config = {
|
||||
globalSettings = { alt = "all" },
|
||||
localSettings = {
|
||||
[".*"] = {
|
||||
cmdline = "neovim",
|
||||
content = "text",
|
||||
priority = 0,
|
||||
selector = "textarea",
|
||||
takeover = "never"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
-- Prevents scrolling when cursor is near the bottom of the text area
|
||||
if vim.g.started_by_firenvim == true then
|
||||
vim.opt.scrolloff = 0
|
||||
end
|
||||
|
||||
4
after/plugin/lightline.lua
Executable file
4
after/plugin/lightline.lua
Executable file
|
|
@ -0,0 +1,4 @@
|
|||
vim.g.lightline = {
|
||||
colorscheme = "one"
|
||||
}
|
||||
|
||||
52
after/plugin/lsp.lua
Executable file
52
after/plugin/lsp.lua
Executable file
|
|
@ -0,0 +1,52 @@
|
|||
local lsp = require('lsp-zero')
|
||||
lsp.preset('recommended')
|
||||
|
||||
lsp.ensure_installed({
|
||||
"lua_ls", -- Lua
|
||||
"rust_analyzer", -- Rust
|
||||
"pyright", -- Python
|
||||
"texlab", -- Latex
|
||||
"clangd", -- C
|
||||
"jdtls", -- Java
|
||||
"html", -- Html
|
||||
})
|
||||
|
||||
local cmp = require("cmp")
|
||||
local cmp_select = {behavior = cmp.SelectBehavior.Select}
|
||||
local cmp_mappings = lsp.defaults.cmp_mappings({
|
||||
["<C-p>"] = cmp.mapping.select_prev_item(cmp_select),
|
||||
["<C-n>"] = cmp.mapping.select_next_item(cmp_select),
|
||||
["<C-y>"] = cmp.mapping.confirm({ select = true }),
|
||||
})
|
||||
|
||||
lsp.set_preferences({
|
||||
sign_icons = { }
|
||||
})
|
||||
|
||||
lsp.setup_nvim_cmp({
|
||||
mapping = cmp_mappings
|
||||
})
|
||||
|
||||
lsp.configure('lua_ls', {
|
||||
settings = {
|
||||
Lua = {
|
||||
diagnostics = {
|
||||
-- Making sure that lua recognizes the global variable 'vim'
|
||||
globals = { 'vim' },
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
lsp.configure('pyright', {
|
||||
settings = {
|
||||
python = {
|
||||
analysis = {
|
||||
typeCheckingMode = "off",
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
lsp.setup()
|
||||
|
||||
10
after/plugin/nvimtree.lua
Executable file
10
after/plugin/nvimtree.lua
Executable file
|
|
@ -0,0 +1,10 @@
|
|||
-- set termguicolors to enable highlight groups
|
||||
vim.opt.termguicolors = true
|
||||
|
||||
require("nvim-tree").setup()
|
||||
|
||||
vim.keymap.set("n", "<leader>pt", ":NvimTreeToggle<CR>")
|
||||
|
||||
-- sets transparent background
|
||||
vim.cmd[[hi NvimTreeNormal guibg=NONE ctermbg=NONE]]
|
||||
|
||||
12
after/plugin/telescope.lua
Executable file
12
after/plugin/telescope.lua
Executable file
|
|
@ -0,0 +1,12 @@
|
|||
local builtin = require("telescope.builtin")
|
||||
vim.keymap.set("n", "<leader>pf", builtin.find_files, {})
|
||||
vim.keymap.set("n", "<leader>ps", function()
|
||||
builtin.grep_string({ search = vim.fn.input("Grep > ") })
|
||||
end)
|
||||
|
||||
require("telescope").setup{
|
||||
defaults = {
|
||||
file_ignore_patterns = { ".git\\", ".pyc", ".mypy_cache\\", "node_modules\\", ".svg" }
|
||||
}
|
||||
}
|
||||
|
||||
16
after/plugin/treesitter.lua
Executable file
16
after/plugin/treesitter.lua
Executable file
|
|
@ -0,0 +1,16 @@
|
|||
require'nvim-treesitter.configs'.setup {
|
||||
ensure_installed = { "vim", "javascript", "html", "css", "python", "java", "lua", "perl", "php", "c" },
|
||||
|
||||
ignore_install = { "latex", "markdown", "htmldjango" },
|
||||
|
||||
sync_install = false,
|
||||
|
||||
auto_install = false,
|
||||
|
||||
highlight = {
|
||||
enable = true,
|
||||
|
||||
addition_vim_regex_highlighting = false,
|
||||
},
|
||||
}
|
||||
|
||||
24
after/plugin/vimtex.lua
Executable file
24
after/plugin/vimtex.lua
Executable file
|
|
@ -0,0 +1,24 @@
|
|||
vim.cmd([[
|
||||
|
||||
let maplocalleader = " "
|
||||
|
||||
let g:vimtex_compiler_method = 'latexmk'
|
||||
|
||||
let g:tex_flavor='latex'
|
||||
let g:vimtex_quickfix_mode=0
|
||||
|
||||
" settings for sumatraPDF
|
||||
let g:vimtex_view_general_viewer = 'C:\Users\andre\AppData\Local\SumatraPDF\SumatraPDF.exe'
|
||||
let g:vimtex_view_general_options
|
||||
\ = '-reuse-instance -forward-search @tex @line @pdf'
|
||||
|
||||
set conceallevel=1
|
||||
let g:tex_conceal='abdmg'
|
||||
|
||||
augroup vimtex_config
|
||||
au!
|
||||
au User VimtexEventQuit call vimtex#compiler#clean(0)
|
||||
augroup END
|
||||
|
||||
]])
|
||||
|
||||
40
after/syntax/asm.vim
Executable file
40
after/syntax/asm.vim
Executable file
|
|
@ -0,0 +1,40 @@
|
|||
syntax case ignore
|
||||
|
||||
" Match regexes.
|
||||
syntax match lc3Label /[A-Za-z_][A-Za-z0-9_]*/
|
||||
syntax match lc3Register /[rR][0-7]/
|
||||
syntax match lc3Decimal /#\=-\=\<[0-9]\+\>/
|
||||
syntax match lc3Hex /x-\=[A-Fa-f0-9]\+/
|
||||
syntax match lc3Binary /b-\=[01]\+/
|
||||
syntax region lc3String start=+"+ skip=+\\"+ end=+"+
|
||||
syntax region lc3Comment start=+;+ end=+$+
|
||||
|
||||
" Assembler directives/pseudo-ops
|
||||
syntax match lc3Directive /\.orig/
|
||||
syntax match lc3Directive /\.end/
|
||||
syntax match lc3Directive /\.fill/
|
||||
syntax match lc3Directive /\.blkw/
|
||||
syntax match lc3Directive /\.stringz/
|
||||
|
||||
" LC-3 opcodes/aliases, minus branches
|
||||
syntax keyword lc3Opcode add ld st jsrr jsr and ldr str rti not ldi sti jmp ret lea trap nop
|
||||
" Branches
|
||||
syntax keyword lc3Opcode br brn brz brp brnz brnp brzp brnzp
|
||||
" Trap subroutines
|
||||
syntax keyword lc3Opcode getc out puts in putsp halt
|
||||
" LC-3b opcodes
|
||||
syntax keyword lc3Opcode ldb ldw lshf rshfl rshfa stb stw xor
|
||||
|
||||
" Link colors.
|
||||
hi def link lc3Opcode Statement
|
||||
hi def link lc3Label Identifier
|
||||
hi def link lc3Register Type
|
||||
hi def link lc3Directive Define
|
||||
hi def link lc3Decimal Number
|
||||
hi def link lc3Hex Number
|
||||
hi def link lc3Binary Number
|
||||
hi def link lc3String String
|
||||
hi def link lc3Comment Comment
|
||||
|
||||
let b:current_syntax = "asm"
|
||||
|
||||
15
after/syntax/lua.vim
Executable file
15
after/syntax/lua.vim
Executable file
|
|
@ -0,0 +1,15 @@
|
|||
|
||||
syn include @Vim $VIMRUNTIME/syntax/vim.vim
|
||||
syn region embedvim matchgroup=luaEmbedError start="vim\.api\.nvim_command(\[\[" end="\]\])" keepend contains=@Vim
|
||||
syn region embedvim matchgroup=luaEmbedError start="vim\.api\.nvim_command \[\[" end="\]\]" keepend contains=@Vim
|
||||
syn region embedvim matchgroup=luaEmbedError start="vim\.api\.nvim_exec(\[\[" end="\]\])" keepend contains=@Vim
|
||||
syn region embedvim matchgroup=luaEmbedError start="vim\.api\.nvim_exec \[\[" end="\]\]" keepend contains=@Vim
|
||||
syn region embedvim matchgroup=luaEmbedError start="vim\.cmd \[\[" end="\]\]" keepend contains=@Vim
|
||||
syn region embedvim matchgroup=luaEmbedError start="vim\.cmd(\[\[" end="\]\])" keepend contains=@Vim
|
||||
syn region embedvim matchgroup=luaEmbedError start="vim\.cmd \"" end="\"" keepend contains=@Vim
|
||||
syn region embedvim matchgroup=luaEmbedError start="vim\.cmd(\"" end="\")" keepend contains=@Vim
|
||||
syn region embedvim matchgroup=luaEmbedError start="vim\.cmd '" end="'" keepend contains=@Vim
|
||||
syn region embedvim matchgroup=luaEmbedError start="vim\.cmd('" end="')" keepend contains=@Vim
|
||||
|
||||
let b:current_syntax = 'lua'
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue