summaryrefslogtreecommitdiff
path: root/nvim/lua/myplugins
diff options
context:
space:
mode:
author2025-06-09 13:43:45 +0300
committer2025-06-09 13:55:38 +0300
commit97af93b2a8ebc89364852e3f63e9fd8cfedaeedf (patch)
tree27e2added74ee6c0ff91c9e7927491c661a8bb36 /nvim/lua/myplugins
parent04.06.2025 (diff)
downloaddotfiles-97af93b2a8ebc89364852e3f63e9fd8cfedaeedf.tar.gz
dotfiles-97af93b2a8ebc89364852e3f63e9fd8cfedaeedf.tar.bz2
dotfiles-97af93b2a8ebc89364852e3f63e9fd8cfedaeedf.tar.xz
dotfiles-97af93b2a8ebc89364852e3f63e9fd8cfedaeedf.zip
Перевёл dotfiles на stow
Diffstat (limited to 'nvim/lua/myplugins')
-rw-r--r--nvim/lua/myplugins/resize.lua97
1 files changed, 0 insertions, 97 deletions
diff --git a/nvim/lua/myplugins/resize.lua b/nvim/lua/myplugins/resize.lua
deleted file mode 100644
index 8af6c3b..0000000
--- a/nvim/lua/myplugins/resize.lua
+++ /dev/null
@@ -1,97 +0,0 @@
-local M = {}
-
-M.setup = function(opts) end
-
-M.isRightMost = function()
- local curWin = vim.fn.winnr()
- vim.cmd([[wincmd l]])
- local rightWin = vim.fn.winnr()
- if curWin == rightWin then
- return true
- else
- vim.cmd([[wincmd h]])
- return false
- end
-end
-
-M.isLeftMost = function()
- local curWin = vim.fn.winnr()
- vim.cmd([[wincmd h]])
- local leftWin = vim.fn.winnr()
- if curWin == leftWin then
- return true
- else
- vim.cmd([[wincmd l]])
- return false
- end
-end
-
-M.isBottomMost = function()
- local curWin = vim.fn.winnr()
- vim.cmd([[wincmd j]])
- local bottomWin = vim.fn.winnr()
- if curWin == bottomWin then
- return true
- else
- vim.cmd([[wincmd k]])
- return false
- end
-end
-
-M.isTopMost = function()
- local curWin = vim.fn.winnr()
- vim.cmd([[wincmd k]])
- local topWin = vim.fn.winnr()
- if curWin == topWin then
- return true
- else
- vim.cmd([[wincmd j]])
- return false
- end
-end
-
-M.ResizeLeft = function()
- if M.isRightMost() then
- if not M.isLeftMost() then
- vim.cmd([[wincmd 5 >]])
- end
- else
- vim.cmd([[wincmd 5 <]])
- end
-end
-
-M.ResizeRight = function()
- if M.isRightMost() then
- if not M.isLeftMost() then
- vim.cmd([[wincmd 5 <]])
- end
- else
- vim.cmd([[wincmd 5 >]])
- end
-end
-
-M.ResizeUp = function()
- if M.isBottomMost() then
- if not M.isTopMost() then
- vim.cmd([[wincmd 5 +]])
- else
- vim.cmd([[wincmd 5 -]])
- end
- else
- vim.cmd([[wincmd 5 -]])
- end
-end
-
-M.ResizeDown = function()
- if M.isBottomMost() then
- if not M.isTopMost() then
- vim.cmd([[wincmd 5 -]])
- else
- vim.cmd([[wincmd 5 +]])
- end
- else
- vim.cmd([[wincmd 5 +]])
- end
-end
-
-return M