Skip to content
Closed

Fail #1717

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
496 changes: 25 additions & 471 deletions init.lua

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions lua/custom/plugins/copilot.lua.bak
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
return {
'github/copilot.vim',
}
1 change: 1 addition & 0 deletions lua/custom/plugins/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
-- I promise not to create any merge conflicts in this directory :)
--
-- See the kickstart.nvim README for more information

return {}
9 changes: 9 additions & 0 deletions lua/custom/plugins/render-markdown.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
return {
'MeanderingProgrammer/render-markdown.nvim',
dependencies = { 'nvim-treesitter/nvim-treesitter', 'echasnovski/mini.nvim' }, -- if you use the mini.nvim suite
-- dependencies = { 'nvim-treesitter/nvim-treesitter', 'echasnovski/mini.icons' }, -- if you use standalone mini plugins
-- dependencies = { 'nvim-treesitter/nvim-treesitter', 'nvim-tree/nvim-web-devicons' }, -- if you prefer nvim-web-devicons
---@module 'render-markdown'
---@type render.md.UserConfig
opts = {},
}
61 changes: 61 additions & 0 deletions lua/custom/plugins/rose-pine.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
return {
'rose-pine/neovim',
name = 'rose-pine',
config = function()
require('rose-pine').setup {
variant = 'auto', -- auto, main, moon, or dawn
dark_variant = 'main', -- main, moon, or dawn
dim_inactive_windows = false,
extend_background_behind_borders = true,

enable = {
terminal = true,
legacy_highlights = true, -- Improve compatibility for previous versions of Neovim
migrations = true, -- Handle deprecated options automatically
},

styles = {
bold = true,
italic = true,
transparency = true,
},

groups = {
border = 'muted',
link = 'iris',
panel = 'surface',

error = 'love',
hint = 'iris',
info = 'foam',
note = 'pine',
todo = 'rose',
warn = 'gold',

git_add = 'foam',
git_change = 'rose',
git_delete = 'love',
git_dirty = 'rose',
git_ignore = 'muted',
git_merge = 'iris',
git_rename = 'pine',
git_stage = 'iris',
git_text = 'rose',
git_untracked = 'subtle',

h1 = 'iris',
h2 = 'foam',
h3 = 'rose',
h4 = 'gold',
h5 = 'pine',
h6 = 'foam',
},

palette = {},

highlight_groups = {},
}

vim.cmd 'colorscheme rose-pine'
end,
}
3 changes: 3 additions & 0 deletions lua/custom/plugins/undotree.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
return {
'mbbill/undotree',
}
10 changes: 10 additions & 0 deletions lua/custom/plugins/vimtex.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
return {
'lervag/vimtex',
lazy = false, -- we don't want to lazy load VimTeX
init = function()
-- VimTeX configuration goes here, e.g.
vim.g.vimtex_view_general_viewer = 'okular'
vim.g.vimtex_view_general_options = '--unique file:@pdf#src:@line@tex'
vim.g.tex_flavor = 'latex'
end,
}
56 changes: 56 additions & 0 deletions lua/custom/remap.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
-- vim.keymap.set('n', '!', '_') -- For macos only

-- Center the view when moving
vim.keymap.set('n', '<C-d>', '<C-d>zz')
vim.keymap.set('n', '<C-u>', '<C-u>zz')

-- Access to file viewer easily
vim.keymap.set('n', '<leader>pv', vim.cmd.Ex, { desc = '[P]roject files [V]iewer' })
vim.keymap.set('n', '<leader>pb', '<cmd>make<CR>', { desc = '[P]roject [B]uild' })
vim.keymap.set('n', '<leader>pc', '<cmd>make clean<CR>', { desc = '[P]roject [C]lean' })
vim.keymap.set('n', '<leader>pr', '<cmd>make run<CR>', { desc = '[P]roject [R]un' })

vim.api.nvim_set_hl(0, 'Normal', { bg = 'none' })
vim.api.nvim_set_hl(0, 'NormalFloat', { bg = 'none' })

-- Undotree
vim.keymap.set('n', '<F5>', vim.cmd.UndotreeToggle)

-- [[ Basic Keymaps ]]
-- See `:help vim.keymap.set()`

-- Clear highlights on search when pressing <Esc> in normal mode
-- See `:help hlsearch`
vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>')

-- Diagnostic keymaps
vim.keymap.set('n', '<leader>q', vim.diagnostic.setloclist, { desc = 'Open diagnostic [Q]uickfix list' })

-- Exit terminal mode in the builtin terminal with a shortcut that is a bit easier
-- for people to discover. Otherwise, you normally need to press <C-\><C-n>, which
-- is not what someone will guess without a bit more experience.
--
-- NOTE: This won't work in all terminal emulators/tmux/etc. Try your own mapping
-- or just use <C-\><C-n> to exit terminal mode
vim.keymap.set('t', '<Esc><Esc>', '<C-\\><C-n>', { desc = 'Exit terminal mode' })

-- TIP: Disable arrow keys in normal mode
vim.keymap.set('n', '<left>', '<cmd>echo "Use h to move!!"<CR>')
vim.keymap.set('n', '<right>', '<cmd>echo "Use l to move!!"<CR>')
vim.keymap.set('n', '<up>', '<cmd>echo "Use k to move!!"<CR>')
vim.keymap.set('n', '<down>', '<cmd>echo "Use j to move!!"<CR>')

-- Keybinds to make split navigation easier.
-- Use CTRL+<hjkl> to switch between windows
--
-- See `:help wincmd` for a list of all window commands
vim.keymap.set('n', '<C-h>', '<C-w><C-h>', { desc = 'Move focus to the left window' })
vim.keymap.set('n', '<C-l>', '<C-w><C-l>', { desc = 'Move focus to the right window' })
vim.keymap.set('n', '<C-j>', '<C-w><C-j>', { desc = 'Move focus to the lower window' })
vim.keymap.set('n', '<C-k>', '<C-w><C-k>', { desc = 'Move focus to the upper window' })

-- NOTE: Some terminals have colliding keymaps or are not able to send distinct keycodes
-- vim.keymap.set("n", "<C-S-h>", "<C-w>H", { desc = "Move window to the left" })
-- vim.keymap.set("n", "<C-S-l>", "<C-w>L", { desc = "Move window to the right" })
-- vim.keymap.set("n", "<C-S-j>", "<C-w>J", { desc = "Move window to the lower" })
-- vim.keymap.set("n", "<C-S-k>", "<C-w>K", { desc = "Move window to the upper" })
70 changes: 70 additions & 0 deletions lua/custom/sets.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
-- Set to true if you have a Nerd Font installed and selected in the terminal
vim.g.have_nerd_font = true

-- [[ Setting options ]]
-- See `:help vim.opt`
-- NOTE: You can change these options as you wish!
-- For more options, you can see `:help option-list`

-- Make line numbers default
vim.opt.number = true
-- You can also add relative line numbers, to help with jumping.
-- Experiment for yourself to see if you like it!
vim.opt.relativenumber = true

-- Enable mouse mode, can be useful for resizing splits for example!
vim.opt.mouse = 'a'

-- Don't show the mode, since it's already in the status line
vim.opt.showmode = false

-- Sync clipboard between OS and Neovim.
-- Schedule the setting after `UiEnter` because it can increase startup-time.
-- Remove this option if you want your OS clipboard to remain independent.
-- See `:help 'clipboard'`
vim.schedule(function()
vim.opt.clipboard = 'unnamedplus'
end)

-- Enable break indent
vim.opt.breakindent = true

-- Save undo history
vim.opt.undofile = true

-- Case-insensitive searching UNLESS \C or one or more capital letters in the search term
vim.opt.ignorecase = true
vim.opt.smartcase = true

-- Keep signcolumn on by default
vim.opt.signcolumn = 'yes'

-- Decrease update time
vim.opt.updatetime = 250

-- Decrease mapped sequence wait time
vim.opt.timeoutlen = 300

-- Configure how new splits should be opened
vim.opt.splitright = true
vim.opt.splitbelow = true

-- Sets how neovim will display certain whitespace characters in the editor.
-- See `:help 'list'`
-- and `:help 'listchars'`
vim.opt.list = true
vim.opt.listchars = { tab = '» ', trail = '·', nbsp = '␣' }

-- Preview substitutions live, as you type!
vim.opt.inccommand = 'split'

-- Show which line your cursor is on
vim.opt.cursorline = true

-- Minimal number of screen lines to keep above and below the cursor.
vim.opt.scrolloff = 10

-- if performing an operation that would fail due to unsaved changes in the buffer (like `:q`),
-- instead raise a dialog asking if you wish to save the current file(s)
-- See `:help 'confirm'`
vim.opt.confirm = true
6 changes: 6 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading