A readme explaining how to make neovim work fast
got the clipboard nailed down
4 files changed, +37 -0
+12-0README.md
| @@ -34,6 +34,18 @@ alias nv=nvim | ||
| 34 | 34 | alias vim=nvim |
| 35 | 35 | ``` |
| 36 | 36 | |
| 37 | +- Set up win32yank for wsl to paste like an absolute gangster | |
| 38 | + - Note use yanky `<leader>p` to paste if you delete before pasting cuz we use unnamedplus default keyboard | |
| 39 | + | |
| 40 | +```bash | |
| 41 | +curl -o win32yank.zip https://github.com/equalsraf/win32yank/releases/download/v0.1.1/win32yank-x86.zip -L | |
| 42 | +unzip win32yank.zip | |
| 43 | +chmod +x win32yank.exe | |
| 44 | +sudo mkdir /mnt/c/tools/ | |
| 45 | +sudo cp win32yank.exe /mnt/c/tools/ | |
| 46 | +rm win32yank* | |
| 47 | +``` | |
| 48 | + | |
| 37 | 49 | ## Tmux like a pro |
| 38 | 50 | |
| 39 | 51 | - Add this to .tmux.conf |
+4-0bashrc.sh
| @@ -2,6 +2,10 @@ | ||
| 2 | 2 | alias nvim='~/nvim.appimage' |
| 3 | 3 | alias vim=nvim |
| 4 | 4 | alias nv=nvim |
| 5 | +export EDITOR=~/nvim.appimage | |
| 5 | 6 | |
| 6 | 7 | # Make nice fzf for tmux prefix Keys |
| 7 | 8 | alias fzf-tmux-prefix='tmux list-keys -T prefix | grep -Po "(?<=prefix\s).*" | fzf --header="Prefixed Keys" --preview="echo {}" --border --preview-window=down:3:wrap | awk '\''{first = $1; $1=""; print $0}'\'' | sed '\''s/^ //g'\' |
| 9 | + | |
| 10 | +# fzf tools | |
| 11 | +alias fzf-hist='fc -nl | fzf' |
+1-0lazy-lock.json
| @@ -6,6 +6,7 @@ | ||
| 6 | 6 | "Toggleterm": { "branch": "main", "commit": "9a88eae817ef395952e08650b3283726786fb5fb" }, |
| 7 | 7 | "alpha-nvim": { "branch": "main", "commit": "de72250e054e5e691b9736ee30db72c65d560771" }, |
| 8 | 8 | "auto-session": { "branch": "main", "commit": "9725cdd4dc96746ff1e1a8e59c7244852ca886df" }, |
| 9 | + "blink-cmp-copilot": { "branch": "main", "commit": "439cff78780c033aa23cf061d7315314b347e3c1" }, | |
| 9 | 10 | "blink.cmp": { "branch": "main", "commit": "cb5e346d9e0efa7a3eee7fd4da0b690c48d2a98e" }, |
| 10 | 11 | "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, |
| 11 | 12 | "catppuccin": { "branch": "main", "commit": "5b5e3aef9ad7af84f463d17b5479f06b87d5c429" }, |
+20-0lua/config/options.lua
| @@ -5,15 +5,35 @@ | ||
| 5 | 5 | -- disable completions with ai |
| 6 | 6 | vim.g.ai_cmp = false |
| 7 | 7 | |
| 8 | +-- disable swap files, not needed with autosession | |
| 9 | +vim.opt.swapfile = false | |
| 10 | + | |
| 8 | 11 | -- wsl settings |
| 9 | 12 | ---@diagnostic disable-next-line |
| 10 | 13 | if vim.loop.os_uname().release:match("WSL") then |
| 11 | 14 | vim.notify("User is on wsl") |
| 15 | + | |
| 16 | + -- open files in windows | |
| 12 | 17 | ---@diagnostic disable-next-line |
| 13 | 18 | vim.ui.open = function(url) |
| 14 | 19 | local cmd = { "wslview", url } |
| 15 | 20 | vim.fn.jobstart(cmd, { detach = true }) |
| 16 | 21 | end |
| 22 | + | |
| 23 | + -- Fix the clipboard | |
| 24 | + local paste = "powershell.exe -NoProfile -Command Get-Clipboard" | |
| 25 | + paste = 'sh -c "' .. paste .. '"' | |
| 26 | + vim.g.clipboard = { | |
| 27 | + name = "clip-wsl", | |
| 28 | + copy = { | |
| 29 | + ["+"] = "/mnt/c/tools/win32yank.exe -i --clrf", | |
| 30 | + ["*"] = "/mnt/c/tools/win32yank.exe -i --clrf", | |
| 31 | + }, | |
| 32 | + paste = { | |
| 33 | + ["+"] = "/mnt/c/tools/win32yank.exe -o --lf", | |
| 34 | + ["*"] = "/mnt/c/tools/win32yank.exe -o --lf", | |
| 35 | + }, | |
| 36 | + } | |
| 17 | 37 | end |
| 18 | 38 | |
| 19 | 39 | -- disable animations |