diff options
-rw-r--r-- | .config/BetterDiscord/data/stable/settings.json | 18 | ||||
-rw-r--r-- | .config/X11/base | 2 | ||||
-rw-r--r-- | .config/clangd/config.yaml | 5 | ||||
-rw-r--r-- | .config/coc/extensions/package.json | 12 | ||||
-rw-r--r-- | .config/fcitx5/conf/imselector.conf | 11 | ||||
l---------[-rw-r--r--] | .config/fzmp/conf | 4 | ||||
-rw-r--r-- | .config/kitty/kitty.conf | 14 | ||||
-rw-r--r-- | .config/mpcplus/fzmp.conf | 3 | ||||
-rw-r--r-- | .config/nvim/init.vim | 14 | ||||
-rw-r--r-- | .config/picom.conf | 2 | ||||
-rw-r--r-- | .local/share/applications/discord.desktop | 1 | ||||
-rwxr-xr-x | .local/share/bin/ccpreview | 2 | ||||
-rwxr-xr-x | .local/share/bin/mk | 7 | ||||
-rwxr-xr-x | .local/share/bin/nginx-dev | 5 | ||||
-rwxr-xr-x | .local/share/bin/set-default | 32 | ||||
-rwxr-xr-x | .local/share/mode/switch.d/kitty | 25 | ||||
-rwxr-xr-x | .local/share/pass-extensions/duplicates.bash | 13 | ||||
-rwxr-xr-x | .local/share/pass-extensions/g.bash | 2 |
18 files changed, 144 insertions, 28 deletions
diff --git a/.config/BetterDiscord/data/stable/settings.json b/.config/BetterDiscord/data/stable/settings.json index 42a2be1..eb9ab27 100644 --- a/.config/BetterDiscord/data/stable/settings.json +++ b/.config/BetterDiscord/data/stable/settings.json @@ -3,11 +3,19 @@ "voiceDisconnect": false, "showToasts": true, "mediaKeys": false, - "bdContextMenu": true + "bdContextMenu": true, + "themeAttributes": true }, "addons": { "addonErrors": true, - "editAction": "detached" + "editAction": "detached", + "checkForUpdates": true, + "updateInterval": 4 + }, + "store": { + "bdAddonStore": true, + "alwaysEnable": false, + "addonEmbeds": true }, "customcss": { "customcss": true, @@ -25,7 +33,8 @@ "window": { "transparency": false, "removeMinimumSize": true, - "frame": false + "frame": false, + "inAppTrafficLights": false }, "developer": { "debugLogs": false, @@ -33,6 +42,7 @@ "debuggerHotkey": false, "reactDevTools": false, "inspectElement": false, - "devToolsWarning": false + "devToolsWarning": false, + "recovery": true } }
\ No newline at end of file diff --git a/.config/X11/base b/.config/X11/base index a556ed2..a538320 100644 --- a/.config/X11/base +++ b/.config/X11/base @@ -1,4 +1,4 @@ -*.font: JetBrainsMono Nerd Font:size=7.5:antialias=true:autohint=true +*.font: monospace:size=7.5:antialias=true:autohint=true *.borderpx: 10 *.termname: st-256color *.tabspaces: 2 diff --git a/.config/clangd/config.yaml b/.config/clangd/config.yaml new file mode 100644 index 0000000..ef8aca7 --- /dev/null +++ b/.config/clangd/config.yaml @@ -0,0 +1,5 @@ +CompileFlags: + # ignore unknown (gcc) compiler flags + Add: -Wno-unknown-warning-option + Remove: [-m*, -f*] + diff --git a/.config/coc/extensions/package.json b/.config/coc/extensions/package.json index b055105..1a8c2f8 100644 --- a/.config/coc/extensions/package.json +++ b/.config/coc/extensions/package.json @@ -2,20 +2,20 @@ "dependencies": { "coc-css": ">=2.1.0", "coc-emmet": ">=1.1.6", - "coc-go": ">=1.3.33", + "coc-go": ">=1.3.35", "coc-html": ">=1.8.0", "coc-java": ">=1.15.2", "coc-json": ">=1.9.2", "coc-python": ">=1.2.13", - "coc-rust-analyzer": ">=0.75.2", - "coc-tsserver": ">=2.1.4", + "coc-rust-analyzer": ">=0.80.2", + "coc-tsserver": ">=2.2.0", "coc-vimtex": ">=1.1.5", "coc-lua": ">=2.0.6", - "coc-deno": ">=3.13.0", - "coc-sh": ">=1.2.2", + "coc-deno": ">=3.15.0", + "coc-sh": ">=1.2.4", "coc-solargraph": ">=1.2.4" }, "disabled": [], "locked": [], - "lastUpdate": 1737632010099 + "lastUpdate": 1738787321876 }
\ No newline at end of file diff --git a/.config/fcitx5/conf/imselector.conf b/.config/fcitx5/conf/imselector.conf index 87428a1..de02872 100644 --- a/.config/fcitx5/conf/imselector.conf +++ b/.config/fcitx5/conf/imselector.conf @@ -1,10 +1,13 @@ -# Trigger Key for only current input context +# 現在の入力コンテキストのみのトリガーキー TriggerKeyLocal= -# Hotkey for switching to the N-th input method -SwitchKey= -# Hotkey for switching to the N-th input method for only current input context +# 現在の入力コンテキストのみをN番目の入力メソッドに切り替えるホットキー SwitchKeyLocal= [TriggerKey] 0=Super+Z +[SwitchKey] +0=Launch5 +1=Launch6 +2=Launch7 + diff --git a/.config/fzmp/conf b/.config/fzmp/conf index 22439c3..a51f36d 100644..120000 --- a/.config/fzmp/conf +++ b/.config/fzmp/conf @@ -1,3 +1 @@ -default_view songs -full_song_format [[[%artist% - %album% / ][%title%]]|%file%] -fzf_options --ignore-case +../mpcplus/fzmp.conf
\ No newline at end of file diff --git a/.config/kitty/kitty.conf b/.config/kitty/kitty.conf new file mode 100644 index 0000000..b3af114 --- /dev/null +++ b/.config/kitty/kitty.conf @@ -0,0 +1,14 @@ +font_size 7.5 +disable_ligatures never +window_padding_width 10 +placement_strategy top-left +cursor_shape block + +modify_font cell_width 95% +modify_font cell_height 120% +modify_font baseline -1 + +copy_on_select yes + +include color.conf + diff --git a/.config/mpcplus/fzmp.conf b/.config/mpcplus/fzmp.conf new file mode 100644 index 0000000..22439c3 --- /dev/null +++ b/.config/mpcplus/fzmp.conf @@ -0,0 +1,3 @@ +default_view songs +full_song_format [[[%artist% - %album% / ][%title%]]|%file%] +fzf_options --ignore-case diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim index dac1f01..9278804 100644 --- a/.config/nvim/init.vim +++ b/.config/nvim/init.vim @@ -19,6 +19,7 @@ set linebreak " set wrap but don't wrap inside words set viminfo+='1000,n~/.local/nvim/viminfo set guifont=JetBrainsMono\ Nerd\ Font:h9:#e-subpixelantialias:#h-slight set linespace=5 +set tabpagemax=999 let g:sneak#label = 1 let g:which_key_map = {} let g:airline_powerline_fonts = 1 @@ -191,6 +192,13 @@ let g:which_key_map.u = 'toggle undo tree' cnoreabbrev W w cnoreabbrev sudow w !sudo tee % +" emacs bindings in vim command-line +cnoremap <A-b> <S-Left> +cnoremap <A-f> <S-Right> +cnoremap <C-a> <Home> +cnoremap <C-e> <End> +cnoremap <A-backspace> <C-w> + " hexokinase let g:Hexokinase_termDisabled = 1 let g:Hexokinase_optOutPatterns = [ 'colour_names' ] @@ -348,6 +356,12 @@ augroup Binary au BufWritePost *.bin set noeol augroup END +" highlight Zephyr .overlay files as devicetree source (dts) +augroup devicetree_ft + au! + au BufRead,BufNewFile *.overlay set syntax=dts +augroup END + " sneak let g:sneak#use_ic_scs = 0 diff --git a/.config/picom.conf b/.config/picom.conf index f88a591..111ad71 100644 --- a/.config/picom.conf +++ b/.config/picom.conf @@ -55,7 +55,7 @@ rules = ( corner-radius = 0; }, { - match = "window_type *= 'popup_menu'"; + match = "window_type *= 'combo'"; shadow = true; corner-radius = 10; }, diff --git a/.local/share/applications/discord.desktop b/.local/share/applications/discord.desktop index 676b330..403a457 100644 --- a/.local/share/applications/discord.desktop +++ b/.local/share/applications/discord.desktop @@ -7,3 +7,4 @@ Exec=discord Icon=discord Type=Application Categories=Network;InstantMessaging; +MimeType=x-scheme-handler/betterdiscord; diff --git a/.local/share/bin/ccpreview b/.local/share/bin/ccpreview index 914a6ad..9f13acc 100755 --- a/.local/share/bin/ccpreview +++ b/.local/share/bin/ccpreview @@ -55,6 +55,7 @@ _mpv \ --interpolation=no \ --stream-buffer-size=4k \ --profile=low-latency \ + --speed=1.001 \ "$AUDIO_URL" # video preview @@ -65,6 +66,7 @@ _mpv \ --demuxer-lavf-o-add=framerate="$FRAMERATE" \ --demuxer-lavf-o-add=resolution="$RESOLUTION" \ --demuxer-lavf-o-add=rw_timeout=30000000 \ + --speed=1.05 \ "$VIDEO_URL" sleep infinity diff --git a/.local/share/bin/mk b/.local/share/bin/mk index ab0f586..b7e2b41 100755 --- a/.local/share/bin/mk +++ b/.local/share/bin/mk @@ -6,6 +6,13 @@ showmode() { printf '\e[1A\e['$col'G\e[1;30m%s\e[0m\n' "$mode" } +mode_west() { + showmode 'west' + [ -z "$*" ] && set -- build + exec west "$@" +} +[ -e "west.yml" ] && mode_west "$@" + mode_cmake() { showmode 'cmake' builddir="build" diff --git a/.local/share/bin/nginx-dev b/.local/share/bin/nginx-dev index 4e9825d..10987fd 100755 --- a/.local/share/bin/nginx-dev +++ b/.local/share/bin/nginx-dev @@ -21,13 +21,14 @@ options: -C enable server cache (disabled by default) -v verbose mode (prints config before starting server) -q quiet mode (disable access_log) + -x automatically open a browser -h show this help EOF exit $1 } ARGC=0 -while getopts hvp:Ct:q OPT; do +while getopts hvp:Ct:qx OPT; do [ $OPTIND -gt $ARGC ] && ARGC=$OPTIND case $OPT in h) usage 0 ;; @@ -36,6 +37,7 @@ while getopts hvp:Ct:q OPT; do v) print_config=1 ;; C) cache_control="" ;; q) access_log="/dev/null" ;; + x) open_browser=1 ;; \?|*) usage 1 ;; esac done @@ -76,6 +78,7 @@ http { } EOF [ $print_config ] && cat "$config" +[ $open_browser ] && (xdg-open "http://localhost:$port" 1> /dev/null 2> /dev/null &) nginx -c "$config" rm -f "$config" "$pidfile" diff --git a/.local/share/bin/set-default b/.local/share/bin/set-default new file mode 100755 index 0000000..d93f65c --- /dev/null +++ b/.local/share/bin/set-default @@ -0,0 +1,32 @@ +#!/bin/sh +SCRIPT_NAME="$(basename "$0")" + +usage() { + code=0 + if [ -z "$1" ] ; then + cat << EOF +Set desktop entry ENTRY as default application for opening files with the same +type as FILE + +EOF + else + echo "error: $1" >&2 + code=1 + fi + cat << EOF +usage: + $SCRIPT_NAME ENTRY FILE [FILE] +EOF + exit $code +} + +[ $# -eq 0 ] && usage +DESKTOP_ENTRY="$1"; shift +[ -z "$DESKTOP_ENTRY" ] && usage "no desktop entry" +[ $# -lt 1 ] && usage "no reference file(s)" + +for file in "$@" ; do + mimetype="$(xdg-mime query filetype "$file")" + xdg-mime default "$DESKTOP_ENTRY" "$mimetype" +done + diff --git a/.local/share/mode/switch.d/kitty b/.local/share/mode/switch.d/kitty new file mode 100755 index 0000000..dddc41b --- /dev/null +++ b/.local/share/mode/switch.d/kitty @@ -0,0 +1,25 @@ +#!/bin/sh +mkcd "$XDG_CONFIG_HOME/kitty" + +cat << EOF > 'color.conf' +background $bg +foreground $fg + +color0 $color0 +color1 $color1 +color2 $color2 +color3 $color3 +color4 $color4 +color5 $color5 +color6 $color6 +color7 $color7 +color8 $color8 +color9 $color9 +color10 $color10 +color11 $color11 +color12 $color12 +color13 $color13 +color14 $color14 +color15 $color15 +EOF + diff --git a/.local/share/pass-extensions/duplicates.bash b/.local/share/pass-extensions/duplicates.bash index cb1cbbc..3ba47aa 100755 --- a/.local/share/pass-extensions/duplicates.bash +++ b/.local/share/pass-extensions/duplicates.bash @@ -5,21 +5,18 @@ pass_names="$(pass names -l)" [ $? -ne 0 ] && exit 1 pass_count="$(echo "$pass_names" | wc -l)" -if [ "$pass_count" -gt 10 ] ; then - cat << EOF >&2 -pass-duplicates needs to decrypt all your passwords one-by-one to cross-match -them. This is all done in-memory, and nothing is saved to disk. You appear to -have $pass_count passwords, so this may take some time... - -EOF -fi +pass_index=1 while read pass_name ; do hash="$(pass show "$pass_name" | head -n1 | sha1sum | cut -c1-40)" dupe_map["$pass_name"]="$hash" dupe_tally["$hash"]=$(( ${dupe_tally["$hash"]} + 1 )) + + printf '\rhashing... (%d/%d)' "$pass_index" "$pass_count" >&2 + pass_index=$(( $pass_index + 1 )) done < <(echo "$pass_names") +printf '\r\e[2K' >&2 unique_duplicates=0 total_shared=0 diff --git a/.local/share/pass-extensions/g.bash b/.local/share/pass-extensions/g.bash new file mode 100755 index 0000000..4ab3ace --- /dev/null +++ b/.local/share/pass-extensions/g.bash @@ -0,0 +1,2 @@ +#!/bin/bash +exec pass git "$@" |