Skip to content

Commit

Permalink
chore: using mini.operators and disabling subversive plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
shubham-cpp committed Dec 24, 2024
1 parent aa72bb4 commit 2f513c3
Show file tree
Hide file tree
Showing 13 changed files with 35 additions and 24 deletions.
2 changes: 1 addition & 1 deletion .config/nvim-astro/after/plugin/options.lua
Original file line number Diff line number Diff line change
Expand Up @@ -46,5 +46,5 @@ o.wildignore:append {
}

if vim.fn.executable "rg" == 1 then
o.grepprg = "rg --vimgrep -uu --smart-case" -- Also check RIPGREP_CONFIG_PATH="$HOME/.config/ripgreprc"
o.grepprg = "rg --vimgrep -uu --smart-case -g '!{.git/,node_modules/,android/,ios/,dist/,vendor/}'" -- Also check RIPGREP_CONFIG_PATH="$HOME/.config/ripgreprc"
end
1 change: 0 additions & 1 deletion .config/nvim-astro/lua/plugins/astrolsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ return {
-- pyright = function(_, opts) require("lspconfig").pyright.setup(opts) end -- or a custom handler function can be passed
emmet_ls = function(_, opts)
opts.on_attach = function(client, bufnr)
vim.print "in the on_attach of emmet"
vim.keymap.set("i", "<C-t>", function()
client.request(
"textDocument/completion",
Expand Down
2 changes: 1 addition & 1 deletion .config/nvim-astro/lua/plugins/astroui.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ return {
opts = {
status = {
colors = {
buffer_active_bg = "#173063",
buffer_active_bg = "#182b3f",
},
},
},
Expand Down
2 changes: 1 addition & 1 deletion .config/nvim-astro/lua/plugins/mini/move.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ return {
{ ">", mode = "v" },
{ "<", mode = "v" },
{ "K", mode = "v" },
{ "L", mode = "v" },
{ "J", mode = "v" },
"<M-h>",
"<M-j>",
"<M-k>",
Expand Down
4 changes: 2 additions & 2 deletions .config/nvim-astro/lua/plugins/mini/operators.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ return {
{ "g=", mode = { "n", "x" }, desc = "Evalute" },
{ "ge", mode = { "n", "x" }, desc = "Exchange" },
{ "gm", mode = { "n", "x" }, desc = "Duplicate" },
{ "gR", mode = { "n", "x" }, desc = "Replace with register" },
{ "gy", mode = { "n", "x" }, desc = "Replace with register" },
{ "gs", mode = { "n", "x" }, desc = "Sort" },
},
opts = {
-- Exchange text regions
exchange = { prefix = "ge" },
replace = { prefix = "gR" },
replace = { prefix = "gy" },
},
config = function(_, opts) require("mini.operators").setup(opts) end,
}
1 change: 1 addition & 0 deletions .config/nvim-astro/lua/plugins/subversive.lua
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---@type LazySpec
return {
"svermeulen/vim-subversive",
enabled = false,
keys = {
{ "x", "<Plug>(SubversiveSubstitute)", noremap = false },
{ "X", "<Plug>(SubversiveSubstituteToEndOfLine)", noremap = false },
Expand Down
4 changes: 4 additions & 0 deletions .config/nvim-lazy/lua/config/options.lua
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,7 @@ vim.opt.wildignore:append({
"vendor",
".git",
})

if vim.fn.executable("rg") == 1 then
vim.opt.grepprg = "rg --vimgrep --smart-case" -- Also check RIPGREP_CONFIG_PATH="$HOME/.config/ripgreprc"
end
20 changes: 10 additions & 10 deletions .config/nvim-lazy/lua/plugins/mini/operators.lua
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
---@type LazySpec
return {
'echasnovski/mini.operators',
version = '*',
"echasnovski/mini.operators",
version = "*",
enabled = true,
keys = {
{ 'g=', mode = { 'n', 'x' }, desc = 'Evalute' },
{ 'ge', mode = { 'n', 'x' }, desc = 'Exchange' },
{ 'gm', mode = { 'n', 'x' }, desc = 'Duplicate' },
{ 'gR', mode = { 'n', 'x' }, desc = 'Replace with register' },
{ 'gs', mode = { 'n', 'x' }, desc = 'Sort' },
{ "g=", mode = { "n", "x" }, desc = "Evalute" },
{ "ge", mode = { "n", "x" }, desc = "Exchange" },
{ "gm", mode = { "n", "x" }, desc = "Duplicate" },
{ "gy", mode = { "n", "x" }, desc = "Replace with register" },
{ "gs", mode = { "n", "x" }, desc = "Sort" },
},
opts = {
-- Exchange text regions
exchange = { prefix = 'ge' },
replace = { prefix = 'gR' },
exchange = { prefix = "ge" },
replace = { prefix = "gy" },
},
config = function(_, opts)
require('mini.operators').setup(opts)
require("mini.operators").setup(opts)
end,
}
1 change: 1 addition & 0 deletions .config/nvim-lazy/lua/plugins/subversive.lua
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---@type LazySpec
return {
"svermeulen/vim-subversive",
enabled = false,
keys = {
{ "x", "<Plug>(SubversiveSubstitute)", noremap = false },
{ "X", "<Plug>(SubversiveSubstituteToEndOfLine)", noremap = false },
Expand Down
2 changes: 1 addition & 1 deletion .config/nvim/after/plugin/options.lua
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ o.iskeyword:append '-'

if vim.fn.executable 'rg' == 1 then
o.grepformat = '%f:%l:%c:%m'
o.grepprg = 'rg --vimgrep --no-heading --smart-case' -- Also check RIPGREP_CONFIG_PATH="$HOME/.config/ripgreprc"
o.grepprg = 'rg --vimgrep --smart-case' -- Also check RIPGREP_CONFIG_PATH="$HOME/.config/ripgreprc"
end

vim.schedule(function()
Expand Down
4 changes: 2 additions & 2 deletions .config/nvim/lua/plugins/mini/operators.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ return {
{ 'g=', mode = { 'n', 'x' }, desc = 'Evalute' },
{ 'ge', mode = { 'n', 'x' }, desc = 'Exchange' },
{ 'gm', mode = { 'n', 'x' }, desc = 'Duplicate' },
{ 'gR', mode = { 'n', 'x' }, desc = 'Replace with register' },
{ 'gy', mode = { 'n', 'x' }, desc = 'Replace with register' },
{ 'gs', mode = { 'n', 'x' }, desc = 'Sort' },
},
opts = {
-- Exchange text regions
exchange = { prefix = 'ge' },
replace = { prefix = 'gR' },
replace = { prefix = 'gy' },
},
config = function(_, opts)
require('mini.operators').setup(opts)
Expand Down
2 changes: 2 additions & 0 deletions .config/nvim/lua/plugins/subversive.lua
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
---@type LazySpec
return {
'svermeulen/vim-subversive',
enabled = false,
keys = {
{ 'x', '<Plug>(SubversiveSubstitute)', noremap = false },
{ 'X', '<Plug>(SubversiveSubstituteToEndOfLine)', noremap = false },
Expand Down
14 changes: 9 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
# Personal Dotfiles

## Main
- WM :- [Awesomewm](.config/awesome/README.md)
- Terminal :- Kitty(main) & xterm(secondary)
- Editor :- [Neovim](https://github.com/shubham-cpp/dotfiles/tree/main/.config/nvim)\([nightly](https://github.com/neovim/neovim/wiki/Building-Neovim)\)
- Shell :- Zsh
- Run launcher :- [dmenu_run_history](https://tools.suckless.org/dmenu/scripts/dmenu_run_with_command_history) and rofi

- WM :- [Hyprland](.config/hyprland)
- DE :- KDE
- Terminal :- Kitty(main) & alacritty(secondary)
- Editor :- [Neovim](https://github.com/shubham-cpp/dotfiles/tree/main/.config/nvim)
- Shell :- Fish
- OS :- [CachyOS](https://cachyos.org/)
- Run launcher :- [rofi](https://github.com/lbonn/rofi)(its rofi-wayland)

## Installation

```bash
# Install stow(https://wiki.archlinux.org/title/Dotfiles) :
# A program that i use for dotfile management
Expand Down

0 comments on commit 2f513c3

Please sign in to comment.