commit
b85b671402
4 changed files with 63 additions and 37 deletions
|
@ -2,7 +2,7 @@
|
||||||
BASE=$(git rev-parse --show-toplevel)
|
BASE=$(git rev-parse --show-toplevel)
|
||||||
LSP_BIN_PATH=$HOME/.local/bin
|
LSP_BIN_PATH=$HOME/.local/bin
|
||||||
|
|
||||||
default_lsp_langs="css html ts rust python bash"
|
default_lsp_langs="css html ts rust python bash json"
|
||||||
lsp_langs=""
|
lsp_langs=""
|
||||||
|
|
||||||
choose_langs() {
|
choose_langs() {
|
||||||
|
@ -103,6 +103,10 @@ install_css() {
|
||||||
install_node_deps vscode-css-languageserver-bin
|
install_node_deps vscode-css-languageserver-bin
|
||||||
}
|
}
|
||||||
|
|
||||||
|
install_json() {
|
||||||
|
install_node_deps vscode-json-languageserver
|
||||||
|
}
|
||||||
|
|
||||||
install_rust() {
|
install_rust() {
|
||||||
if [[ ! -e ~/.local/bin/rust-analyzer ]]; then
|
if [[ ! -e ~/.local/bin/rust-analyzer ]]; then
|
||||||
mkdir -p ${LSP_BIN_PATH}
|
mkdir -p ${LSP_BIN_PATH}
|
||||||
|
|
|
@ -9,19 +9,20 @@ end
|
||||||
local opt = {}
|
local opt = {}
|
||||||
|
|
||||||
-- dont copy any deleted text , this is disabled by default so uncomment the below mappings if you want them!
|
-- dont copy any deleted text , this is disabled by default so uncomment the below mappings if you want them!
|
||||||
--[[
|
--[[ remove this line
|
||||||
|
|
||||||
map("n", "dd", [=[ "_dd ]=], opt)
|
map("n", "dd", [=[ "_dd ]=], opt)
|
||||||
map("v", "dd", [=[ "_dd ]=], opt)
|
map("v", "dd", [=[ "_dd ]=], opt)
|
||||||
map("v", "x", [=[ "_x ]=], opt)
|
map("v", "x", [=[ "_x ]=], opt)
|
||||||
|
|
||||||
]]
|
this line too ]]
|
||||||
|
|
||||||
-- OPEN TERMINALS --
|
-- OPEN TERMINALS --
|
||||||
map("n", "<C-l>", [[<Cmd>vnew term://bash <CR>]], opt) -- open term over right
|
map("n", "<C-l>", [[<Cmd>vnew term://bash <CR>]], opt) -- over right
|
||||||
map("n", "<C-x>", [[<Cmd> split term://bash | resize 10 <CR>]], opt) -- open term bottom
|
map("n", "<C-x>", [[<Cmd> split term://bash | resize 10 <CR>]], opt) -- bottom
|
||||||
|
map("n", "<C-t>t", [[<Cmd> tabnew | term <CR>]], opt) -- newtab
|
||||||
|
|
||||||
-- COPY EVERYTHING --
|
-- COPY EVERYTHING in the file--
|
||||||
map("n", "<C-a>", [[ <Cmd> %y+<CR>]], opt)
|
map("n", "<C-a>", [[ <Cmd> %y+<CR>]], opt)
|
||||||
|
|
||||||
-- toggle numbers ---
|
-- toggle numbers ---
|
||||||
|
@ -30,3 +31,5 @@ map("n", "<leader>n", [[ <Cmd> set nu!<CR>]], opt)
|
||||||
-- toggle truezen.nvim's ataraxis and minimalist mode
|
-- toggle truezen.nvim's ataraxis and minimalist mode
|
||||||
map("n", "<leader>z", [[ <Cmd> TZAtaraxis<CR>]], opt)
|
map("n", "<leader>z", [[ <Cmd> TZAtaraxis<CR>]], opt)
|
||||||
map("n", "<leader>m", [[ <Cmd> TZMinimalist<CR>]], opt)
|
map("n", "<leader>m", [[ <Cmd> TZMinimalist<CR>]], opt)
|
||||||
|
|
||||||
|
map("n", "<C-s>", [[ <Cmd> w <CR>]], opt) -- save
|
||||||
|
|
|
@ -1,77 +1,96 @@
|
||||||
-- colors
|
-- define some colors
|
||||||
|
|
||||||
local bar_fg = "#565c64"
|
local bar_fg = "#565c64"
|
||||||
local activeBuffer_fg = "#c8ccd4"
|
local activeBuffer_fg = "#c8ccd4"
|
||||||
|
|
||||||
require "bufferline".setup {
|
require "bufferline".setup {
|
||||||
options = {
|
options = {
|
||||||
|
offsets = {{filetype = "NvimTree", text = "Explorer"}},
|
||||||
buffer_close_icon = "",
|
buffer_close_icon = "",
|
||||||
modified_icon = "",
|
modified_icon = "",
|
||||||
close_icon = "",
|
close_icon = " ",
|
||||||
left_trunc_marker = "",
|
left_trunc_marker = "",
|
||||||
right_trunc_marker = "",
|
right_trunc_marker = "",
|
||||||
max_name_length = 14,
|
max_name_length = 14,
|
||||||
max_prefix_length = 13,
|
max_prefix_length = 13,
|
||||||
tab_size = 20,
|
tab_size = 20,
|
||||||
enforce_regular_tabs = true,
|
show_tab_indicators = true,
|
||||||
|
enforce_regular_tabs = false,
|
||||||
view = "multiwindow",
|
view = "multiwindow",
|
||||||
show_buffer_close_icons = true,
|
show_buffer_close_icons = true,
|
||||||
separator_style = "thin"
|
separator_style = "thin",
|
||||||
|
mappings = "true"
|
||||||
},
|
},
|
||||||
|
-- bar colors!!
|
||||||
highlights = {
|
highlights = {
|
||||||
background = {
|
|
||||||
guifg = bar_fg,
|
|
||||||
guibg = "#282c34"
|
|
||||||
},
|
|
||||||
fill = {
|
fill = {
|
||||||
guifg = bar_fg,
|
guifg = bar_fg,
|
||||||
guibg = "#282c34"
|
guibg = "#252931"
|
||||||
},
|
},
|
||||||
-- focused window
|
background = {
|
||||||
|
guifg = bar_fg,
|
||||||
|
guibg = "#252931"
|
||||||
|
},
|
||||||
|
-- buffer
|
||||||
buffer_selected = {
|
buffer_selected = {
|
||||||
guifg = activeBuffer_fg,
|
guifg = activeBuffer_fg,
|
||||||
guibg = "#1e222a",
|
guibg = "#1e222a",
|
||||||
gui = "bold"
|
gui = "bold"
|
||||||
},
|
},
|
||||||
|
buffer_visible = {
|
||||||
|
guifg = "#9298a0",
|
||||||
|
guibg = "#252931"
|
||||||
|
},
|
||||||
|
-- tabs over right
|
||||||
|
tab = {
|
||||||
|
guifg = "#9298a0",
|
||||||
|
guibg = "#30343c"
|
||||||
|
},
|
||||||
|
tab_selected = {
|
||||||
|
guifg = "#30343c",
|
||||||
|
guibg = "#9298a0"
|
||||||
|
},
|
||||||
|
tab_close = {
|
||||||
|
guifg = "#f9929b",
|
||||||
|
guibg = "#252931"
|
||||||
|
},
|
||||||
|
-- buffer separators
|
||||||
|
separator = {
|
||||||
|
guifg = "#252931",
|
||||||
|
guibg = "#252931"
|
||||||
|
},
|
||||||
separator_selected = {
|
separator_selected = {
|
||||||
guifg = "#1e222a",
|
guifg = "#1e222a",
|
||||||
guibg = "#1e222a"
|
guibg = "#1e222a"
|
||||||
},
|
},
|
||||||
-- unfocused opened window
|
|
||||||
buffer_visible = {
|
|
||||||
guifg = "#9298a0",
|
|
||||||
guibg = "#282c34"
|
|
||||||
},
|
|
||||||
separator_visible = {
|
separator_visible = {
|
||||||
guifg = "#282c34",
|
guifg = "#252931",
|
||||||
guibg = "#282c34"
|
guibg = "#252931"
|
||||||
},
|
|
||||||
separator = {
|
|
||||||
guifg = "#282c34",
|
|
||||||
guibg = "#282c34"
|
|
||||||
},
|
},
|
||||||
indicator_selected = {
|
indicator_selected = {
|
||||||
guifg = "#282c34",
|
guifg = "#252931",
|
||||||
guibg = "#282c34"
|
guibg = "#252931"
|
||||||
},
|
},
|
||||||
|
-- modified files (but not saved)
|
||||||
modified_selected = {
|
modified_selected = {
|
||||||
guifg = "#A3BE8C",
|
guifg = "#A3BE8C",
|
||||||
guibg = "#1e222a"
|
guibg = "#1e222a"
|
||||||
|
},
|
||||||
|
modified_visible = {
|
||||||
|
guifg = "#BF616A",
|
||||||
|
guibg = "#23272f"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
local opt = {silent = true}
|
local opt = {silent = true}
|
||||||
|
|
||||||
local map = vim.api.nvim_set_keymap
|
local map = vim.api.nvim_set_keymap
|
||||||
vim.g.mapleader = " "
|
vim.g.mapleader = " "
|
||||||
|
|
||||||
--command that adds new buffer and moves to it
|
-- MAPPINGS
|
||||||
map("n", "<S-t>", [[<Cmd>tabnew<CR>]], opt)
|
map("n", "<S-t>", [[<Cmd>tabnew<CR>]], opt) -- new tab
|
||||||
|
map("n", "<S-x>", [[<Cmd>bdelete<CR>]], opt) -- close tab
|
||||||
|
|
||||||
--removing a buffer
|
-- move between tabs
|
||||||
map("n", "<S-x>", [[<Cmd>bdelete<CR>]], opt)
|
|
||||||
|
|
||||||
-- tabnew and tabprev
|
|
||||||
map("n", "<TAB>", [[<Cmd>BufferLineCycleNext<CR>]], opt)
|
map("n", "<TAB>", [[<Cmd>BufferLineCycleNext<CR>]], opt)
|
||||||
map("n", "<S-TAB>", [[<Cmd>BufferLineCyclePrev<CR>]], opt)
|
map("n", "<S-TAB>", [[<Cmd>BufferLineCyclePrev<CR>]], opt)
|
||||||
|
|
|
@ -30,7 +30,7 @@ true_zen.setup(
|
||||||
hidden_signcolumn = "no",
|
hidden_signcolumn = "no",
|
||||||
shown_number = true,
|
shown_number = true,
|
||||||
shown_relativenumber = false,
|
shown_relativenumber = false,
|
||||||
shown_signcolumn = "no"
|
shown_signcolumn = "yes"
|
||||||
},
|
},
|
||||||
ataraxis = {
|
ataraxis = {
|
||||||
just_do_it_for_me = false,
|
just_do_it_for_me = false,
|
||||||
|
|
Loading…
Reference in a new issue