This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
th_pass_mark = 0 | |
th_max_mark = 0 | |
pr_pass_mark = 0 | |
pr_max_mark = 0 | |
def parmark(pr_max_mark, pr_pass_mark, th_max_mark, th_pass_mark, score_mark): | |
if score_mark <= th_pass_mark: | |
score_pr_mark = pr_pass_mark |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('nvim-autopairs').setup({ | |
enable_check_bracket_line = true, -- Don't add pairs if it already have a close pairs in same line | |
disable_filetype = { "TelescopePrompt" , "vim" }, -- | |
enable_afterquote = false, -- add bracket pairs after quote | |
enable_moveright = true | |
}) | |
-- If you want insert `(` after select function or method item | |
local cmp_autopairs = require('nvim-autopairs.completion.cmp') | |
local cmp = require('cmp') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('configs') | |
--If you want to automatically ensure that packer.nvim is installed on any machine you clone your configuration to, | |
--add the following snippet (which is due to @Iron-E) somewhere in your config before your first usage of packer: | |
local execute = vim.api.nvim_command | |
local fn = vim.fn | |
local install_path = fn.stdpath('data')..'/site/pack/packer/start/packer.nvim' | |
if fn.empty(fn.glob(install_path)) > 0 then | |
fn.system({'git', 'clone', 'https://github.com/wbthomason/packer.nvim', install_path}) | |
execute 'packadd packer.nvim' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('configs') | |
--If you want to automatically ensure that packer.nvim is installed on any machine you clone your configuration to, | |
--add the following snippet (which is due to @Iron-E) somewhere in your config before your first usage of packer: | |
local execute = vim.api.nvim_command | |
local fn = vim.fn | |
local install_path = fn.stdpath('data')..'/site/pack/packer/start/packer.nvim' | |
if fn.empty(fn.glob(install_path)) > 0 then | |
fn.system({'git', 'clone', 'https://github.com/wbthomason/packer.nvim', install_path}) | |
execute 'packadd packer.nvim' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local exec = vim.api.nvim_exec -- execute Vimscript | |
local set = vim.opt -- global options | |
local cmd = vim.cmd -- execute Vim commands | |
-- local fn = vim.fn -- call Vim functions | |
-- local g = vim.g -- global variables | |
-- local b = vim.bo -- buffer-scoped options | |
-- local w = vim.wo -- windows-scoped options | |
cmd('autocmd ColorScheme * highlight ExtraWhitespace ctermbg=red guibg=grey') --to Show whitespace, MUST be inserted BEFORE the colorscheme command | |
cmd('colorscheme rvcs') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require'nvim-treesitter.configs'.setup { | |
highlight = { | |
enable = {"c", "cpp", "dart", "python", "javascript"}, -- enable = true (false will disable the whole extension) | |
-- disable = { "c", "rust" }, -- list of language that will be disabled | |
custom_captures = { | |
-- Highlight the @foo.bar capture group with the "Identifier" highlight group. | |
["foo.bar"] = "Identifier", | |
}, | |
-- Setting this to true will run `:h syntax` and tree-sitter at the same time. | |
-- Set this to `true` if you depend on 'syntax' being enabled (like for indentation). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--If you want to automatically ensure that packer.nvim is installed on any machine you clone your configuration to, | |
--add the following snippet (which is due to @Iron-E) somewhere in your config before your first usage of packer: | |
local execute = vim.api.nvim_command | |
local fn = vim.fn | |
local install_path = fn.stdpath('data')..'/site/pack/packer/start/packer.nvim' | |
if fn.empty(fn.glob(install_path)) > 0 then | |
fn.system({'git', 'clone', 'https://github.com/wbthomason/packer.nvim', install_path}) | |
execute 'packadd packer.nvim' | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local ls = require("luasnip") | |
-- some shorthands... | |
local s = ls.snippet | |
local sn = ls.snippet_node | |
local t = ls.text_node | |
local i = ls.insert_node | |
local f = ls.function_node | |
local c = ls.choice_node | |
local d = ls.dynamic_node |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Set completeopt to have a better completion experience | |
vim.o.completeopt = 'menuone,noselect' | |
local cmp = require'cmp' | |
cmp.setup({ | |
completion = { | |
--completeopt = 'menu,menuone,noinsert', | |
}, | |
snippet = { | |
expand = function(args) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local lsp_installer = require("nvim-lsp-installer") | |
-- Provide settings first! | |
lsp_installer.settings { | |
ui = { | |
icons = { | |
server_installed = "✓", | |
server_pending = "➜", | |
server_uninstalled = "✗", | |
}, |
NewerOlder