Skip to content

Commit 443e701

Browse files
committed
myTermux-v.0.4.4 dev
1 parent 4bd24b6 commit 443e701

File tree

17 files changed

+1152
-0
lines changed

17 files changed

+1152
-0
lines changed

.config/nvim/init.lua

Lines changed: 114 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,114 @@
1+
-- load all plugins
2+
require "pluginsList.lua"
3+
require "file-icons.lua"
4+
5+
require "misc-utils.lua"
6+
require "bufferline.lua"
7+
require "statusline.lua"
8+
9+
require("colorizer").setup()
10+
require("neoscroll").setup() -- smooth scroll
11+
12+
-- lsp
13+
require "lspconfig.lua"
14+
require "compe.lua"
15+
16+
local cmd = vim.cmd
17+
local g = vim.g
18+
19+
local colors = {
20+
21+
bg = "#1e222a",
22+
line_bg = "#1e222a",
23+
fg = "#D8DEE9",
24+
fg_green = "#65a380",
25+
yellow = "#A3BE8C",
26+
cyan = "#22262C",
27+
darkblue = "#61afef",
28+
green = "#BBE67E",
29+
orange = "#FF8800",
30+
purple = "#252930",
31+
magenta = "#c678dd",
32+
blue = "#22262C",
33+
-- red = "#DF8890",
34+
-- red = "#FA5AA4",
35+
red = "#FA74B2",
36+
lightbg = "#282c34",
37+
nord = "#81A1C1",
38+
greenYel = "#EBCB8B"
39+
40+
}
41+
42+
g.mapleader = " "
43+
g.auto_save = 1
44+
45+
-- colorscheme related stuff
46+
47+
cmd "syntax enable"
48+
cmd "syntax on"
49+
50+
local base16 = require "base16"
51+
base16(base16.themes["onedark"], true)
52+
53+
-- blankline
54+
55+
local indent = 2
56+
57+
g.indentLine_enabled = 1
58+
g.indent_blankline_char = ""
59+
60+
cmd "hi IndentBlanklineChar guifg=#2a2e36"
61+
62+
g.indent_blankline_filetype_exclude = {"help", "terminal"}
63+
g.indent_blankline_buftype_exclude = {"terminal"}
64+
65+
g.indent_blankline_show_trailing_blankline_indent = false
66+
g.indent_blankline_show_first_indent_level = false
67+
68+
--require "treesitter.lua"
69+
require "mappings.lua"
70+
require "settings.lua"
71+
72+
-- highlights --
73+
cmd "hi LineNr guifg=#42464e guibg=NONE"
74+
cmd "hi Comment guifg=#42464e"
75+
76+
cmd "hi SignColumn guibg=NONE"
77+
cmd "hi VertSplit guibg=NONE guifg=#2a2e36"
78+
cmd "hi EndOfBuffer guifg=#1e222a"
79+
cmd "hi PmenuSel guibg=#98c379"
80+
cmd "hi Pmenu guibg=#282c34"
81+
82+
cmd "hi Normal guibg=NONE ctermbg=NONE"
83+
84+
require "telescope.lua"
85+
require "nvimTree.lua"
86+
87+
-- git signs
88+
require "gitsigns.lua"
89+
90+
require("nvim-autopairs").setup()
91+
92+
require("lspkind").init(
93+
{
94+
with_text = true,
95+
symbol_map = {
96+
Folder = ""
97+
}
98+
}
99+
)
100+
101+
-- hide line numbers in terminal windows
102+
vim.api.nvim_exec([[
103+
au BufEnter term://* setlocal nonumber
104+
]], false)
105+
106+
-- inactive statuslines as thin splitlines
107+
cmd("highlight! StatusLineNC gui=underline guibg=NONE guifg=#D8DEE9")
108+
109+
cmd "hi clear CursorLine"
110+
cmd "hi cursorlinenr guibg=NONE guifg=#D8DEE9"
111+
112+
-- setup for TrueZen.nvim
113+
require "zenmode.lua"
114+
Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
vim.o.termguicolors = true
2+
3+
-- colors for active , inactive uffer tabs
4+
require "bufferline".setup {
5+
options = {
6+
buffer_close_icon = "",
7+
modified_icon = "",
8+
close_icon = "",
9+
left_trunc_marker = "",
10+
right_trunc_marker = "",
11+
max_name_length = 14,
12+
max_prefix_length = 13,
13+
tab_size = 18,
14+
enforce_regular_tabs = true,
15+
view = "multiwindow",
16+
show_buffer_close_icons = true,
17+
separator_style = "thin"
18+
},
19+
highlights = {
20+
background = {
21+
guifg = comment_fg,
22+
guibg = "#1e222a"
23+
},
24+
fill = {
25+
guifg = comment_fg,
26+
guibg = "#1e222a"
27+
},
28+
buffer_selected = {
29+
guifg = normal_fg,
30+
guibg = "#282c34",
31+
gui = "bold"
32+
},
33+
buffer_visible = {
34+
guifg = "#3e4451",
35+
guibg = "#1e222a"
36+
},
37+
separator_visible = {
38+
guifg = "#1e222a",
39+
guibg = "#1e222a"
40+
},
41+
separator_selected = {
42+
guifg = "#1e222a",
43+
guibg = "#1e222a"
44+
},
45+
separator = {
46+
guifg = "#1e222a",
47+
guibg = "#1e222a"
48+
},
49+
indicator_selected = {
50+
guifg = "#1e222a",
51+
guibg = "#1e222a"
52+
},
53+
modified_selected = {
54+
guifg = string_fg,
55+
guibg = "#353b45"
56+
}
57+
}
58+
}
59+
60+
local opt = {silent = true}
61+
62+
vim.g.mapleader = " "
63+
64+
--command that adds new buffer and moves to it
65+
vim.api.nvim_command "com -nargs=? -complete=file_in_path New badd <args> | blast"
66+
vim.api.nvim_set_keymap("n", "<S-b>", ":New ", opt)
67+
68+
--removing a buffer
69+
vim.api.nvim_set_keymap("n", "<S-f>", [[<Cmd>bdelete<CR>]], opt)
70+
71+
-- tabnew and tabprev
72+
vim.api.nvim_set_keymap("n", "<S-l>", [[<Cmd>BufferLineCycleNext<CR>]], opt)
73+
vim.api.nvim_set_keymap("n", "<S-s>", [[<Cmd>BufferLineCyclePrev<CR>]], opt)

.config/nvim/lua/compe/lua.lua

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
vim.cmd [[packadd nvim-lspconfig]]
2+
vim.cmd [[packadd nvim-compe]]
3+
4+
vim.o.completeopt = "menuone,noselect"
5+
6+
require "compe".setup {
7+
enabled = true,
8+
autocomplete = true,
9+
debug = false,
10+
min_length = 1,
11+
preselect = "enable",
12+
throttle_time = 80,
13+
source_timeout = 200,
14+
incomplete_delay = 400,
15+
max_abbr_width = 100,
16+
max_kind_width = 100,
17+
max_menu_width = 100,
18+
documentation = true,
19+
source = {
20+
path = true,
21+
buffer = true,
22+
calc = true,
23+
vsnip = true,
24+
nvim_lsp = true,
25+
nvim_lua = true,
26+
spell = true,
27+
tags = true,
28+
snippets_nvim = true,
29+
treesitter = true
30+
}
31+
}
32+
33+
local t = function(str)
34+
return vim.api.nvim_replace_termcodes(str, true, true, true)
35+
end
36+
37+
local check_back_space = function()
38+
local col = vim.fn.col(".") - 1
39+
if col == 0 or vim.fn.getline("."):sub(col, col):match("%s") then
40+
return true
41+
else
42+
return false
43+
end
44+
end
45+
46+
-- tab completion
47+
48+
_G.tab_complete = function()
49+
if vim.fn.pumvisible() == 1 then
50+
return t "<C-n>"
51+
elseif check_back_space() then
52+
return t "<Tab>"
53+
else
54+
return vim.fn["compe#complete"]()
55+
end
56+
end
57+
_G.s_tab_complete = function()
58+
if vim.fn.pumvisible() == 1 then
59+
return t "<C-p>"
60+
elseif vim.fn.call("vsnip#jumpable", {-1}) == 1 then
61+
return t "<Plug>(vsnip-jump-prev)"
62+
else
63+
return t "<S-Tab>"
64+
end
65+
end
66+
67+
-- mappings
68+
69+
vim.api.nvim_set_keymap("i", "<Tab>", "v:lua.tab_complete()", {expr = true})
70+
vim.api.nvim_set_keymap("s", "<Tab>", "v:lua.tab_complete()", {expr = true})
71+
vim.api.nvim_set_keymap("i", "<S-Tab>", "v:lua.s_tab_complete()", {expr = true})
72+
vim.api.nvim_set_keymap("s", "<S-Tab>", "v:lua.s_tab_complete()", {expr = true})
73+
74+
function _G.completions()
75+
local npairs = require("nvim-autopairs")
76+
if vim.fn.pumvisible() == 1 then
77+
if vim.fn.complete_info()["selected"] ~= -1 then
78+
return vim.fn["compe#confirm"]("<CR>")
79+
end
80+
end
81+
return npairs.check_break_line_char()
82+
end
83+
84+
vim.api.nvim_set_keymap("i", "<CR>", "v:lua.completions()", {expr = true})
Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
vim.cmd [[packadd nvim-web-devicons]]
2+
3+
require "nvim-web-devicons".setup {
4+
override = {
5+
html = {
6+
icon = "",
7+
color = "#DE8C92",
8+
name = "html"
9+
},
10+
css = {
11+
icon = "",
12+
color = "#61afef",
13+
name = "css"
14+
},
15+
js = {
16+
icon = "",
17+
color = "#EBCB8B",
18+
name = "js"
19+
},
20+
ts = {
21+
icon = "",
22+
color = "#519ABA",
23+
name = "ts"
24+
},
25+
kt = {
26+
icon = "󱈙",
27+
color = "#ffcb91",
28+
name = "kt"
29+
},
30+
png = {
31+
icon = "",
32+
color = "#BD77DC",
33+
name = "png"
34+
},
35+
jpg = {
36+
icon = "",
37+
color = "#BD77DC",
38+
name = "jpg"
39+
},
40+
jpeg = {
41+
icon = "",
42+
color = "#BD77DC",
43+
name = "jpeg"
44+
},
45+
mp3 = {
46+
icon = "",
47+
color = "#C8CCD4",
48+
name = "mp3"
49+
},
50+
mp4 = {
51+
icon = "",
52+
color = "#C8CCD4",
53+
name = "mp4"
54+
},
55+
out = {
56+
icon = "",
57+
color = "#C8CCD4",
58+
name = "out"
59+
},
60+
Dockerfile = {
61+
icon = "",
62+
color = "#b8b5ff",
63+
name = "Dockerfile"
64+
},
65+
rb = {
66+
icon = "",
67+
color = "#ff75a0",
68+
name = "rb"
69+
},
70+
vue = {
71+
icon = "",
72+
color = "#7eca9c",
73+
name = "vue"
74+
},
75+
py = {
76+
icon = "",
77+
color = "#a7c5eb",
78+
name = "py"
79+
},
80+
toml = {
81+
icon = "",
82+
color = "#61afef",
83+
name = "toml"
84+
},
85+
lock = {
86+
icon = "",
87+
color = "#DE6B74",
88+
name = "lock"
89+
},
90+
zip = {
91+
icon = "",
92+
color = "#EBCB8B",
93+
name = "zip"
94+
},
95+
xz = {
96+
icon = "",
97+
color = "#EBCB8B",
98+
name = "xz"
99+
}
100+
}
101+
}

0 commit comments

Comments
 (0)