remove lvim, update tmux, zsh

This commit is contained in:
neoteny 2021-11-22 18:58:53 +02:00
parent 2feea5ce1e
commit 08e75ea6e9
24 changed files with 4 additions and 306 deletions

View file

@ -57,7 +57,7 @@ ramp-volume-0 = 
[module/archupd]
type = custom/script
exec = ~/.config/bspwm/polybar/scripts/updates-pacman-aur.sh
click-left = kitty -e ~/bin/arch-upd
click-left = alacritty -e ~/bin/arch-upd
interval = 60
[module/wifi-signal]

View file

@ -1,32 +0,0 @@
vim.o.relativenumber = true
lvim.format_on_save = true
lvim.lint_on_save = true
lvim.colorscheme = "onedarker"
-- Default fatures
lvim.builtin.terminal.active = true
lvim.builtin.dashboard.active = true
lvim.builtin.dap.active = true
-- GitSigns
lvim.builtin.gitsigns.opts.current_line_blame = true
lvim.builtin.gitsigns.opts.current_line_blame_opts = { delay = 200 }
-- TreeSitter
lvim.builtin.treesitter.ensure_installed = { "javascript", "typescript", "jsdoc", "yaml", "toml", "lua", "go", "gomod" }
lvim.builtin.treesitter.indent.disable = { "python" }
-- Telescope
lvim.builtin.telescope.defaults.layout_config.prompt_position = "top"
lvim.builtin.telescope.defaults.file_ignore_patterns = { ".git", "node_modules", "target", "env", ".bin" }
-- NvimTree
lvim.builtin.nvimtree.ignore = { ".git", "node_modules", ".bin", "env" }
-- LSP
lvim.lsp.override = { "go", "gopls" }
-- Others
require "user.plugins"
require "user.keymaps"

View file

@ -1,8 +0,0 @@
lvim.lang.go.formatters = {
{ exe = "gofumpt" },
-- { exe = "gofmt" },
{ exe = "goimports" },
}
-- Debugger
require("dap-install").config("go_delve", {})

View file

@ -1,28 +0,0 @@
lvim.lang.javascript.formatters = {
-- { exe = "eslint_d" },
{ exe = "prettierd" },
}
lvim.lang.javascript.linters = {
{ exe = "eslint_d" },
}
-- Debugger
require("dap-install").config("jsnode", {})
-- Lsp
lvim.lang.javascript.lsp.setup.handlers = {
["textDocument/publishDiagnostics"] = function(_, _, p, id, _, cfg)
if p.diagnostics ~= nil then
local i = 1
while i <= #p.diagnostics do
if p.diagnostics[i].code == 80001 then
table.remove(p.diagnostics, i)
else
i = i + 1
end
end
end
vim.lsp.diagnostic.on_publish_diagnostics(_, _, p, id, _, cfg)
end,
}

View file

@ -1,8 +0,0 @@
lvim.lang.lua.formatters = {
{ exe = "stylua" },
}
lvim.lang.lua.linters = {
-- { exe = "luacheck" },
{ exe = "selene" },
}

View file

@ -1,8 +0,0 @@
lvim.lang.python.formatters = {
{ exe = "black" },
{ exe = "isort" },
}
lvim.lang.python.linters = {
{ exe = "flake8" },
}

View file

@ -1,8 +0,0 @@
lvim.lang.typescript.formatters = {
-- { exe = "eslint_d" },
{ exe = "prettierd" },
}
lvim.lang.typescript.linters = {
{ exe = "eslint_d" },
}

View file

@ -1,6 +0,0 @@
{
"go.logging.level": "error",
"go.lintOnSave": "package",
"go.lintTool": "golint",
"go.formatTool": "gofumpt"
}

View file

@ -1,15 +0,0 @@
{
"json.schemas": [
{"url": "https://json.schemastore.org/package.json", "fileMatch": ["package.json"]},
{"url": "http://json.schemastore.org/tsconfig", "fileMatch": ["tsconfig.json", "tsconfig.*.json"]},
{"url": "http://json.schemastore.org/lerna", "fileMatch": ["lerna.json"]},
{"url": "http://json.schemastore.org/babelrc.json", "fileMatch": [".babelrc.json", ".babelrc", "babel.config.json"]},
{"url": "http://json.schemastore.org/eslintrc", "fileMatch": [".eslintrc.json", ".eslintrc"]},
{"url": "https://bucklescript.github.io/bucklescript/docson/build-schema.json", "fileMatch": ["bsconfig.json"]},
{"url": "http://json.schemastore.org/prettierrc", "fileMatch": [".prettierrc", ".prettierrc.json", "prettier.config.json"]},
{"url": "http://json.schemastore.org/now", "fileMatch": ["now.json"]},
{"url": "https://raw.githubusercontent.com/OAI/OpenAPI-Specification/main/schemas/v3.1/schema.json", "fileMatch": ["openapi.json", "swagger.json"]},
{"url": "https://json.schemastore.org/nest-cli.json", "fileMatch": ["nest-cli.json"]},
{"url": "https://json.schemastore.org/nodemon.json", "fileMatch": ["nodemon.json"]}
]
}

View file

@ -1,5 +0,0 @@
{
"python.analysis.typeCheckingMode": "off",
"python.analysis.autoImportCompletions": true,
"python.analysis.diagnosticMode": "workspace"
}

View file

@ -1,10 +0,0 @@
{
"yaml.schemas": {
"https://raw.githubusercontent.com/compose-spec/compose-spec/master/schema/compose-spec.json": ["docker-compose.yml", "docker-compose.yaml"],
"https://json.schemastore.org/yamllint.json": [".yamllint", ".yamllint.yml", ".yamllint.yaml"],
"https://yarnpkg.com/configuration/yarnrc.json": [".yarnrc", ".yarnrc.yml"],
"https://json.schemastore.org/github-action.json": ["*/.github/workflows/**/*.yml", "*/.github/workflows/**/*.yaml" ],
"https://json.schemastore.org/gitlab-ci.json": [".gitlab-ci.yml"],
"https://raw.githubusercontent.com/OAI/OpenAPI-Specification/main/schemas/v3.1/schema.json": ["openapi.yaml", "openapi.yml", "swagger.yml", "swagger.yal"]
}
}

View file

@ -1,8 +0,0 @@
local M = {}
function M.setup()
-- Virtual text
vim.g.dap_virtual_text = true
end
return M

View file

@ -1,12 +0,0 @@
local M = {}
function M.setup()
local ok, lua_dev = pcall(require, "lua-dev")
if not ok then
return
end
lua_dev.setup {}
end
return M

View file

@ -1,16 +0,0 @@
local M = {}
function M.setup()
local ok, tabnine_cfg = pcall(require, "cmp_tabnine.config")
if not ok then
return
end
tabnine_cfg:setup {
max_lines = 1000,
max_num_results = 10,
sort = true,
}
end
return M

View file

@ -1,12 +0,0 @@
local M = {}
function M.setup()
local ok, todo_comments = pcall(require, "todo-comments")
if not ok then
return
end
todo_comments.setup {}
end
return M

View file

@ -1,14 +0,0 @@
local M = {}
function M.setup()
local ok, ts_unit = pcall(require, "ts-unit")
if not ok then
return
end
ts_unit.setup {
keymaps = true,
}
end
return M

View file

@ -1,8 +0,0 @@
local M = {}
function M.setup()
-- GOlang
vim.g["test#go#gotest#optiongs"] = "-v --short"
end
return M

View file

@ -1,27 +0,0 @@
lvim.keys.insert_mode["<C-BS>"] = "<C-w>"
lvim.keys.normal_mode["<C-w>"] = "<cmd>BufferClose<cr>"
lvim.keys.normal_mode["<C-s>"] = "<cmd>w<cr>"
lvim.keys.term_mode["jk"] = "<C-\\><C-n>"
lvim.keys.visual_mode["jk"] = "<esc>"
-- Which key
lvim.builtin.which_key.mappings.l.d = { "<cmd>TroubleToggle<cr>", "Diagnostics" }
lvim.builtin.which_key.mappings.l.R = { "<cmd>TroubleToggle lsp_references<cr>", "References" }
lvim.builtin.which_key.mappings.s.P = { "<cmd>Telescope projects<cr>", "Projects" }
lvim.builtin.which_key.mappings["t"] = {
name = "Test",
t = { "<cmd>Ultest<cr>", "Run tests" },
s = { "<cmd>UltestStop<cr>", "Stop tests" },
c = { "<cmd>UltestClear<cr>", "Clear result" },
n = { "<cmd>UltestNearest<cr>", "Run test" },
o = { "<cmd>UltestOutput<cr>", "Show output" },
j = { "<Plug>(ultest-next-fail)", "Next fail" },
k = { "<Plug>(ultest-prev-fail)", "Prev fail" },
}
-- Beffers
lvim.keys.normal_mode["<A-0>"] = "<cmd>BufferLast<cr>"
local fmt = string.format
for i = 1, 9 do
lvim.keys.normal_mode[fmt("<A-%d>", i)] = fmt("<cmd>BufferGoto %d<cr>", i)
end

View file

@ -1,58 +0,0 @@
lvim.plugins = {
{ "tpope/vim-surround", keys = { "c", "y", "d" }, event = "BufRead" },
{ "folke/trouble.nvim", cmd = "TroubleToggle" },
{
"theHamsta/nvim-dap-virtual-text",
after = "nvim-dap",
config = function()
require("plug.dap").setup()
end,
},
{
"kristijanhusak/orgmode.nvim",
ft = "org",
config = function()
require"orgmode".setup {}
end,
},
{
"folke/todo-comments.nvim",
event = "BufRead",
config = function()
require("plug.todo-comment").setup()
end,
},
{
"tzachar/cmp-tabnine",
run = "./install.sh",
event = "InsertEnter",
config = function()
require("plug.tabnine").setup()
end,
},
{
"folke/lua-dev.nvim",
ft = "lua",
config = function()
require("plug.lua-dev").setup()
end,
},
{
"Smirnov-O/ts-unit.nvim",
keys = { "vip", "cip", "yip", "dip" },
config = function()
require("plug.ts-unit").setup { keymaps = true }
end,
},
{
"rcarriga/vim-ultest",
requires = {
{ "vim-test/vim-test", after = "vim-ultest" },
},
cmd = { "Ultest", "UltestStop", "UltestClear", "UltestNearest", "UltestOutput" },
run = ":UpdateRemotePlugins",
config = function()
require("plug.ultest").setup()
end,
},
}

View file

@ -1 +0,0 @@
std="vim"

View file

@ -1,6 +0,0 @@
column_width = 120
line_endings = "Unix"
indent_type = "Spaces"
indent_width = 2
quote_style = "AutoPreferDouble"
no_call_parentheses = true

View file

@ -1,9 +0,0 @@
[selene]
base = "lua52"
name = "vim"
[vim]
any = true
[lvim]
any = true

View file

@ -41,7 +41,7 @@ bind Tab last-window
set -g status-right ' #{?client_prefix,*,} #S '
set -g status-left ' '
set -g status-bg default
set -g status-fg black
set -g status-fg colour254
set -g status-style fg=colour110
#== Pane border colors

7
zshrc
View file

@ -4,10 +4,7 @@
## Variables
export GOPATH="$HOME/go"
export PATH="$HOME/bin:$HOME/.local/bin:$HOME/.golang/bin:$GOPATH/bin:$HOME/.yarn/bin:$HOME/.luarocks/bin:$HOME/.cargo/bin:$PATH"
export EDITOR="lvim"
## FzF
export FZF_DEFAULT_COMMAND="fd -t f -t l -E node_modules -E env -E __pycache__ -E target"
export EDITOR="nvim"
## Oh my zsh
plugins=(git dotenv npm yarn extract)
@ -28,7 +25,7 @@ dotnet() {
## Aliases
alias cls="clear" cp="cp -r" mkdir="mkdir -p" open="open_command" lg="lazygit"
alias v="nvim" vim="v"
alias v="nvim" vim="v" m="make"
alias ...="cd ../.." .3="cd ../../.."
alias gor="go run" gob="go build" gog="go get" goi="go install" got="go test"
alias n="npm" asdfi=". /opt/asdf-vm/asdf.sh"