Compare commits
3 Commits
wip
...
a6e37c95d7
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a6e37c95d7 | ||
|
|
b9ed91ed57 | ||
|
|
bc41c5ff77 |
@@ -1,34 +0,0 @@
|
||||
# gotmpl
|
||||
[grammar.gotmpl.source.git]
|
||||
url = "https://github.com/ngalaiko/tree-sitter-go-template"
|
||||
pin = "aa71f63de226c5592dfbfc1f29949522d7c95fac"
|
||||
|
||||
[language.gotmpl.queries.source.git]
|
||||
url = "https://github.com/helix-editor/helix"
|
||||
pin = "7275b7f85014aad7e15d4987ec4f2249572eecfb"
|
||||
|
||||
# odin
|
||||
[grammar.odin.source.git]
|
||||
url = "https://github.com/tree-sitter-grammars/tree-sitter-odin"
|
||||
pin = "d2ca8efb4487e156a60d5bd6db2598b872629403"
|
||||
|
||||
[grammar.odin]
|
||||
compile_args = ["-c", "-fpic", "../scanner.c", "../parser.c", "-I", ".."]
|
||||
link_args = ["-shared", "-fpic", "scanner.o", "parser.o", "-o", "odin.so"]
|
||||
|
||||
[language.odin.queries.source.git]
|
||||
url = "https://github.com/helix-editor/helix"
|
||||
pin = "7275b7f85014aad7e15d4987ec4f2249572eecfb"
|
||||
|
||||
# templ
|
||||
[grammar.templ.source.git]
|
||||
url = "https://github.com/vrischmann/tree-sitter-templ"
|
||||
pin = "04bae7c82de2fcfec94254fef50f5f1c5924f5f5"
|
||||
|
||||
[grammar.templ]
|
||||
compile_args = ["-c", "-fpic", "../scanner.c", "../parser.c", "-I", ".."]
|
||||
link_args = ["-shared", "-fpic", "scanner.o", "parser.o", "-o", "templ.so"]
|
||||
|
||||
[language.templ.queries.source.git]
|
||||
url = "https://github.com/helix-editor/helix"
|
||||
pin = "7275b7f85014aad7e15d4987ec4f2249572eecfb"
|
||||
@@ -121,55 +121,5 @@ evaluate-commands %sh{
|
||||
|
||||
set-face global SnippetsNextPlaceholders $bg,$green2
|
||||
set-face global SnippetsOtherPlaceholders $bg,$yellow2
|
||||
|
||||
# kak-tree-sitter
|
||||
|
||||
set-face global ts_attribute $green3
|
||||
set-face global ts_comment $gray
|
||||
set-face global ts_constant $violet2
|
||||
set-face global ts_conceal $red1
|
||||
set-face global ts_constructor $red1
|
||||
set-face global ts_diff_plus $green2
|
||||
set-face global ts_diff_minus $red2
|
||||
set-face global ts_diff_delta $blue2
|
||||
set-face global ts_error $red2
|
||||
set-face global ts_function $blue2
|
||||
set-face global ts_hint $green2
|
||||
set-face global ts_info $blue2
|
||||
set-face global ts_keyword $violet3
|
||||
set-face global ts_label $red1
|
||||
set-face global ts_bold $green2+b
|
||||
set-face global ts_markup_heading $red3
|
||||
set-face global ts_markup_italic $green2+i
|
||||
set-face global ts_markup_list_checked $red2
|
||||
set-face global ts_markup_list_numbered $red2
|
||||
set-face global ts_markup_list_unchecked $red2
|
||||
set-face global ts_markup_list_unnumbered $red2
|
||||
set-face global ts_markup_link_label $green2
|
||||
set-face global ts_markup_link_url $blue2
|
||||
set-face global ts_markup_link_uri $blue2
|
||||
set-face global ts_markup_link_text $red1
|
||||
set-face global ts_markup_quote $blue3
|
||||
set-face global ts_markup_raw $yellow2
|
||||
set-face global ts_markup_strikethrough $red2+s
|
||||
set-face global ts_namespace $green3
|
||||
set-face global ts_operator $red2
|
||||
set-face global ts_property $green3
|
||||
set-face global ts_punctuation $red3
|
||||
set-face global ts_special $red3
|
||||
set-face global ts_spell $red1+c
|
||||
set-face global ts_string $yellow2
|
||||
set-face global ts_string_regex $yellow1+b
|
||||
set-face global ts_string_regexp $yellow1+b
|
||||
set-face global ts_string_escape $yellow1+b
|
||||
set-face global ts_string_special $yellow1+b
|
||||
set-face global ts_string_symbol $yellow1+b
|
||||
set-face global ts_tag $green2
|
||||
set-face global ts_tag_error $red2+c
|
||||
set-face global ts_text $red1
|
||||
set-face global ts_text_title $red3
|
||||
set-face global ts_type $green2
|
||||
set-face global ts_variable $blue3
|
||||
set-face global ts_warning $yellow2+c
|
||||
"
|
||||
}
|
||||
|
||||
@@ -121,55 +121,5 @@ evaluate-commands %sh{
|
||||
|
||||
set-face global SnippetsNextPlaceholders $bg,$green2
|
||||
set-face global SnippetsOtherPlaceholders $bg,$yellow2
|
||||
|
||||
# kak-tree-sitter
|
||||
|
||||
set-face global ts_attribute $green3
|
||||
set-face global ts_comment $gray
|
||||
set-face global ts_constant $violet2
|
||||
set-face global ts_conceal $red1
|
||||
set-face global ts_constructor $red1
|
||||
set-face global ts_diff_plus $green2
|
||||
set-face global ts_diff_minus $red2
|
||||
set-face global ts_diff_delta $blue2
|
||||
set-face global ts_error $red2
|
||||
set-face global ts_function $blue2
|
||||
set-face global ts_hint $green2
|
||||
set-face global ts_info $blue2
|
||||
set-face global ts_keyword $violet3
|
||||
set-face global ts_label $red1
|
||||
set-face global ts_bold $green2+b
|
||||
set-face global ts_markup_heading $red3
|
||||
set-face global ts_markup_italic $green2+i
|
||||
set-face global ts_markup_list_checked $red2
|
||||
set-face global ts_markup_list_numbered $red2
|
||||
set-face global ts_markup_list_unchecked $red2
|
||||
set-face global ts_markup_list_unnumbered $red2
|
||||
set-face global ts_markup_link_label $green2
|
||||
set-face global ts_markup_link_url $blue2
|
||||
set-face global ts_markup_link_uri $blue2
|
||||
set-face global ts_markup_link_text $red1
|
||||
set-face global ts_markup_quote $blue3
|
||||
set-face global ts_markup_raw $yellow2
|
||||
set-face global ts_markup_strikethrough $red2+s
|
||||
set-face global ts_namespace $green3
|
||||
set-face global ts_operator $red2
|
||||
set-face global ts_property $green3
|
||||
set-face global ts_punctuation $red3
|
||||
set-face global ts_special $red3
|
||||
set-face global ts_spell $red1+c
|
||||
set-face global ts_string $yellow2
|
||||
set-face global ts_string_regex $yellow1+b
|
||||
set-face global ts_string_regexp $yellow1+b
|
||||
set-face global ts_string_escape $yellow1+b
|
||||
set-face global ts_string_special $yellow1+b
|
||||
set-face global ts_string_symbol $yellow1+b
|
||||
set-face global ts_tag $green2
|
||||
set-face global ts_tag_error $red2+c
|
||||
set-face global ts_text $red1
|
||||
set-face global ts_text_title $red3
|
||||
set-face global ts_type $green2
|
||||
set-face global ts_variable $blue3
|
||||
set-face global ts_warning $yellow2+c
|
||||
"
|
||||
}
|
||||
|
||||
@@ -6,11 +6,7 @@ set-option global ui_options terminal_assistant=none
|
||||
hook global WinCreate .* %{
|
||||
add-highlighter window/number-lines number-lines -relative -hlcursor
|
||||
}
|
||||
|
||||
hook global BufCreate .*\.templ %{ set buffer filetype templ }
|
||||
hook global BufCreate .*\.html.tmpl %{ set buffer filetype gotmpl }
|
||||
|
||||
hook global WinCreate ^[^*]+$ %{editorconfig-load}
|
||||
add-highlighter global/ show-matching
|
||||
|
||||
# LOCAL
|
||||
|
||||
@@ -38,8 +34,6 @@ map global -docstring 'Grep previous match' file-mode 'p' ': grep-prev-match<ret
|
||||
map global -docstring 'Grep current file' file-mode 'l' ':grep-file '
|
||||
map global -docstring 'Grep current file' file-mode 'L' ': grep-file %val{selection}<ret>'
|
||||
map global -docstring 'Delete buffer' file-mode 'x' ': delete-buffer '
|
||||
map global -docstring 'REPL send selection' file-mode 'u' ': repl-send-text<ret>'
|
||||
map global -docstring 'REPL send paragraph' file-mode 'U' ': repl-send-paragraph<ret>'
|
||||
|
||||
declare-user-mode git-mode
|
||||
map global -docstring 'Git' user 'g' ': enter-user-mode git-mode<ret>'
|
||||
@@ -129,10 +123,6 @@ define-command -override open-create-in-dir %{
|
||||
execute-keys ': edit ' %sh{dirname "$kak_buffile"}/
|
||||
}
|
||||
|
||||
define-command -override repl-send-paragraph %{
|
||||
execute-keys -draft '<a-i>p: repl-send-text<ret>'
|
||||
}
|
||||
|
||||
define-command git-log-show-current-commit %{
|
||||
execute-keys ';<a-/>^commit\s[0-9a-f]+<ret>b'
|
||||
git show %val{selection}
|
||||
@@ -250,14 +240,6 @@ bundle kak-harpoon 'https://codeberg.org/raiguard/kak-harpoon' %{
|
||||
harpoon-add-bindings
|
||||
}
|
||||
|
||||
# TREE SITTER
|
||||
|
||||
eval %sh{ kak-tree-sitter -dks --init $kak_session }
|
||||
|
||||
define-command -override tree-sitter-user-after-highlighter %{
|
||||
add-highlighter -override buffer/show-matching show-matching
|
||||
}
|
||||
|
||||
# LOCAL
|
||||
|
||||
define-command set-dark-or-light-colorscheme %{
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
for (i = 3; i < NF; ++i) {
|
||||
if ($i ~ /^[0-9]+$/) {
|
||||
j = match($0, "[ ]+" $(i-1) "[ ]+" $i " ")
|
||||
print substr($0, 0, j - 1) "·" $(i-1) "·" $i
|
||||
print substr($0, 0, j - 1) "\u00a0" $(i-1) "\u00a0" $i
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
BEGIN {
|
||||
n = split(ENVIRON["kak_text"], a, "·")
|
||||
n = split(ENVIRON["kak_text"], a, "\u00a0")
|
||||
line = a[3]
|
||||
if (n == 3 && line ~ /^[0-9]+/) {
|
||||
pat = a[1]
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
for (i = 3; i < NF; ++i) {
|
||||
if ($i ~ /^[0-9]+$/) {
|
||||
j = match($0, "[ ]+" $(i-1) "[ ]+" $i " ")
|
||||
print substr($0, 0, j - 1) "·" $(i-1) "·" $i "·" $(i+1)
|
||||
print substr($0, 0, j - 1) "\u00a0" $(i-1) "\u00a0" $i "\u00a0" $(i+1)
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
BEGIN {
|
||||
n = split(ENVIRON["kak_text"], a, "·")
|
||||
n = split(ENVIRON["kak_text"], a, "\u00a0")
|
||||
line = a[3]
|
||||
if (n == 4 && line ~ /^[0-9]+/) {
|
||||
pat = a[1]
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
/bin/zsh
|
||||
@@ -1,2 +0,0 @@
|
||||
#!/bin/sh
|
||||
PATH="$PATH:$HOME/.config/lazygit/bin" exec /usr/bin/lazygit "$@"
|
||||
@@ -11,6 +11,3 @@ gui:
|
||||
theme:
|
||||
selectedLineBgColor:
|
||||
- reverse
|
||||
|
||||
git:
|
||||
autoFetch: false
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
alias k=kak
|
||||
alias kc='kak -c "$(kak -l | fzf)"'
|
||||
alias kd='kak -s "$(printf %s $PWD | xargs basename)"'
|
||||
alias lg=lazygit
|
||||
alias z='cd $(fzf --walker dir --walker-root ~)'
|
||||
@@ -38,14 +38,12 @@ fi
|
||||
export GOPATH=~/.cache/go
|
||||
export GOBIN=~/.local/bin
|
||||
|
||||
export ENV=~/.ashrc
|
||||
|
||||
# start X or Hyprland at login
|
||||
if [ -z "$DISPLAY" -a -z "$WAYLAND_DISPLAY" -a "$(tty)" = /dev/tty1 ]; then
|
||||
if which /usr/bin/sx > /dev/null; then
|
||||
exec /usr/bin/sx ~/.xinitrc
|
||||
exec /usr/bin/sx ~/.xsession
|
||||
elif which /usr/bin/startx > /dev/null; then
|
||||
exec /usr/bin/startx
|
||||
exec /usr/bin/startx ~/.xsession
|
||||
elif which niri > /dev/null; then
|
||||
exec niri
|
||||
elif which river argen > /dev/null; then
|
||||
|
||||
@@ -23,8 +23,8 @@ fi
|
||||
|
||||
pkill -USR1 '^dwm$'
|
||||
|
||||
XRES=$(readlink -f ~/.Xresources)
|
||||
if [ -f "$XRES" ]; then
|
||||
XRES=$(readlink -e ~/.Xresources)
|
||||
if [ -n "$XRES" ]; then
|
||||
if [ "$THEME" = dark ]; then
|
||||
sed -i 's/^#undef THEME_DARK/#define THEME_DARK/' "$XRES"
|
||||
elif [ "$THEME" = light ]; then
|
||||
@@ -35,11 +35,11 @@ if [ -f "$XRES" ]; then
|
||||
fi
|
||||
|
||||
# Alacritty
|
||||
AYML=$(readlink -f ~/.config/alacritty/alacritty.yml)
|
||||
if [ -f "$AYML" ]; then
|
||||
AYML=$(readlink -e ~/.config/alacritty/alacritty.yml)
|
||||
if [ -n "$AYML" ]; then
|
||||
sed -i "s/^colors: [*].*/colors: *$THEME/" "$AYML"
|
||||
fi
|
||||
ATOML=$(readlink -f ~/.config/alacritty/alacritty.toml)
|
||||
ATOML=$(readlink -e ~/.config/alacritty/alacritty.toml)
|
||||
if [ -f "$ATOML" ]; then
|
||||
sed -i "s#^import =.*#import = [\"~/.config/alacritty/$THEME.toml\"]#" "$ATOML"
|
||||
fi
|
||||
@@ -52,27 +52,27 @@ elif [ "$THEME" = light ]; then
|
||||
fi
|
||||
|
||||
# Foot
|
||||
FOOT=$(readlink -f ~/.config/foot/foot.ini)
|
||||
if [ -f "$FOOT" ]; then
|
||||
FOOT=$(readlink -e ~/.config/foot/foot.ini)
|
||||
if [ -n "$FOOT" ]; then
|
||||
sed -i "s/^initial-color-theme .*/initial-color-theme = $THEME/" "$FOOT"
|
||||
fi
|
||||
|
||||
# GTK
|
||||
XSET=$(readlink -f ~/.config/xsettingsd/xsettingsd.conf)
|
||||
if [ -f "$XSET" ]; then
|
||||
XSET=$(readlink -e ~/.config/xsettingsd/xsettingsd.conf)
|
||||
if [ -n "$XSET" ]; then
|
||||
sed -i -E "s#(Net/ThemeName) .*#\\1 \"${GTK_THEME}\"#" "$XSET"
|
||||
pkill -HUP -x xsettingsd
|
||||
gsettings set org.gnome.desktop.interface gtk-theme "${GTK_THEME}"
|
||||
fi
|
||||
|
||||
# niri
|
||||
NIRI=$(readlink -f ~/.config/niri/config.kdl)
|
||||
if [ -f "$NIRI" ]; then
|
||||
NIRI=$(readlink -e ~/.config/niri/config.kdl)
|
||||
if [ -n "$NIRI" ]; then
|
||||
sed -i -E "s%^(include) \"(dark|light).kdl\".*%\\1 \"${THEME}.kdl\"%" "$NIRI"
|
||||
fi
|
||||
|
||||
# waybar
|
||||
WCSS=$(readlink -f ~/.config/waybar/style.css)
|
||||
WCSS=$(readlink -e ~/.config/waybar/style.css)
|
||||
if [ -f "$WCSS" ]; then
|
||||
sed -i -E "s#file:///.*/(light|dark)[.]css#file://$HOME/.config/waybar/$THEME.css#" "$WCSS"
|
||||
killall -SIGUSR2 waybar
|
||||
|
||||
Reference in New Issue
Block a user