From e06226519007bd5b4b0d8ae9e6ec674eb71f67e4 Mon Sep 17 00:00:00 2001 From: Elias Almqvist Date: Tue, 22 Aug 2023 20:55:31 +0200 Subject: [PATCH 1/4] Packer --- nvim/.config/nvim/lua/evim/packer.lua | 2 +- nvim/.config/nvim/plugin/packer_compiled.lua | 16 ++++++++-------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/nvim/.config/nvim/lua/evim/packer.lua b/nvim/.config/nvim/lua/evim/packer.lua index f9a866b..829331d 100644 --- a/nvim/.config/nvim/lua/evim/packer.lua +++ b/nvim/.config/nvim/lua/evim/packer.lua @@ -16,7 +16,7 @@ vim.cmd [[packadd packer.nvim]] return require("packer").startup(function(use) -- Core use "wbthomason/packer.nvim" - use("nvim-treesitter/nvim-treesitter", { run = ":TSUpdate" }) + -- use("nvim-treesitter/nvim-treesitter", { run = ":TSUpdate" }) use { "nvim-telescope/telescope.nvim", tag = "0.1.1", requires = { { "nvim-lua/plenary.nvim" } } diff --git a/nvim/.config/nvim/plugin/packer_compiled.lua b/nvim/.config/nvim/plugin/packer_compiled.lua index e242278..905aad9 100644 --- a/nvim/.config/nvim/plugin/packer_compiled.lua +++ b/nvim/.config/nvim/plugin/packer_compiled.lua @@ -197,14 +197,6 @@ _G.packer_plugins = { } time([[Defining packer_plugins]], false) --- Config for: Comment.nvim -time([[Config for Comment.nvim]], true) -try_loadstring("\27LJ\2\n5\0\0\3\0\3\0\0066\0\0\0'\2\1\0B\0\2\0029\0\2\0B\0\1\1K\0\1\0\nsetup\fComment\frequire\0", "config", "Comment.nvim") -time([[Config for Comment.nvim]], false) --- Config for: gitsigns.nvim -time([[Config for gitsigns.nvim]], true) -try_loadstring("\27LJ\2\n6\0\0\3\0\3\0\0066\0\0\0'\2\1\0B\0\2\0029\0\2\0B\0\1\1K\0\1\0\nsetup\rgitsigns\frequire\0", "config", "gitsigns.nvim") -time([[Config for gitsigns.nvim]], false) -- Config for: nvim-autopairs time([[Config for nvim-autopairs]], true) try_loadstring("\27LJ\2\n@\0\0\3\0\3\0\a6\0\0\0'\2\1\0B\0\2\0029\0\2\0004\2\0\0B\0\2\1K\0\1\0\nsetup\19nvim-autopairs\frequire\0", "config", "nvim-autopairs") @@ -213,6 +205,14 @@ time([[Config for nvim-autopairs]], false) time([[Config for todo-comments.nvim]], true) try_loadstring("\27LJ\2\n?\0\0\3\0\3\0\a6\0\0\0'\2\1\0B\0\2\0029\0\2\0004\2\0\0B\0\2\1K\0\1\0\nsetup\18todo-comments\frequire\0", "config", "todo-comments.nvim") time([[Config for todo-comments.nvim]], false) +-- Config for: gitsigns.nvim +time([[Config for gitsigns.nvim]], true) +try_loadstring("\27LJ\2\n6\0\0\3\0\3\0\0066\0\0\0'\2\1\0B\0\2\0029\0\2\0B\0\1\1K\0\1\0\nsetup\rgitsigns\frequire\0", "config", "gitsigns.nvim") +time([[Config for gitsigns.nvim]], false) +-- Config for: Comment.nvim +time([[Config for Comment.nvim]], true) +try_loadstring("\27LJ\2\n5\0\0\3\0\3\0\0066\0\0\0'\2\1\0B\0\2\0029\0\2\0B\0\1\1K\0\1\0\nsetup\fComment\frequire\0", "config", "Comment.nvim") +time([[Config for Comment.nvim]], false) _G._packer.inside_compile = false if _G._packer.needs_bufread == true then From 71eacfcc902b8def93f7eee7ff5472d5f9bf04a6 Mon Sep 17 00:00:00 2001 From: Elias Almqvist Date: Sun, 3 Sep 2023 21:32:38 +0200 Subject: [PATCH 2/4] Stuff --- eww/.config/eww/eww.yuck | 2 +- leftwm/.config/leftwm/config.ron | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/eww/.config/eww/eww.yuck b/eww/.config/eww/eww.yuck index 94bb22b..d0a21d7 100644 --- a/eww/.config/eww/eww.yuck +++ b/eww/.config/eww/eww.yuck @@ -82,7 +82,7 @@ )) (button :class "icon logo ${power ? 'logo-seperator' : ''}" :tooltip "Open menu" - :onclick "${EWW_CMD} update power=true" "󰘧") + :onclick "${EWW_CMD} update power=true" "Λ") ))) (defvar power false) diff --git a/leftwm/.config/leftwm/config.ron b/leftwm/.config/leftwm/config.ron index 260d5f9..1db41db 100644 --- a/leftwm/.config/leftwm/config.ron +++ b/leftwm/.config/leftwm/config.ron @@ -57,7 +57,7 @@ layout_mode: Tag, insert_behavior: Bottom, scratchpad: [ - (name: "Qalc", value: "alacritty -e qalc", x: 760, y: 415, height: 250, width: 400), + (name: "Qalc", value: "alacritty -e qalc -t", x: 760, y: 415, height: 250, width: 400), ], window_rules: [], disable_current_tag_swap: true, From d0afbd2736c62835b03cca311aa0f0940b4e2b10 Mon Sep 17 00:00:00 2001 From: Elias Almqvist Date: Wed, 6 Sep 2023 15:17:08 +0200 Subject: [PATCH 3/4] NeoVim stuff --- nvim/.config/nvim/lua/evim/packer.lua | 5 ++- nvim/.config/nvim/plugin/after/vimtex.lua | 35 ++++++++++++++++++++ nvim/.config/nvim/plugin/packer_compiled.lua | 17 ++++++---- 3 files changed, 50 insertions(+), 7 deletions(-) create mode 100644 nvim/.config/nvim/plugin/after/vimtex.lua diff --git a/nvim/.config/nvim/lua/evim/packer.lua b/nvim/.config/nvim/lua/evim/packer.lua index 829331d..44aa6a9 100644 --- a/nvim/.config/nvim/lua/evim/packer.lua +++ b/nvim/.config/nvim/lua/evim/packer.lua @@ -16,7 +16,7 @@ vim.cmd [[packadd packer.nvim]] return require("packer").startup(function(use) -- Core use "wbthomason/packer.nvim" - -- use("nvim-treesitter/nvim-treesitter", { run = ":TSUpdate" }) + use("nvim-treesitter/nvim-treesitter", { run = ":TSUpdate" }) use { "nvim-telescope/telescope.nvim", tag = "0.1.1", requires = { { "nvim-lua/plenary.nvim" } } @@ -84,6 +84,9 @@ return require("packer").startup(function(use) end } + -- Lang stuff / cool stuff + use "lervag/vimtex" + if packer_bootstrap then require("packer").sync() end diff --git a/nvim/.config/nvim/plugin/after/vimtex.lua b/nvim/.config/nvim/plugin/after/vimtex.lua new file mode 100644 index 0000000..4de9a07 --- /dev/null +++ b/nvim/.config/nvim/plugin/after/vimtex.lua @@ -0,0 +1,35 @@ +-- Otherwise the plugin wont work +vim.cmd("filetype plugin indent on") + +-- Viewer options: One may configure the viewer either by specifying a built-in viewer method: +vim.g.vimtex_view_method = "zathura" + +-- Or with a generic interface: +-- vim.g.vimtex_view_general_viewer = "okular" +-- vim.g.vimtex_view_general_options = "--unique file:@pdf#src:@line@tex" + +-- VimTeX uses latexmk as the default compiler backend. If you use it, which is strongly recommended, you probably don"t need to configure anything. If you want another compiler backend, you can change it as follows. The list of supported backends and further explanation is provided in the documentation, see ":help vimtex-compiler". +vim.g.vimtex_compiler_method = "latexrun" + +-- Most VimTeX mappings rely on localleader and this can be changed with the following line. The default is usually fine and is the symbol "\". +vim.g.maplocalleader = "," + +-- Set the TEX flavor to 'latex' +vim.g.tex_flavor = 'latex' + +-- Disable vimtex quickfix mode +vim.g.vimtex_quickfix_mode = 0 + +-- Set conceallevel to 1 +vim.o.conceallevel = 1 + +-- Configure TEX conceal settings +vim.g.tex_conceal = 'abdmg' + +-- Automatically update the PDF when saving a TeX file +vim.api.nvim_exec([[ + augroup auto_update_pdf + autocmd! + autocmd BufWritePost *.tex VimtexCompile + augroup END +]], true) diff --git a/nvim/.config/nvim/plugin/packer_compiled.lua b/nvim/.config/nvim/plugin/packer_compiled.lua index 905aad9..4e0ea93 100644 --- a/nvim/.config/nvim/plugin/packer_compiled.lua +++ b/nvim/.config/nvim/plugin/packer_compiled.lua @@ -49,8 +49,8 @@ local function save_profiles(threshold) end time([[Luarocks path setup]], true) -local package_path_str = "/home/elal/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?.lua;/home/elal/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?/init.lua;/home/elal/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?.lua;/home/elal/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?/init.lua" -local install_cpath_pattern = "/home/elal/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/lua/5.1/?.so" +local package_path_str = "/home/elal/.cache/nvim/packer_hererocks/2.1.1692616192/share/lua/5.1/?.lua;/home/elal/.cache/nvim/packer_hererocks/2.1.1692616192/share/lua/5.1/?/init.lua;/home/elal/.cache/nvim/packer_hererocks/2.1.1692616192/lib/luarocks/rocks-5.1/?.lua;/home/elal/.cache/nvim/packer_hererocks/2.1.1692616192/lib/luarocks/rocks-5.1/?/init.lua" +local install_cpath_pattern = "/home/elal/.cache/nvim/packer_hererocks/2.1.1692616192/lib/lua/5.1/?.so" if not string.find(package.path, package_path_str, 1, true) then package.path = package.path .. ';' .. package_path_str end @@ -193,6 +193,11 @@ _G.packer_plugins = { loaded = true, path = "/home/elal/.local/share/nvim/site/pack/packer/start/todo-comments.nvim", url = "https://github.com/folke/todo-comments.nvim" + }, + vimtex = { + loaded = true, + path = "/home/elal/.local/share/nvim/site/pack/packer/start/vimtex", + url = "https://github.com/lervag/vimtex" } } @@ -201,10 +206,6 @@ time([[Defining packer_plugins]], false) time([[Config for nvim-autopairs]], true) try_loadstring("\27LJ\2\n@\0\0\3\0\3\0\a6\0\0\0'\2\1\0B\0\2\0029\0\2\0004\2\0\0B\0\2\1K\0\1\0\nsetup\19nvim-autopairs\frequire\0", "config", "nvim-autopairs") time([[Config for nvim-autopairs]], false) --- Config for: todo-comments.nvim -time([[Config for todo-comments.nvim]], true) -try_loadstring("\27LJ\2\n?\0\0\3\0\3\0\a6\0\0\0'\2\1\0B\0\2\0029\0\2\0004\2\0\0B\0\2\1K\0\1\0\nsetup\18todo-comments\frequire\0", "config", "todo-comments.nvim") -time([[Config for todo-comments.nvim]], false) -- Config for: gitsigns.nvim time([[Config for gitsigns.nvim]], true) try_loadstring("\27LJ\2\n6\0\0\3\0\3\0\0066\0\0\0'\2\1\0B\0\2\0029\0\2\0B\0\1\1K\0\1\0\nsetup\rgitsigns\frequire\0", "config", "gitsigns.nvim") @@ -213,6 +214,10 @@ time([[Config for gitsigns.nvim]], false) time([[Config for Comment.nvim]], true) try_loadstring("\27LJ\2\n5\0\0\3\0\3\0\0066\0\0\0'\2\1\0B\0\2\0029\0\2\0B\0\1\1K\0\1\0\nsetup\fComment\frequire\0", "config", "Comment.nvim") time([[Config for Comment.nvim]], false) +-- Config for: todo-comments.nvim +time([[Config for todo-comments.nvim]], true) +try_loadstring("\27LJ\2\n?\0\0\3\0\3\0\a6\0\0\0'\2\1\0B\0\2\0029\0\2\0004\2\0\0B\0\2\1K\0\1\0\nsetup\18todo-comments\frequire\0", "config", "todo-comments.nvim") +time([[Config for todo-comments.nvim]], false) _G._packer.inside_compile = false if _G._packer.needs_bufread == true then From 08ba70fe80419c99ae83ffdf1bf8971a4d5f251f Mon Sep 17 00:00:00 2001 From: Elias Almqvist Date: Thu, 7 Sep 2023 10:45:30 +0200 Subject: [PATCH 4/4] Add vscode settings for remote work --- code/.config/Code/User/keybindings.json | 12 +++++ code/.config/Code/User/settings.json | 71 +++++++++++++++++++++++++ 2 files changed, 83 insertions(+) create mode 100644 code/.config/Code/User/keybindings.json create mode 100644 code/.config/Code/User/settings.json diff --git a/code/.config/Code/User/keybindings.json b/code/.config/Code/User/keybindings.json new file mode 100644 index 0000000..88d2194 --- /dev/null +++ b/code/.config/Code/User/keybindings.json @@ -0,0 +1,12 @@ +// Place your key bindings in this file to override the defaultsauto[] +[ + { + "key": "ctrl+w", + "command": "-workbench.action.closeActiveEditor" + }, + { + "key": "ctrl+w", + "command": "-workbench.action.terminal.killEditor", + "when": "terminalEditorFocus && terminalFocus && terminalHasBeenCreated && resourceScheme == 'vscode-terminal' || terminalEditorFocus && terminalFocus && terminalProcessSupported && resourceScheme == 'vscode-terminal'" + } +] \ No newline at end of file diff --git a/code/.config/Code/User/settings.json b/code/.config/Code/User/settings.json new file mode 100644 index 0000000..ec08ad9 --- /dev/null +++ b/code/.config/Code/User/settings.json @@ -0,0 +1,71 @@ +{ + "telemetry.telemetryLevel": "off", + "editor.insertSpaces": false, + "editor.detectIndentation": false, + "explorer.confirmDelete": false, + "git.openRepositoryInParentFolders": "never", + "workbench.editorAssociations": { + "*.sqlite": "default" + }, + "workbench.startupEditor": "none", + "editor.minimap.enabled": false, + "breadcrumbs.enabled": false, + "editor.renderWhitespace": "none", + "window.menuBarVisibility": "toggle", + "workbench.activityBar.visible": false, + "editor.fontFamily": "Fira Code, 'Droid Sans Mono', 'monospace', monospace", + "window.zoomLevel": -1, + "jupyter.askForKernelRestart": false, + "vim.normalModeKeyBindingsNonRecursive": [ + { + "before": ["u"], + "commands": ["undo"] + }, + { + "before": ["c-r"], + "commands": ["redo"] + }, + { + "before": ["", "t"], + "commands": ["workbench.action.toggleSidebarVisibility"] + }, + { + "before": ["g", "s"], + "commands": ["workbench.action.showAllSymbols"] + }, + { + "before": ["g", "a"], + "commands": ["references-view.findReferences"] + }, + { + "before": ["g", "r"], + "commands": ["editor.action.rename"] + }, + { + "before": ["g", "w"], + "commands": ["editor.emmet.action.wrapWithAbbreviation"] + } + ], + "vim.visualModeKeyBindingsNonRecursive": [ + { + "before": ["g", "r"], + "commands": ["git.revertSelectedRanges"] + }, + { + "before": ["g", "w"], + "commands": ["editor.emmet.action.wrapWithAbbreviation"] + }, + { + "before": ["c-"], + "commands": ["editor.action.triggerSuggest"] + } + ], + "editor.mouseWheelScrollSensitivity": 2, + "editor.smoothScrolling": true, + "workbench.list.smoothScrolling": true, + "terminal.integrated.smoothScrolling": true, + "editor.cursorSmoothCaretAnimation": "on", + "[latex]": { + "editor.defaultFormatter": "mathematic.vscode-latex" + }, +} \ No newline at end of file