From ea9a749bd6238334ff9e92a0a31fdeaf5223619b Mon Sep 17 00:00:00 2001 From: ottjk Date: Sat, 20 Jan 2024 01:29:51 -0500 Subject: many such updates --- .wezterm.lua | 2 +- configs.toml | 66 +++++++++++++++++++++------------------- keybs/kanata.kbd | 4 +-- nvim/after/ftplugin/markdown.lua | 5 --- nvim/lua/keymaps.lua | 6 ++-- nvim/lua/plugins.lua | 4 +++ nvim/snips/tex/expressions.lua | 10 +++--- nvim/snips/tex/symbols.lua | 8 +++++ rofi/config.rasi | 18 +++++++++++ starship/starship.toml | 2 +- sway/config | 20 +++++++++--- tofi/config | 19 ------------ 12 files changed, 93 insertions(+), 71 deletions(-) delete mode 100644 nvim/after/ftplugin/markdown.lua create mode 100644 rofi/config.rasi delete mode 100644 tofi/config diff --git a/.wezterm.lua b/.wezterm.lua index 0b49ff1..f2c23d4 100644 --- a/.wezterm.lua +++ b/.wezterm.lua @@ -51,7 +51,7 @@ config.font_size = 11.0 config.hide_tab_bar_if_only_one_tab = true -config.front_end = "WebGpu" +-- config.front_end = "Software" -- and finally, return the configuration to wezterm return config diff --git a/configs.toml b/configs.toml index 173a874..28828d9 100644 --- a/configs.toml +++ b/configs.toml @@ -1,59 +1,63 @@ -[nvim] -file = "nvim" +[tofi] +file = "tofi" parent = "~/.config" -[kanata] -file = "keybs" +[dunst] +file = "dunst" parent = "~/.config" -[sway] -file = "sway" -parent = "~/.config" +[rofi] +file = "rofi" +parent = "/home/josh/.config" + +[vim] +file = ".vimrc" +parent = "~/" + +[tmux] +file = ".tmux.conf" +parent = "/home/josh/" [wezterm] file = ".wezterm.lua" parent = "~/" -[fish] -file = "config.fish" -parent = "~/.config/fish" - -[waybar] -file = "waybar" +[zathura] +file = "zathura" parent = "~/.config" -[vim] -file = ".vimrc" -parent = "~/" - -[dunst] -file = "dunst" +[starship] +file = "starship" parent = "~/.config" -[zathura] -file = "zathura" +[swaylock] +file = "swaylock" parent = "~/.config" [tex] file = "texmf" parent = "~/" -[starship] -file = "starship" -parent = "~/.config" +[fish] +file = "config.fish" +parent = "~/.config/fish" -[tofi] -file = "tofi" +[sway] +file = "sway" parent = "~/.config" -[tmux] -file = ".tmux.conf" -parent = "/home/josh/" +[waybar] +file = "waybar" +parent = "~/.config" [xplr] file = "xplr" parent = "~/.config" -[swaylock] -file = "swaylock" +[kanata] +file = "keybs" +parent = "~/.config" + +[nvim] +file = "nvim" parent = "~/.config" diff --git a/keybs/kanata.kbd b/keybs/kanata.kbd index 62df002..75bed26 100644 --- a/keybs/kanata.kbd +++ b/keybs/kanata.kbd @@ -90,7 +90,7 @@ esc f1 f2 f3 f4 f5 f6 f7 f8 f9 f10 f11 f12 home end ins (deflayer navigation _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ - _ _ [ ] _ _ _ _ pgdn pgup _ _ _ _ + _ _ [ ] _ _ _ del pgdn pgup _ _ _ _ _ _ @cop @pop @pcl _ _ left down up rght _ _ _ _ _ S-] _ _ _ home end _ _ _ _ _ _ _ _ _ _ _ _ _ _ @@ -101,7 +101,7 @@ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ lrld _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 4 5 6 S-\ _ S-8 S-, S-. _ _ _ _ - tab esc 1 2 3 S-6 _ @meq @mco . / _ _ + _ tab 1 2 3 S-6 _ @meq @mco . / _ _ _ 7 8 9 S-` _ _ - S-- S-+ _ _ _ _ _ _ _ _ _ _ _ _ _ 0 _ _ _ _ _ diff --git a/nvim/after/ftplugin/markdown.lua b/nvim/after/ftplugin/markdown.lua deleted file mode 100644 index 86af50e..0000000 --- a/nvim/after/ftplugin/markdown.lua +++ /dev/null @@ -1,5 +0,0 @@ -local map = vim.keymap.set -local opts = { noremap = false, silent = true} - -map('', 'o', 'Markdown_NewLineBelow', opts) -map('', 'O', 'Markdown_NewLineAbove', opts) diff --git a/nvim/lua/keymaps.lua b/nvim/lua/keymaps.lua index f491651..18b379d 100644 --- a/nvim/lua/keymaps.lua +++ b/nvim/lua/keymaps.lua @@ -74,6 +74,9 @@ map('n', 'vc', ':VimtexClean!') map('i', '', [[: silent exec '.!inkscape-figures create "'.getline('.').'" "'.b:vimtex.root.'/figures/"':w]], opts) map('n', '', [[: silent exec '!inkscape-figures edit "'.b:vimtex.root.'/figures/" > /dev/null 2>&1 &':redraw!]], opts) +map('i', '', [[: silent exec '.!xoppdog shake "'.getline('.').'" "'.b:vimtex.root.'/figures/"':w]], opts) +map('n', '', [[: silent exec '!xoppdog fetch "'.b:vimtex.root.'/figures/" > /dev/null 2>&1 &':redraw!]], opts) + vim.cmd([[ " press to expand or jump in a snippet. These can also be mapped separately " via luasnip-expand-snippet and luasnip-jump-next. @@ -84,5 +87,4 @@ map('i', '', [[lua require'luasnip'.jump(-1)]], opts) map('s', '', [[lua require('luasnip').jump(1)]], opts) map('s', '', [[lua require('luasnip').jump(-1)]], opts) -map('', '', 'Markdown_NewLineAbove', opts) -map('', '', 'Markdown_NewLineBelow', opts) +map('n', 'xx', function() require('trouble').toggle() end) diff --git a/nvim/lua/plugins.lua b/nvim/lua/plugins.lua index 2fb9566..49532d3 100644 --- a/nvim/lua/plugins.lua +++ b/nvim/lua/plugins.lua @@ -71,4 +71,8 @@ require("lazy").setup({ require("hop").setup({ keys = "tnseridhaofuwyplcqxz" }) end, }, + { + 'folke/trouble.nvim', + dependencies = { "nvim-tree/nvim-web-devicons" }, + }, }) diff --git a/nvim/snips/tex/expressions.lua b/nvim/snips/tex/expressions.lua index 2bb6d29..88659eb 100644 --- a/nvim/snips/tex/expressions.lua +++ b/nvim/snips/tex/expressions.lua @@ -26,8 +26,8 @@ local parens = function(_, parent) if open == "'a" then open = "\\langle" end local node = n.sn(1, - n.fmta("\\left<> <> \\right<>", - { n.t(open), n.i(1), n.t(closer(open)) }) + n.fmta("\\left<> <> \\right<><>", + { n.t(open), n.i(1), n.t(closer(open)), n.i(0) }) ) return node end @@ -97,7 +97,7 @@ return { { condition = h.in_mathzone } ), n.s({trig="df", wordTrig=false, snippetType="autosnippet"}, - { n.t("\\diff") }, + { n.t("\\diff ") }, { condition = h.in_mathzone } ), n.s({trig="pf", wordTrig=false, snippetType="autosnippet"}, @@ -133,8 +133,8 @@ return { { condition = h.in_enumerate * h.line_begin } ), n.s({trig = "ceil", snippetType="autosnippet"}, - n.fmta("\\left\\lceil <> \\right\\rceil", - { n.i(1) }), + n.fmta("\\left\\lceil <> \\right\\rceil<>", + { n.i(1), n.i(0) }), { condition = h.in_mathzone } ), n.s({trig = "floor", snippetType="autosnippet"}, diff --git a/nvim/snips/tex/symbols.lua b/nvim/snips/tex/symbols.lua index d42c831..59b505b 100644 --- a/nvim/snips/tex/symbols.lua +++ b/nvim/snips/tex/symbols.lua @@ -246,6 +246,10 @@ return { { n.t("\\rho") }, { condition = h.in_mathzone } ), + n.s({trig="'ch", snippetType="autosnippet"}, + { n.t("\\chi") }, + { condition = h.in_mathzone } + ), n.s({trig="del", snippetType="autosnippet"}, { n.t("\\Del") }, { condition = h.in_mathzone } @@ -330,6 +334,10 @@ return { { n.t("^{\\circ}") }, { condition = h.in_mathzone } ), + n.s({trig="'da", snippetType="autosnippet", wordTrig=false}, + { n.t("^{\\dag}") }, + { condition = h.in_mathzone } + ), n.s({trig="oxx", snippetType="autosnippet"}, { n.t("\\otimes") }, { condition = h.in_mathzone } diff --git a/rofi/config.rasi b/rofi/config.rasi new file mode 100644 index 0000000..a705974 --- /dev/null +++ b/rofi/config.rasi @@ -0,0 +1,18 @@ +configuration{ + modi: "run,drun"; + icon-theme: "Papirus"; + show-icons: true; + terminal: "wezterm"; + drun-display-format: "{icon} {name}"; + location: 0; + disable-history: false; + hide-scrollbar: true; + display-drun: "  Apps "; + display-run: "  Run "; + display-window: " 󰕰 Window"; + display-Network: " 󰤨 Network"; + sidebar-mode: false; +} + +@theme "catppuccin-mocha" + diff --git a/starship/starship.toml b/starship/starship.toml index abadafc..f7a2ad6 100644 --- a/starship/starship.toml +++ b/starship/starship.toml @@ -60,7 +60,7 @@ format = '[@$hostname]($style)' [sudo] disabled = false -symbol = " " +symbol = " " style = "bg:id_color fg:black" format = '[$symbol]($style)' diff --git a/sway/config b/sway/config index 28abbb0..8c8b439 100644 --- a/sway/config +++ b/sway/config @@ -18,10 +18,10 @@ set $right o set $term wezterm -set $menu tofi-drun | xargs swaymsg exec -- +set $menu rofi -show drun | xargs swaymsg exec -- ### Output configuration -# exec way-displays > /tmp/way-displays.${XDG_VTNR}.${USER}.log 2>&1 +exec way-displays > /tmp/way-displays.${XDG_VTNR}.${USER}.log 2>&1 exec swaybg --image ~/Pictures/backgrounds/arch-rainbow-1920x1080.png --mode center --color=#302d41 @@ -42,6 +42,14 @@ input type:touchpad { middle_emulation enabled } +input type:touch { + map_to_output eDP-1 +} + +input type:tablet_tool { + map_to_output eDP-1 +} + ### Key bindings # # Basics: @@ -164,12 +172,13 @@ bindsym XF86AudioPlay exec playerctl play-pause bindsym XF86AudioNext exec playerctl next bindsym XF86AudioPrev exec playerctl previous -bindsym XF86MonBrightnessUp exec brightnessctl set +10% -bindsym XF86MonBrightnessDown exec brightnessctl set 10%- +bindsym XF86MonBrightnessUp exec brightnessctl set +5% +bindsym XF86MonBrightnessDown exec brightnessctl set 5%- bindsym $mod+b exec firefox bindsym $mod+x exec xournalpp -bindsym $mod+c exec "wezterm start --cwd ~/nextcloud/notebook/tex xch nvim" +# bindsym $mod+c exec "wezterm start --cwd ~/nextcloud/notebook/tex xch nvim" +bindsym $mod+c exec "lectern open" bindsym $mod+d exec "wezterm start --cwd ~/nextcloud/notebook/md xch nvim" bindsym $mod+Shift+c exec "wezterm start --class 'numbat' numbat" bindsym $mod+Shift+g exec "feh -Z -F -B black /home/josh/Pictures/game.png" @@ -189,6 +198,7 @@ title_align center default_border pixel for_window [app_id="numbat"] floating enable +for_window [app_id="xoppdoggin"] floating enable; resize set 1800 1000 for_window [class="Inkscape"] floating enable; resize set 1800 1000 for_window [class="vimscape"] floating enable; resize set 600 300; move down 300; move left 550 diff --git a/tofi/config b/tofi/config deleted file mode 100644 index 9c3770c..0000000 --- a/tofi/config +++ /dev/null @@ -1,19 +0,0 @@ -width = 35% -height = 35% -border-width = 0 -outline-width = 0 -padding-left = 2% -padding-top = 2% -result-spacing = 25 -num-results = 5 -font = /usr/share/fonts/TTF/FiraCodeNerdFont-Regular.ttf -font-size = 18 -background-color = #181926fa -text-color = #cad3f5 -selection-color = #ed8796 -prompt-color = #8aadf4 -input-background = #363a4f -input-background-padding = 7 -input-background-corner-radius = 3 -clip-to-padding = false -corner-radius = 8 -- cgit v1.3