diff options
| author | Mike Vink <mike@pionative.com> | 2025-01-20 10:59:33 +0100 |
|---|---|---|
| committer | Mike Vink <mike@pionative.com> | 2025-01-20 10:59:33 +0100 |
| commit | d659a2d6da6d8d9aa166a33a18025606434f136f (patch) | |
| tree | 61d0c914657319d2a30646fb3c8d11d0c27260d1 /mut | |
| parent | 883055eb4182cdb8ebf784a2171771de7334f95e (diff) | |
some surf related changes
Diffstat (limited to 'mut')
| -rwxr-xr-x | mut/bin/surf-open.sh | 32 | ||||
| -rw-r--r-- | mut/dwm/config.h | 2 | ||||
| -rw-r--r-- | mut/neovim/lua/my/packages/blink.lua | 1 | ||||
| -rw-r--r-- | mut/nushell/config.nu | 1 | ||||
| -rw-r--r-- | mut/nushell/env.nu | 6 | ||||
| -rw-r--r-- | mut/surf/config.def.h | 3 |
6 files changed, 39 insertions, 6 deletions
diff --git a/mut/bin/surf-open.sh b/mut/bin/surf-open.sh new file mode 100755 index 0000000..c22edc2 --- /dev/null +++ b/mut/bin/surf-open.sh @@ -0,0 +1,32 @@ +#!/bin/sh +# +# See the LICENSE file for copyright and license details. +# + +xidfile="$HOME/tmp/tabbed-surf.xid" +uri="" + +if [ "$#" -gt 0 ]; +then + uri="$1" +fi + +runtabbed() { + tabbed -dn tabbed-surf -r 2 surf -e '' "$uri" >"$xidfile" \ + 2>/dev/null & +} + +if [ ! -r "$xidfile" ]; +then + runtabbed +else + xid=$(cat "$xidfile") + xprop -id "$xid" >/dev/null 2>&1 + if [ $? -gt 0 ]; + then + runtabbed + else + surf -e "$xid" "$uri" >/dev/null 2>&1 & + fi +fi + diff --git a/mut/dwm/config.h b/mut/dwm/config.h index 5adcb46..4086f31 100644 --- a/mut/dwm/config.h +++ b/mut/dwm/config.h @@ -3,7 +3,7 @@ /* Constants */ #define TERMINAL "ghostty" #define TERMCLASS "Ghostty" -#define BROWSER "surf" +#define BROWSER "surf-open.sh" /* appearance */ static unsigned int borderpx = 3; /* border pixel of windows */ diff --git a/mut/neovim/lua/my/packages/blink.lua b/mut/neovim/lua/my/packages/blink.lua index fbbe87d..31726dc 100644 --- a/mut/neovim/lua/my/packages/blink.lua +++ b/mut/neovim/lua/my/packages/blink.lua @@ -1,5 +1,6 @@ local blink = require('blink.cmp') blink.setup { + fuzzy = { prebuilt_binaries = { force_version = "v0.10.0" } }, -- 'default' for mappings similar to built-in completion -- 'super-tab' for mappings similar to vscode (tab to accept, arrow keys to navigate) -- 'enter' for mappings similar to 'super-tab' but with 'enter' to accept diff --git a/mut/nushell/config.nu b/mut/nushell/config.nu index 69b48d7..3fb5613 100644 --- a/mut/nushell/config.nu +++ b/mut/nushell/config.nu @@ -1,4 +1,3 @@ -try {xset r rate 230 30} if ($env | default "" DOCKER_NAME | get DOCKER_NAME | is-empty) { try {pnsh-nvim} } diff --git a/mut/nushell/env.nu b/mut/nushell/env.nu index 35fb30f..01f1fb7 100644 --- a/mut/nushell/env.nu +++ b/mut/nushell/env.nu @@ -90,12 +90,12 @@ $env.NU_PLUGIN_DIRS = [ # $env.PATH = ($env.PATH | split row (char esep) | prepend '/some/path') # An alternate way to add entries to $env.PATH is to use the custom command `path add` # which is built into the nushell stdlib: -# use std "path add" +use std "path add" # $env.PATH = ($env.PATH | split row (char esep)) # path add /some/path # path add ($env.CARGO_HOME | path join "bin") -# path add ($env.HOME | path join ".local" "bin") -# $env.PATH = ($env.PATH | uniq) +path add ($env.HOME | path join ".local" "bin") +$env.PATH = ($env.PATH | uniq) # To load from a custom file you can use: # source ($nu.default-config-dir | path join 'custom.nu') diff --git a/mut/surf/config.def.h b/mut/surf/config.def.h index 1d27a0e..d1fca18 100644 --- a/mut/surf/config.def.h +++ b/mut/surf/config.def.h @@ -166,6 +166,7 @@ static Key keys[] = { { MODKEY|GDK_SHIFT_MASK, GDK_KEY_q, zoom, { .i = 0 } }, { MODKEY, GDK_KEY_minus, zoom, { .i = -1 } }, { MODKEY, GDK_KEY_plus, zoom, { .i = +1 } }, + { MODKEY|GDK_SHIFT_MASK, GDK_KEY_plus, zoom, { .i = +1 } }, { MODKEY, GDK_KEY_p, clipboard, { .i = 1 } }, { MODKEY, GDK_KEY_y, clipboard, { .i = 0 } }, @@ -174,7 +175,7 @@ static Key keys[] = { { MODKEY|GDK_SHIFT_MASK, GDK_KEY_n, find, { .i = -1 } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_p, print, { 0 } }, - { MODKEY, GDK_KEY_t, showcert, { 0 } }, + { MODKEY, GDK_KEY_o, showcert, { 0 } }, { MODKEY|GDK_SHIFT_MASK, GDK_KEY_a, togglecookiepolicy, { 0 } }, { 0, GDK_KEY_F11, togglefullscreen, { 0 } }, |
