Add jj/kitty/nvim/opencode/paru/fish/yazi/jjui

This commit is contained in:
2026-02-19 22:27:46 +00:00
parent 774492f279
commit e55197517c
95 changed files with 10407 additions and 0 deletions

6
fish/config.lua Normal file
View File

@@ -0,0 +1,6 @@
return {
target = {
linux = "~/.config/fish",
default = "~/.config/fish",
},
}

View File

@@ -0,0 +1,186 @@
# This is terribly complicated
# It's because:
# 1. bun run has to have dynamic completions
# 2. there are global options
# 3. bun {install add remove} gets special options
# 4. I don't know how to write fish completions well
# Contributions very welcome!!
function __fish__get_bun_bins
string split ' ' (bun getcompletes b)
end
function __fish__get_bun_scripts
set -lx SHELL bash
set -lx MAX_DESCRIPTION_LEN 40
string trim (string split '\n' (string split '\t' (bun getcompletes z)))
end
function __fish__get_bun_packages
if test (commandline -ct) != ""
set -lx SHELL fish
string split ' ' (bun getcompletes a (commandline -ct))
end
end
function __history_completions
set -l tokens (commandline --current-process --tokenize)
history --prefix (commandline) | string replace -r \^$tokens[1]\\s\* "" | string replace -r \^$tokens[2]\\s\* "" | string split ' '
end
function __fish__get_bun_bun_js_files
string split ' ' (bun getcompletes j)
end
set -l bun_install_boolean_flags yarn production optional development no-save dry-run force no-cache silent verbose global
set -l bun_install_boolean_flags_descriptions "Write a yarn.lock file (yarn v1)" "Don't install devDependencies" "Add dependency to optionalDependencies" "Add dependency to devDependencies" "Don't update package.json or save a lockfile" "Don't install anything" "Always request the latest versions from the registry & reinstall all dependencies" "Ignore manifest cache entirely" "Don't output anything" "Excessively verbose logging" "Use global folder"
set -l bun_builtin_cmds_without_run dev create help bun upgrade discord install remove add init pm x
set -l bun_builtin_cmds_accepting_flags create help bun upgrade discord run init link unlink pm x
function __bun_complete_bins_scripts --inherit-variable bun_builtin_cmds_without_run -d "Emit bun completions for bins and scripts"
# Do nothing if we already have a builtin subcommand,
# or any subcommand other than "run".
if __fish_seen_subcommand_from $bun_builtin_cmds_without_run
or not __fish_use_subcommand && not __fish_seen_subcommand_from run
return
end
# Do we already have a bin or script subcommand?
set -l bins (__fish__get_bun_bins)
if __fish_seen_subcommand_from $bins
return
end
# Scripts have descriptions appended with a tab separator.
# Strip off descriptions for the purposes of subcommand testing.
set -l scripts (__fish__get_bun_scripts)
if __fish_seen_subcommand_from (string split \t -f 1 -- $scripts)
return
end
# Emit scripts.
for script in $scripts
echo $script
end
# Emit binaries and JS files (but only if we're doing `bun run`).
if __fish_seen_subcommand_from run
for bin in $bins
echo "$bin"\t"package bin"
end
for file in (__fish__get_bun_bun_js_files)
echo "$file"\t"Bun.js"
end
end
end
# Clear existing completions
complete -e -c bun
# Dynamically emit scripts and binaries
complete -c bun -f -a "(__bun_complete_bins_scripts)"
# Complete flags if we have no subcommand or a flag-friendly one.
set -l flag_applies "__fish_use_subcommand; or __fish_seen_subcommand_from $bun_builtin_cmds_accepting_flags"
complete -c bun \
-n $flag_applies --no-files -s 'u' -l 'origin' -r -d 'Server URL. Rewrites import paths'
complete -c bun \
-n $flag_applies --no-files -s 'p' -l 'port' -r -d 'Port number to start server from'
complete -c bun \
-n $flag_applies --no-files -s 'd' -l 'define' -r -d 'Substitute K:V while parsing, e.g. --define process.env.NODE_ENV:\"development\"'
complete -c bun \
-n $flag_applies --no-files -s 'e' -l 'external' -r -d 'Exclude module from transpilation (can use * wildcards). ex: -e react'
complete -c bun \
-n $flag_applies --no-files -l 'use' -r -d 'Use a framework (ex: next)'
complete -c bun \
-n $flag_applies --no-files -l 'hot' -r -d 'Enable hot reloading in Bun\'s JavaScript runtime'
# Complete dev and create as first subcommand.
complete -c bun \
-n "__fish_use_subcommand" -a 'dev' -d 'Start dev server'
complete -c bun \
-n "__fish_use_subcommand" -a 'create' -f -d 'Create a new project from a template'
# Complete "next" and "react" if we've seen "create".
complete -c bun \
-n "__fish_seen_subcommand_from create" -a 'next' -d 'new Next.js project'
complete -c bun \
-n "__fish_seen_subcommand_from create" -a 'react' -d 'new React project'
# Complete "upgrade" as first subcommand.
complete -c bun \
-n "__fish_use_subcommand" -a 'upgrade' -d 'Upgrade bun to the latest version' -x
# Complete "-h/--help" unconditionally.
complete -c bun \
-s "h" -l "help" -d 'See all commands and flags' -x
# Complete "-v/--version" if we have no subcommand.
complete -c bun \
-n "not __fish_use_subcommand" -l "version" -s "v" -d 'Bun\'s version' -x
# Complete additional subcommands.
complete -c bun \
-n "__fish_use_subcommand" -a 'discord' -d 'Open bun\'s Discord server' -x
complete -c bun \
-n "__fish_use_subcommand" -a 'bun' -d 'Generate a new bundle'
complete -c bun \
-n "__fish_seen_subcommand_from bun" -F -d 'Bundle this'
complete -c bun \
-n "__fish_seen_subcommand_from create; and __fish_seen_subcommand_from react next" -F -d "Create in directory"
complete -c bun \
-n "__fish_use_subcommand" -a 'init' -F -d 'Start an empty Bun project'
complete -c bun \
-n "__fish_use_subcommand" -a 'install' -f -d 'Install packages from package.json'
complete -c bun \
-n "__fish_use_subcommand" -a 'add' -F -d 'Add a package to package.json'
complete -c bun \
-n "__fish_use_subcommand" -a 'remove' -F -d 'Remove a package from package.json'
for i in (seq (count $bun_install_boolean_flags))
complete -c bun \
-n "__fish_seen_subcommand_from install add remove" -l "$bun_install_boolean_flags[$i]" -d "$bun_install_boolean_flags_descriptions[$i]"
end
complete -c bun \
-n "__fish_seen_subcommand_from install add remove" -l 'cwd' -d 'Change working directory'
complete -c bun \
-n "__fish_seen_subcommand_from install add remove" -l 'cache-dir' -d 'Choose a cache directory (default: $HOME/.bun/install/cache)'
complete -c bun \
-n "__fish_seen_subcommand_from add" -d 'Popular' -a '(__fish__get_bun_packages)'
complete -c bun \
-n "__fish_seen_subcommand_from add" -d 'History' -a '(__history_completions)'
complete -c bun \
-n "__fish_seen_subcommand_from pm; and not __fish_seen_subcommand_from (__fish__get_bun_bins) (__fish__get_bun_scripts) cache;" -a 'bin ls cache hash hash-print hash-string' -f
complete -c bun \
-n "__fish_seen_subcommand_from pm; and __fish_seen_subcommand_from cache; and not __fish_seen_subcommand_from (__fish__get_bun_bins) (__fish__get_bun_scripts);" -a 'rm' -f
# Add built-in subcommands with descriptions.
complete -c bun -n "__fish_use_subcommand" -a "create" -f -d "Create a new project from a template"
complete -c bun -n "__fish_use_subcommand" -a "build bun" --require-parameter -F -d "Transpile and bundle one or more files"
complete -c bun -n "__fish_use_subcommand" -a "upgrade" -d "Upgrade Bun"
complete -c bun -n "__fish_use_subcommand" -a "run" -d "Run a script or package binary"
complete -c bun -n "__fish_use_subcommand" -a "install" -d "Install dependencies from package.json" -f
complete -c bun -n "__fish_use_subcommand" -a "remove" -d "Remove a dependency from package.json" -f
complete -c bun -n "__fish_use_subcommand" -a "add" -d "Add a dependency to package.json" -f
complete -c bun -n "__fish_use_subcommand" -a "init" -d "Initialize a Bun project in this directory" -f
complete -c bun -n "__fish_use_subcommand" -a "link" -d "Register or link a local npm package" -f
complete -c bun -n "__fish_use_subcommand" -a "unlink" -d "Unregister a local npm package" -f
complete -c bun -n "__fish_use_subcommand" -a "pm" -d "Additional package management utilities" -f
complete -c bun -n "__fish_use_subcommand" -a "x" -d "Execute a package binary, installing if needed" -f
complete -c bun -n "__fish_use_subcommand" -a "outdated" -d "Display the latest versions of outdated dependencies" -f
complete -c bun -n "__fish_use_subcommand" -a "publish" -d "Publish your package from local to npm" -f

View File

@@ -0,0 +1,14 @@
# This file was created by fish when upgrading to version 4.3, to migrate
# the 'fish_key_bindings' variable from its old default scope (universal)
# to its new default scope (global). We recommend you delete this file
# and configure key bindings in ~/.config/fish/config.fish if needed.
set --global fish_key_bindings fish_vi_key_bindings
# Prior to version 4.3, fish shipped an event handler that runs
# `set --universal fish_key_bindings fish_default_key_bindings`
# whenever the fish_key_bindings variable is erased.
# This means that as long as any fish < 4.3 is still running on this system,
# we cannot complete the migration.
# As a workaround, erase the universal variable at every shell startup.
set --erase --universal fish_key_bindings

View File

@@ -0,0 +1,37 @@
# This file was created by fish when upgrading to version 4.3, to migrate
# theme variables from universal to global scope.
# Don't edit this file, as it will be written by the web-config tool (`fish_config`).
# To customize your theme, delete this file and see
# help interactive#syntax-highlighting
# or
# man fish-interactive | less +/^SYNTAX.HIGHLIGHTING
# for appropriate commands to add to ~/.config/fish/config.fish instead.
# See also the release notes for fish 4.3.0 (run `help relnotes`).
set --global fish_color_autosuggestion brblack
set --global fish_color_cancel -r
set --global fish_color_command normal
set --global fish_color_comment red
set --global fish_color_cwd green
set --global fish_color_cwd_root red
set --global fish_color_end green
set --global fish_color_error brred
set --global fish_color_escape brcyan
set --global fish_color_history_current --bold
set --global fish_color_host normal
set --global fish_color_host_remote yellow
set --global fish_color_normal normal
set --global fish_color_operator brcyan
set --global fish_color_param cyan
set --global fish_color_quote yellow
set --global fish_color_redirection cyan --bold
set --global fish_color_search_match white --background=brblack
set --global fish_color_selection white --bold --background=brblack
set --global fish_color_status red
set --global fish_color_user brgreen
set --global fish_color_valid_path --underline
set --global fish_pager_color_completion normal
set --global fish_pager_color_description yellow -i
set --global fish_pager_color_prefix normal --bold --underline
set --global fish_pager_color_progress brwhite --background=cyan
set --global fish_pager_color_selected_background -r

View File

@@ -0,0 +1 @@
source "$HOME/.cargo/env.fish"

View File

@@ -0,0 +1,2 @@
source "$HOME/.local/bin/env.fish"

152
fish/files/config.fish Normal file
View File

@@ -0,0 +1,152 @@
# Only execute this file once per shell.
set -q __fish_home_manager_config_sourced; and exit
set -g __fish_home_manager_config_sourced 1
# Add ROCm bin directory to PATH
set -gx PATH "/opt/rocm/bin" $PATH
set --export VOLTA_HOME "$HOME/.volta"
set --export PATH "$VOLTA_HOME/bin" $PATH
set --export EDITOR "nvim"
status is-login; and begin
# Login shell initialisation
end
status is-interactive; and begin
# Abbreviations
# Aliases
alias che chezmoi
alias gb 'git branch'
alias gca 'git commit --amend'
alias gchd 'git checkout develop'
alias gchm 'git checkout main'
alias gcho 'git checkout'
alias gcnv 'git commit --no-verify'
alias gd 'git diff'
alias gdc 'git diff --cached'
alias gdt 'git diff-tree --no-commit-id --name-only -r'
alias gf 'git fetch'
alias gl 'git pull'
alias gm 'git merge'
alias gp 'git push'
alias gpuoh 'git push --set-upstream origin HEAD'
alias gr 'git remote'
alias gra 'git remote add'
alias grr 'git remote remove'
alias grv 'git remote -v'
alias gs 'git status'
alias nv nvim
# alias yay paru
alias wo 'pomodoro work'
alias br 'pomodoro break'
# Interactive shell initialisation
fish_config theme choose rose-pine-moon
set fish_greeting # Disable greeting
test -f /run/current-system/sw/share/autojump/autojump.fish; and source /run/current-system/sw/share/autojump/autojump.fish
[ -f /opt/homebrew/share/autojump/autojump.fish ]; and source /opt/homebrew/share/autojump/autojump.fish
test -f ~/.env; and source ~/.env
test -f ~/.config/myvars; and source ~/.config/myvars
nerdfetch
if test "$TERM" != dumb
eval (starship init fish)
fzf --fish | source
end
# add completions generated by Home Manager to $fish_complete_path
begin
set -l joined (string join " " $fish_complete_path)
set -l prev_joined (string replace --regex "[^\s]*generated_completions.*" "" $joined)
set -l post_joined (string replace $prev_joined "" $joined)
set -l prev (string split " " (string trim $prev_joined))
set -l post (string split " " (string trim $post_joined))
set fish_complete_path $prev "/home/thomasgl/.local/share/fish/home-manager_generated_completions" $post
end
end
# pnpm
switch (uname)
case Linux
set -gx PNPM_HOME "/home/thomasgl/.local/share/pnpm"
case Darwin
set -gx PNPM_HOME "/Users/thomasglopes/.local/share/pnpm"
end
if not string match -q -- $PNPM_HOME $PATH
set -gx PATH "$PNPM_HOME" $PATH
end
# pnpm end
set -Ux ENV ~/.config/fish/config.fish
if not set -q SSH_AUTH_SOCK
# Check if ssh-agent is already running and accessible
set -l agent_pid (pgrep ssh-agent | head -n 1)
if test -n "$agent_pid"
# Try to find existing socket
set -l sock_path (find /tmp -name "ssh-*" -type d 2>/dev/null | \
xargs -I {} find {} -name "agent.*" 2>/dev/null | head -n 1)
if test -n "$sock_path"
set -gx SSH_AUTH_SOCK "$sock_path"
set -gx SSH_AGENT_PID "$agent_pid"
# Test if agent is responsive
if ssh-add -l >/dev/null 2>&1
# echo "Connected to existing ssh-agent (PID: $agent_pid)"
return 0
else
# Clean up stale variables
set -e SSH_AUTH_SOCK SSH_AGENT_PID
end
end
end
# Start new ssh-agent
# echo "Starting new ssh-agent..."
set -l agent_output (ssh-agent -c)
# Parse output and set variables
for line in $agent_output
if string match -qr '^setenv SSH_AUTH_SOCK' "$line"
set -gx SSH_AUTH_SOCK (string replace -r '^setenv SSH_AUTH_SOCK (.+);$' '$1' "$line" | string trim -c '"')
else if string match -qr '^setenv SSH_AGENT_PID' "$line"
set -gx SSH_AGENT_PID (string replace -r '^setenv SSH_AGENT_PID (.+);$' '$1' "$line" | string trim -c '"')
end
end
# Verify agent started successfully
if test -z "$SSH_AUTH_SOCK" -o -z "$SSH_AGENT_PID"
# echo "Error: Failed to start ssh-agent" >&2
return 1
end
# echo "ssh-agent started (PID: $SSH_AGENT_PID)"
end
# bun
set --export BUN_INSTALL "$HOME/.bun"
set --export PATH $BUN_INSTALL/bin $PATH
# opencode
fish_add_path /home/thomasgl/.opencode/bin
source ~/.safe-chain/scripts/init-fish.fish # Safe-chain Fish initialization script

View File

@@ -0,0 +1,7 @@
source /usr/share/cachyos-fish-config/cachyos-config.fish
# overwrite greeting
# potentially disabling fastfetch
#function fish_greeting
# # smth smth
#end

View File

@@ -0,0 +1,30 @@
function bw-create-note
function bw-create-note --argument-names content_or_name name
if isatty stdin
# Direct input mode
set notes_content $content_or_name
set note_name $name
else
# Pipe mode
read -z notes_content
set note_name $content_or_name
end
# If no name provided, use default
if test -z "$note_name"
set note_name secure-note
end
# If no content, show usage
if test -z "$notes_content"
echo "Usage: bw-create-note 'content' 'note name'"
echo "Or: command | bw-create-note 'note name'"
return 1
end
bw get template item | jq --arg folderId (bw list folders | jq -r '.[] | select(.name == "chezmoi") | .id') \
--arg notes "$notes_content" \
--arg name "$note_name" \
'.type = 2 | .secureNote.type = 0 | .notes=$notes | .name = $name | .folderId=$folderId' | bw encode | bw create item
end
end

View File

@@ -0,0 +1,3 @@
function bw-unlock
set -Ux BW_SESSION (bw unlock --raw || echo "Error unlocking BW")
end

View File

@@ -0,0 +1,11 @@
function pomodoro --argument type
set -l durations work 45 break 10
set -l idx (contains -i -- $type $durations)
if test -n "$idx"
set -l minutes $durations[(math $idx + 1)]
echo $type | lolcat
timer {$minutes}m
espeak "$type session done"
end
end

View File

@@ -0,0 +1,6 @@
function reload-env
for line in (grep -v '^#' /etc/environment | grep '=')
set -l pair (string split -m 1 '=' $line)
set -gx $pair[1] $pair[2]
end
end

View File

@@ -0,0 +1,8 @@
function y
set tmp (mktemp -t "yazi-cwd.XXXXXX")
yazi $argv --cwd-file="$tmp"
if set cwd (command cat -- "$tmp"); and [ -n "$cwd" ]; and [ "$cwd" != "$PWD" ]
builtin cd -- "$cwd"
end
rm -f -- "$tmp"
end

49
fish/files/script.sh Executable file
View File

@@ -0,0 +1,49 @@
#!/bin/bash
# Directory to process
TARGET_DIR="/home/thomasgl/.config/fish-backup" # Make sure this is the correct, full path
# Check if the directory exists
if [ ! -d "$TARGET_DIR" ]; then
echo "Error: Directory '$TARGET_DIR' not found."
exit 1
fi
# Find symlinks and process them
find "$TARGET_DIR" -type l -print0 | while IFS= read -r -d $'\0' SYMLINK; do
echo "Processing symlink: $SYMLINK"
# Get the target of the symlink
TARGET=$(readlink "$SYMLINK")
# Check if readlink was successful and the target exists
if [ $? -eq 0 ] && [ -e "$TARGET" ]; then
echo " Target: $TARGET"
# *** Explicitly remove the symlink BEFORE copying ***
echo " Removing symlink: $SYMLINK"
rm "$SYMLINK"
# Check if removal was successful
if [ $? -eq 0 ]; then
# Copy the target file to the location where the symlink was
echo " Copying target to $SYMLINK"
cp "$TARGET" "$SYMLINK"
if [ $? -eq 0 ]; then
echo " Replaced symlink with a copy of the target."
else
echo " Error: Failed to copy target to $SYMLINK."
fi
else
echo " Error: Failed to remove symlink: $SYMLINK. Cannot proceed with copy."
fi
else
echo " Warning: Could not resolve target for '$SYMLINK' or target does not exist."
fi
done
echo "Processing complete."

View File

@@ -0,0 +1,41 @@
# syntax highlighting variables
# https://fishshell.com/docs/current/interactive.html#syntax-highlighting-variables
fish_color_normal e0def4
fish_color_command c4a7e7
fish_color_keyword 9ccfd8
fish_color_quote f6c177
fish_color_redirection 3e8fb0
fish_color_end 908caa
fish_color_error eb6f92
fish_color_param ea9a97
fish_color_comment 908caa
# fish_color_match --background=brblue
fish_color_selection --reverse
# fish_color_history_current --bold
fish_color_operator e0def4
fish_color_escape 3e8fb0
fish_color_autosuggestion 908caa
fish_color_cwd ea9a97
# fish_color_cwd_root red
fish_color_user f6c177
fish_color_host 9ccfd8
fish_color_host_remote c4a7e7
fish_color_cancel e0def4
fish_color_search_match --background=232136
fish_color_valid_path
# pager color variables
# https://fishshell.com/docs/current/interactive.html#pager-color-variables
fish_pager_color_progress ea9a97
fish_pager_color_background --background=2a273f
fish_pager_color_prefix 9ccfd8
fish_pager_color_completion 908caa
fish_pager_color_description 908caa
fish_pager_color_secondary_background
fish_pager_color_secondary_prefix
fish_pager_color_secondary_completion
fish_pager_color_secondary_description
fish_pager_color_selected_background --background=393552
fish_pager_color_selected_prefix 9ccfd8
fish_pager_color_selected_completion e0def4
fish_pager_color_selected_description e0def4

6
jj/config.lua Normal file
View File

@@ -0,0 +1,6 @@
return {
target = {
linux = "~/.config/jj",
default = "~/.config/jj",
},
}

6
jj/files/config.toml Normal file
View File

@@ -0,0 +1,6 @@
[user]
name = "Thomas G. Lopes"
email = "thomasgl@pm.me"
[git]
write-change-id-header = true

6
jjui/config.lua Normal file
View File

@@ -0,0 +1,6 @@
return {
target = {
linux = "~/.config/jjui",
default = "~/.config/jjui",
},
}

3
jjui/files/config.toml Normal file
View File

@@ -0,0 +1,3 @@
[ui.theme]
dark = "matugen"
light = "matugen"

View File

@@ -0,0 +1,51 @@
"text" = { fg = "#f0dfd6", bg = "#19120d" }
"dimmed" = { fg = "#d6c3b7" }
"selected" = { bg = "#6d390a", fg = "#ffdcc5" }
"border" = { fg = "#9f8d83" }
"title" = { fg = "#ffb782", bold = true }
"shortcut" = { fg = "#e4bfa7" }
"matched" = { fg = "#c7ca95", underline = true }
"source_marker" = { bg = "#464920", fg = "#e3e6af" }
"target_marker" = { bg = "#93000a", fg = "#ffdad6" }
"revisions rebase source_marker" = { bold = true }
"revisions rebase target_marker" = { bold = true }
"status" = { bg = "#312822" }
"status title" = { fg = "#4f2500", bg = "#ffb782", bold = true }
"status shortcut" = { fg = "#e4bfa7" }
"status dimmed" = { fg = "#d6c3b7" }
"revset text" = { bold = true }
"revset completion selected" = { bg = "#6d390a", fg = "#ffdcc5" }
"revset completion matched" = { bold = true }
"revset completion dimmed" = { fg = "#d6c3b7" }
"revisions selected" = { bold = true }
"oplog selected" = { bold = true }
"evolog selected" = { bg = "#5b412f", fg = "#ffdcc5", bold = true }
"help" = { bg = "#261e18" }
"help title" = { fg = "#ffb782", bold = true, underline = true }
"help border" = { fg = "#9f8d83" }
"menu" = { bg = "#261e18" }
"menu title" = { fg = "#ffb782", bold = true }
"menu shortcut" = { fg = "#e4bfa7" }
"menu dimmed" = { fg = "#d6c3b7" }
"menu border" = { fg = "#9f8d83" }
"menu selected" = { bg = "#6d390a", fg = "#ffdcc5" }
"confirmation" = { bg = "#261e18" }
"confirmation text" = { fg = "#f0dfd6" }
"confirmation selected" = { bg = "#6d390a", fg = "#ffdcc5" }
"confirmation dimmed" = { fg = "#d6c3b7" }
"confirmation border" = { fg = "#ffb782" }
"undo" = { bg = "#261e18" }
"undo confirmation dimmed" = { fg = "#d6c3b7" }
"undo confirmation selected" = { bg = "#6d390a", fg = "#ffdcc5" }
"preview" = { fg = "#f0dfd6" }

6
kitty/config.lua Normal file
View File

@@ -0,0 +1,6 @@
return {
target = {
linux = "~/.config/kitty",
default = "~/.config/kitty",
},
}

View File

@@ -0,0 +1,80 @@
# vim:ft=kitty
## name: Catppuccin-Macchiato
## author: Pocco81 (https://github.com/Pocco81)
## license: MIT
## upstream: https://github.com/catppuccin/kitty/blob/main/macchiato.conf
## blurb: Soothing pastel theme for the high-spirited!
# The basic colors
foreground #CAD3F5
background #24273A
selection_foreground #24273A
selection_background #F4DBD6
# Cursor colors
cursor #F4DBD6
cursor_text_color #24273A
# URL underline color when hovering with mouse
url_color #F4DBD6
# Kitty window border colors
active_border_color #B7BDF8
inactive_border_color #6E738D
bell_border_color #EED49F
# OS Window titlebar colors
wayland_titlebar_color system
macos_titlebar_color system
# Tab bar colors
active_tab_foreground #181926
active_tab_background #C6A0F6
inactive_tab_foreground #CAD3F5
inactive_tab_background #1E2030
tab_bar_background #181926
# Colors for marks (marked text in the terminal)
mark1_foreground #24273A
mark1_background #B7BDF8
mark2_foreground #24273A
mark2_background #C6A0F6
mark3_foreground #24273A
mark3_background #7DC4E4
# The 16 terminal colors
# black
color0 #494D64
color8 #5B6078
# red
color1 #ED8796
color9 #ED8796
# green
color2 #A6DA95
color10 #A6DA95
# yellow
color3 #EED49F
color11 #EED49F
# blue
color4 #8AADF4
color12 #8AADF4
# magenta
color5 #F5BDE6
color13 #F5BDE6
# cyan
color6 #8BD5CA
color14 #8BD5CA
# white
color7 #B8C0E0
color15 #A5ADCB

View File

@@ -0,0 +1,80 @@
# vim:ft=kitty
## name: Catppuccin-Macchiato
## author: Pocco81 (https://github.com/Pocco81)
## license: MIT
## upstream: https://github.com/catppuccin/kitty/blob/main/macchiato.conf
## blurb: Soothing pastel theme for the high-spirited!
# The basic colors
foreground #CAD3F5
background #24273A
selection_foreground #24273A
selection_background #F4DBD6
# Cursor colors
cursor #F4DBD6
cursor_text_color #24273A
# URL underline color when hovering with mouse
url_color #F4DBD6
# Kitty window border colors
active_border_color #B7BDF8
inactive_border_color #6E738D
bell_border_color #EED49F
# OS Window titlebar colors
wayland_titlebar_color system
macos_titlebar_color system
# Tab bar colors
active_tab_foreground #181926
active_tab_background #7dc4e4
inactive_tab_foreground #CAD3F5
inactive_tab_background #1E2030
tab_bar_background #181926
# Colors for marks (marked text in the terminal)
mark1_foreground #24273A
mark1_background #B7BDF8
mark2_foreground #24273A
mark2_background #C6A0F6
mark3_foreground #24273A
mark3_background #7DC4E4
# The 16 terminal colors
# black
color0 #494D64
color8 #5B6078
# red
color1 #ED8796
color9 #ED8796
# green
color2 #A6DA95
color10 #A6DA95
# yellow
color3 #EED49F
color11 #EED49F
# blue
color4 #8AADF4
color12 #8AADF4
# magenta
color5 #F5BDE6
color13 #F5BDE6
# cyan
color6 #8BD5CA
color14 #8BD5CA
# white
color7 #B8C0E0
color15 #A5ADCB

2659
kitty/files/kitty.conf Normal file

File diff suppressed because it is too large Load Diff

2653
kitty/files/kitty.conf.bak Normal file

File diff suppressed because it is too large Load Diff

6
nvim/config.lua Normal file
View File

@@ -0,0 +1,6 @@
return {
target = {
linux = "~/.config/nvim",
default = "~/.config/nvim",
},
}

56
nvim/files/Session.vim Normal file
View File

@@ -0,0 +1,56 @@
let SessionLoad = 1
let s:so_save = &g:so | let s:siso_save = &g:siso | setg so=0 siso=0 | setl so=-1 siso=-1
let v:this_session=expand("<sfile>:p")
silent only
silent tabonly
cd ~/.config/nvim
if expand('%') == '' && !&modified && line('$') <= 1 && getline(1) == ''
let s:wipebuf = bufnr('%')
endif
let s:shortmess_save = &shortmess
if &shortmess =~ 'A'
set shortmess=aoOA
else
set shortmess=aoO
endif
badd +198 lua/thomasgen/lazy/mini.lua
badd +1 lua/thomasgen/lazy/telescope.lua
badd +3 lua/thomasgen/lazy/colors.lua
badd +1 ~/.config/nvim/lua/thomasgen/lazy/alpha.lua
argglobal
%argdel
edit ~/.config/nvim/lua/thomasgen/lazy/alpha.lua
argglobal
balt lua/thomasgen/lazy/mini.lua
setlocal fdm=manual
setlocal fde=0
setlocal fmr={{{,}}}
setlocal fdi=#
setlocal fdl=0
setlocal fml=1
setlocal fdn=20
setlocal fen
silent! normal! zE
let &fdl = &fdl
let s:l = 10 - ((9 * winheight(0) + 29) / 59)
if s:l < 1 | let s:l = 1 | endif
keepjumps exe s:l
normal! zt
keepjumps 10
normal! 0
tabnext 1
if exists('s:wipebuf') && len(win_findbuf(s:wipebuf)) == 0 && getbufvar(s:wipebuf, '&buftype') isnot# 'terminal'
silent exe 'bwipe ' . s:wipebuf
endif
unlet! s:wipebuf
set winheight=1 winwidth=20
let &shortmess = s:shortmess_save
let s:sx = expand("<sfile>:p:r")."x.vim"
if filereadable(s:sx)
exe "source " . fnameescape(s:sx)
endif
let &g:so = s:so_save | let &g:siso = s:siso_save
nohlsearch
doautoall SessionLoadPost
unlet SessionLoad
" vim: set ft=vim :

View File

@@ -0,0 +1,11 @@
-- Material You colorscheme for Neovim
-- Generated by matugen
-- Load the matugen module which has the theme setup
local ok, matugen = pcall(require, "matugen")
if not ok then
vim.notify("Failed to load matugen module", vim.log.levels.ERROR)
return
end
-- The module will automatically set up the colorscheme

42
nvim/files/init.lua Normal file
View File

@@ -0,0 +1,42 @@
require("set")
require("remap")
-- [[ Install `lazy.nvim` plugin manager ]]
-- See `:help lazy.nvim.txt` or https://github.com/folke/lazy.nvim for more info
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
if vim.v.shell_error ~= 0 then
error("Error cloning lazy.nvim:\n" .. out)
end
end
---@type vim.Option
local rtp = vim.opt.rtp
rtp:prepend(lazypath)
require("lazy").setup({
import = "plugins",
}, {
ui = {
icons = vim.g.have_nerd_font and {} or {
cmd = "",
config = "🛠",
event = "📅",
ft = "📂",
init = "",
keys = "🗝",
plugin = "🔌",
runtime = "💻",
require = "🌙",
source = "📄",
start = "🚀",
task = "📌",
lazy = "💤 ",
},
},
})
-- The line beneath this is called `modeline`. See `:help modeline`
-- vim: ts=2 sts=2 sw=2 et

25
nvim/files/lsp/biome.lua Normal file
View File

@@ -0,0 +1,25 @@
return {
cmd = { "biome", "lsp-proxy" },
filetypes = {
"javascript",
"javascriptreact",
"typescript",
"typescriptreact",
"json",
"jsonc",
"astro",
"css",
"graphql",
"vue",
"svelte",
},
root_markers = { "biome.json", "biome.jsonc" },
on_attach = function(client, bufnr)
vim.api.nvim_create_autocmd("BufWritePre", {
buffer = bufnr,
callback = function()
vim.lsp.buf.format({ bufnr = bufnr, id = client.id })
end,
})
end,
}

10
nvim/files/lsp/cssls.lua Normal file
View File

@@ -0,0 +1,10 @@
return {
cmd = { "vscode-css-language-server", "--stdio" },
filetypes = { "css", "scss", "less" },
root_markers = { "package.json", ".git" },
settings = {
css = { validate = true },
scss = { validate = true },
less = { validate = true },
},
}

82
nvim/files/lsp/eslint.lua Normal file
View File

@@ -0,0 +1,82 @@
return {
cmd = { "vscode-eslint-language-server", "--stdio" },
filetypes = {
"javascript",
"javascriptreact",
"javascript.jsx",
"typescript",
"typescriptreact",
"typescript.tsx",
"vue",
"svelte",
"astro",
},
root_dir = function(bufnr, on_dir)
local fname = vim.api.nvim_buf_get_name(bufnr)
local root = vim.fs.root(fname, {
".eslintrc",
".eslintrc.js",
".eslintrc.cjs",
".eslintrc.yaml",
".eslintrc.yml",
".eslintrc.json",
"eslint.config.js",
"eslint.config.mjs",
"eslint.config.cjs",
"eslint.config.ts",
"eslint.config.mts",
"eslint.config.cts",
"package.json",
})
-- Disable ESLint if Biome is detected
if root then
local biome_json = vim.fs.joinpath(root, "biome.json")
local biome_jsonc = vim.fs.joinpath(root, "biome.jsonc")
local has_biome = vim.fn.filereadable(biome_json) == 1 or vim.fn.filereadable(biome_jsonc) == 1
if has_biome then
vim.notify("ESLint disabled - Biome detected in " .. root, vim.log.levels.INFO)
on_dir(nil)
return
end
end
on_dir(root)
end,
settings = {
codeAction = {
disableRuleComment = {
enable = true,
location = "separateLine",
},
showDocumentation = {
enable = true,
},
},
codeActionOnSave = {
enable = false,
mode = "all",
},
format = true,
nodePath = "",
onIgnoredFiles = "off",
problems = {
shortenToSingleLine = false,
},
quiet = false,
rulesCustomizations = {},
run = "onType",
useESLintClass = false,
validate = "on",
workingDirectory = {
mode = "location",
},
},
on_attach = function(_, bufnr)
vim.api.nvim_create_autocmd("BufWritePre", {
buffer = bufnr,
command = "EslintFixAll",
})
end,
}

View File

@@ -0,0 +1,5 @@
return {
cmd = { "nc", "localhost", "6005" },
filetypes = { "gd", "gdscript", "gdscript3" },
root_markers = { "project.godot", ".git" },
}

12
nvim/files/lsp/lua_ls.lua Normal file
View File

@@ -0,0 +1,12 @@
return {
cmd = { "lua-language-server" },
filetypes = { "lua" },
root_markers = { ".luarc.json", ".luarc.jsonc", ".git" },
settings = {
Lua = {
completion = {
callSnippet = "Replace",
},
},
},
}

View File

@@ -0,0 +1,38 @@
return {
cmd = { "pyright-langserver", "--stdio" },
filetypes = { "python" },
root_markers = { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", ".git" },
on_new_config = function(new_config, root_dir)
local resolved_root = vim.fs.normalize(vim.fn.expand(root_dir))
local venv_python = resolved_root .. "/.venv/bin/python"
if vim.uv.fs_stat(venv_python) then
new_config.settings = new_config.settings or {}
new_config.settings.python = new_config.settings.python or {}
new_config.settings.python.pythonPath = venv_python
end
end,
on_init = function(client)
local root_dir = client.config.root_dir
if not root_dir then
return
end
local resolved_root = vim.fs.normalize(vim.fn.expand(root_dir))
local venv_python = resolved_root .. "/.venv/bin/python"
if vim.uv.fs_stat(venv_python) then
client.config.settings = client.config.settings or {}
client.config.settings.python = client.config.settings.python or {}
client.config.settings.python.pythonPath = venv_python
client.notify("workspace/didChangeConfiguration", { settings = client.config.settings })
end
end,
settings = {
python = {
analysis = {
autoSearchPaths = true,
useLibraryCodeForTypes = true,
diagnosticMode = "openFilesOnly",
},
},
},
}

View File

@@ -0,0 +1,5 @@
return {
cmd = { "svelteserver", "--stdio" },
filetypes = { "svelte" },
root_markers = { "svelte.config.js", "svelte.config.mjs", "svelte.config.cjs", "package.json", ".git" },
}

View File

@@ -0,0 +1,52 @@
return {
filetypes = {
"aspnetcorerazor",
"astro",
"astro-markdown",
"blade",
"clojure",
"django-html",
"htmldjango",
"edge",
"eelixir",
"elixir",
"ejs",
"erb",
"eruby",
"gohtml",
"gohtmltmpl",
"haml",
"handlebars",
"hbs",
"html",
"html-eex",
"heex",
"jade",
"leaf",
"liquid",
"markdown",
"mdx",
"mustache",
"njk",
"nunjucks",
"php",
"razor",
"slim",
"twig",
"css",
"less",
"postcss",
"sass",
"scss",
"stylus",
"sugarss",
"javascript",
"javascriptreact",
"reason",
"rescript",
"typescript",
"typescriptreact",
"vue",
"svelte",
},
}

36
nvim/files/lsp/tsgo.lua Normal file
View File

@@ -0,0 +1,36 @@
return {
cmd = { "tsgo", "--lsp", "--stdio" },
filetypes = { "javascript", "javascriptreact", "typescript", "typescriptreact" },
-- Use .git to find monorepo root so vtsls indexes ALL packages
root_markers = { ".git" },
-- Reuse client across projects for cross-package references
reuse_client = function(client, config)
return client.name == config.name
end,
settings = {
vtsls = {
autoWorkspaceCache = true, -- Helps index the workspace in the background
tsserver = {
maxMemory = 8192, -- Give it 8GB of RAM for large projects
globalPlugins = {
{
name = "typescript-svelte-plugin",
location = vim.fn.stdpath("data")
.. "/mason/packages/svelte-language-server/node_modules/typescript-svelte-plugin",
enableForWorkspaceTypeScriptVersions = true,
},
},
},
},
typescript = {
tsserver = {
maxTsServerMemory = 8192,
maxMemory = 8192, -- Give it 8GB of RAM for large projects
},
},
},
commands = {
-- Suppress "does not support command" notification for organize imports
["_typescript.didOrganizeImports"] = function() end,
},
}

35
nvim/files/lsp/vtsls.lua Normal file
View File

@@ -0,0 +1,35 @@
return {
cmd = { "vtsls", "--stdio" },
filetypes = { "javascript", "javascriptreact", "typescript", "typescriptreact" },
-- Use .git to find monorepo root so vtsls indexes ALL packages
root_markers = { ".git" },
-- Reuse client across projects for cross-package references
reuse_client = function(client, config)
return client.name == config.name
end,
settings = {
vtsls = {
autoWorkspaceCache = true, -- Helps index the workspace in the background
tsserver = {
maxMemory = 8192, -- Give it 8GB of RAM for large projects
globalPlugins = {
{
name = "typescript-svelte-plugin",
location = vim.fn.stdpath("data")
.. "/mason/packages/svelte-language-server/node_modules/typescript-svelte-plugin",
enableForWorkspaceTypeScriptVersions = true,
},
},
},
},
typescript = {
tsserver = {
maxTsServerMemory = 8192,
},
},
},
commands = {
-- Suppress "does not support command" notification for organize imports
["_typescript.didOrganizeImports"] = function() end,
},
}

View File

@@ -0,0 +1,4 @@
return {
"tpope/vim-abolish",
enabled = true,
}

View File

@@ -0,0 +1,53 @@
return {
"goolord/alpha-nvim",
dependencies = {
{
"catppuccin/nvim",
name = "catppuccin",
priority = 1000, -- Load colorscheme before other plugins
},
"echasnovski/mini.icons",
"nvim-lua/plenary.nvim",
},
config = function()
local alpha_c = function()
local alpha = require("alpha")
local dashboard = require("alpha.themes.dashboard")
local scan = require("plenary.scandir")
-- Get the runtime path where your headers are stored
local runtime_path = vim.fn.stdpath("config") .. "/lua/plugins/alpha_headers"
-- Scan for all Lua files in the headers directory
local headers = {}
for _, file in ipairs(scan.scan_dir(runtime_path, { search_pattern = "%.lua$" })) do
-- Extract just the filename without extension and path
local header_name = vim.fn.fnamemodify(file, ":t:r")
table.insert(headers, header_name)
end
-- Randomly select a header
math.randomseed(os.time()) -- Initialize random seed
local random_header = headers[math.random(#headers)]
-- Construct the full path and require the header
local header = "plugins.alpha_headers." .. random_header
require(header).setup(dashboard)
dashboard.section.buttons.val = {
dashboard.button("n", " New file", "<Cmd>ene <CR>"),
dashboard.button("SPC p f", " Find file"),
dashboard.button("SPC p v", " Open Oil"),
dashboard.button("SPC w q", " Quit"),
}
for _, a in ipairs(dashboard.section.buttons.val) do
a.opts.width = 49
a.opts.cursor = -2
end
alpha.setup(dashboard.config)
end
alpha_c()
end,
}

View File

@@ -0,0 +1,142 @@
local function getLen(str, start_pos)
local byte = string.byte(str, start_pos)
if not byte then
return nil
end
return (byte < 0x80 and 1) or (byte < 0xE0 and 2) or (byte < 0xF0 and 3) or (byte < 0xF8 and 4) or 1
end
local function colorize(header, header_color_map, colors)
for letter, color in pairs(colors) do
local color_name = "AlphaJemuelKwelKwelWalangTatay" .. letter
vim.api.nvim_set_hl(0, color_name, color)
colors[letter] = color_name
end
local colorized = {}
for i, line in ipairs(header_color_map) do
local colorized_line = {}
local pos = 0
for j = 1, #line do
local start = pos
pos = pos + getLen(header[i], start + 1)
local color_name = colors[line:sub(j, j)]
if color_name then
table.insert(colorized_line, { color_name, start, pos })
end
end
table.insert(colorized, colorized_line)
end
return colorized
end
local M = {}
M.setup = function(dashboard)
local color = require("util.color")
local alpha = require("alpha")
local mocha = require("catppuccin.palettes").get_palette("mocha")
local color_map = {
[[ AAAA]],
[[AAAAAA AAAA]],
[[AA AAAA AAAA KKHHKKHHHH]],
[[AAAA AAAA AA HHBBKKKKKKKKKKKKKK]],
[[ AAAAAA AAKKBBHHKKBBYYBBKKKKHHKKKKKK]],
[[ AAAA BBAAKKHHBBBBKKKKBBYYBBHHHHKKKKKK]],
[[ BBAABBKKYYYYHHKKYYYYKKKKBBBBBBZZZZZZ]],
[[ YYBBYYBBKKYYYYYYYYYYKKKKBBKKAAAAZZOOZZZZ]],
[[ XXXXYYYYBBYYYYYYYYBBBBBBKKKKBBBBAAAAZZZZ]],
[[ XXXXUUUUYYYYBBYYYYYYBBKKBBZZOOAAZZOOAAAAAA]],
[[ ZZZZZZXXUUXXXXYYYYYYYYBBAAAAZZOOOOAAOOZZZZAAAA]],
[[ ZZUUZZXXUUUUXXXXUUXXFFFFFFFFAAAAOOZZAAZZZZ AA]],
[[ RRRRUUUUZZZZZZZZXXOOFFFFOOZZOOAAAAAAZZZZAA]],
[[ CCSSUUUUZZXXXXZZXXOOFFFFOOZZOOOOZZOOAAAA]],
[[ CCCCUUUUUUUUUURRRROOFFFFOOZZOOOOZZOOZZZZ]],
[[ CCCCUUUUUUUUSSCCCCEEQQQQOOZZOOOOZZOOZZZZ]],
[[ CCCCUUGGUUUUCCCCCCEEQQQQOOZZOOOOZZEEZZ]],
[[ RRRRGGGGUUGGCCCCCCOOOOOOOOZZOOEEZZII]],
[[ IIRRGGGGGGCCCCCCOOOOOOOOZZEEII]],
[[ GGRRCCCCCCOOOOEEEEII II]],
[[ RRRRRREEEE IIII]],
[[ II]],
[[]],
}
local yellow = "#FAC87C"
local orange = "#BF854E"
local maroon = "#502E2B"
local brown = "#38291B"
local colors = {
["A"] = { fg = mocha.rosewater },
["Y"] = { fg = yellow },
["B"] = { fg = color.darken(yellow, 5) },
["X"] = { fg = color.darken(yellow, 20) },
["U"] = { fg = color.darken(yellow, 25) },
["F"] = { fg = color.darken(yellow, 35) },
["O"] = { fg = color.darken(yellow, 45) },
["K"] = { fg = maroon },
["H"] = { fg = color.darken(maroon, 10) },
["Z"] = { fg = mocha.crust },
["G"] = { fg = color.darken(yellow, 25) },
["R"] = { fg = orange },
["Q"] = { fg = color.darken(orange, 20) },
["E"] = { fg = color.darken(orange, 35) },
["I"] = { fg = brown },
["C"] = { fg = mocha.mantle },
["S"] = { fg = mocha.subtext1 },
}
local header = {}
for _, line in ipairs(color_map) do
local header_line = [[]]
for i = 1, #line do
if line:sub(i, i) ~= " " then
header_line = header_line .. ""
else
header_line = header_line .. " "
end
end
table.insert(header, header_line)
end
local header_add = [[ N E O B E E ]]
table.insert(header, header_add)
local hl_add = {}
for i = 1, #header_add do
table.insert(hl_add, { "NeoBeeTitle", 1, i })
end
dashboard.section.header.val = header
local colorized = colorize(header, color_map, colors)
table.insert(colorized, hl_add)
dashboard.section.header.opts = {
hl = colorized,
position = "center",
}
dashboard.section.buttons.val = {
dashboard.button("SPC e e", " New file", "<Cmd>ene <CR>"),
dashboard.button("SPC f f", " Find file"),
dashboard.button("SPC s s", " NeoBee config", "<Cmd>Neotree reveal ~/.config/nvim<CR>"),
dashboard.button("SPC q q", " Quit", "<Cmd>qa<CR>"),
}
for _, a in ipairs(dashboard.section.buttons.val) do
a.opts.width = 49
a.opts.cursor = -2
end
alpha.setup(dashboard.config)
end
return M

View File

@@ -0,0 +1,37 @@
local M = {}
M.setup = function(dashboard)
vim.api.nvim_set_hl(0, "AlphaHeaderRed", { fg = _G.matugen_palette.color12, bold = true })
local logo = {
"⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡿⠿⠋⠀⢀⣼⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡇⠀⠈⠉⠉⠙⠛⠛⠻⢿⣿⡿⠟⠁⠀⣀⣴⣿⣿⣿⣿⣿⠟",
"⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠃⠀⠀⢀⣴⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠟⠛⣉⣡⠀⣠⣴⣶⣶⣦⠄⣀⡀⠀⠀⠀⣠⣾⣿⣿⣿⣿⣿⡿⢃⣾",
"⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡏⠀⣾⣤⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠏⣠⣾⡟⢡⣾⣿⣿⣿⡿⢋⣴⣿⡿⢀⣴⣾⣿⣿⣿⣿⣿⣿⣿⢡⣾⣿",
"⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠟⠃⠀⢻⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠃⣼⣿⡟⣰⣿⣿⣿⣿⠏⣰⣿⣿⠟⣠⣿⣿⣿⣿⣿⣿⣿⣿⣿⡇⢚⣛⢿",
"⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠏⠀⣠⣾⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣟⠸⣿⠟⢰⣿⣿⣿⣿⠃⣾⣿⣿⠏⣴⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡿⢋⣾",
"⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠿⠻⠻⠃⠀⣴⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡄⢉⣴⣿⣿⣿⣿⡇⠘⣿⣿⠋⣼⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣧⡘⣿",
"⣿⣿⣿⣿⣿⣿⣿⣿⡿⠿⠿⣿⣿⣿⣿⠁⢀⣀⠀⢀⣾⣿⣿⣿⣿⣿⣿⠟⠉⠉⠉⢿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣦⣤⣤⣾⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣷⣌",
"⣿⣿⣿⣿⣿⣿⡿⠁⣀⣤⡀⠀⠈⠻⢿⠀⣼⣿⣷⣿⣿⣿⣿⣿⣿⡿⠁⠀⠀⠀⠀⠘⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿",
"⣿⣿⣿⠟⠛⠙⠃⠀⣿⣿⣿⠀⠀⠀⠀⠀⠙⠿⣿⣿⣿⣿⣿⣿⣿⠀⠀⠀⠀⠀⠀⠀⣾⣿⣿⡿⠿⠿⠿⠿⢿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠛⠁⠀⠀⠀⠈⠻⣿⣿⣿⣿⣿⣿⣿",
"⣿⠟⠁⢀⣴⣶⣶⣾⣿⣿⣿⣿⣶⡐⢦⣄⠀⠀⠈⠛⢿⣿⣿⣿⣿⡀⠀⠀⠀⠀⢀⣼⡿⢛⣩⣴⣶⣶⣶⣶⣶⣶⣭⣙⠻⣿⣿⣿⣿⣿⠀⠀⠀⠀⠀⠀⠀⠀⠘⣿⣿⣿⣿⣿⣿",
"⠁⠀⣴⣿⣿⣿⣿⠿⠿⣿⣿⣿⣿⣿⣦⡙⠻⣶⣄⡀⠀⠈⠙⢿⣿⣷⣦⣤⣤⣴⣿⡏⣠⢸⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣷⣌⠻⣿⣿⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⣿⣿⣿⣿⣿",
"⠀⢸⣿⣿⣿⠋⣠⠔⠀⠀⠻⣿⣿⣿⣿⢉⡳⢦⣉⠛⢷⣤⣀⠀⠈⠙⠿⣿⣿⣿⣿⢸⣿⡄⠻⣿⣿⠟⡈⣿⣿⣿⣿⣿⢉⣿⣧⢹⣿⣿⣄⠀⠀⠀⠀⠀⠀⠀⢠⣿⣿⣿⣿⣿⣿",
"⠀⢸⣿⣿⡇⠠⡇⠀⠀⠀⠀⣿⣿⣿⣿⢸⣿⣷⣤⣙⠢⢌⡛⠷⣤⣄⠀⠈⠙⠿⣿⣿⣿⣿⣷⣦⣴⣾⣿⣤⣙⣛⣛⣥⣾⣿⣿⡌⣿⣿⣿⣷⣤⣀⣀⣀⣠⣴⣿⣿⣿⣿⣿⣿⣿",
"⠀⢸⣿⣿⣷⡀⠡⠀⠀⠀⣰⣿⣿⣿⣿⢸⣿⣿⣿⣿⣿⣦⣌⡓⠤⣙⣿⣦⡄⠀⠈⠙⠿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⢡⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿",
"⠀⢸⣿⣿⣿⣿⣶⣤⣴⣾⣿⣿⣿⣿⣿⢸⣿⣿⣿⣿⣿⣿⣿⣿⣷⣾⣿⣿⣷⠀⣶⡄⠀⠈⠙⠿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡿⢃⣾⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿",
"⠀⢸⣿⣿⣿⣿⣿⠟⠻⣿⣿⡏⣉⣭⣭⡘⠻⢿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠀⣿⡇⢸⡇⢠⡀⠈⠙⠋⠉⠉⠉⠉⠛⠫⣴⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿",
"⠀⢸⣿⣿⠛⣿⣿⣀⣀⣾⡿⢀⣿⣿⣿⢻⣷⣦⢈⡙⠻⢿⣿⣿⣿⣿⣿⣿⣿⠀⣿⡇⢸⡇⢸⣿⠀⣦⠀⠀⠶⣶⣦⣀⠀⠘⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿",
"⠀⢸⣿⣿⣦⣈⡛⠿⠟⣋⣤⣾⣿⣿⣿⣸⣿⣿⢸⡇⢰⡆⢈⡙⠻⢿⣿⣿⣿⠀⢿⡇⢸⡇⢸⣿⢠⣿⡇⣿⡆⢈⡙⠻⠧⠀⢹⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿",
"⠀⠀⣝⠛⢿⣿⣿⣿⣿⣿⣿⠟⣁⠀⠀⢈⠛⠿⢸⣇⢸⡇⢸⡇⣶⣦⣌⡙⠻⢄⡀⠁⠘⠇⠘⣿⢸⣿⡇⣿⡇⢸⡛⠷⣦⣄⠀⠹⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿",
}
-- Keep the logo as a single string to preserve formatting
dashboard.section.header.val = logo
dashboard.section.header.opts = {
position = "center",
hl = "AlphaHeaderRed",
shrink_margin = false,
}
end
return M

View File

@@ -0,0 +1,52 @@
local M = {}
M.setup = function(dashboard)
vim.api.nvim_set_hl(0, "AlphaHeaderRed", { fg = _G.matugen_palette.color12, bold = true })
local logo = {
" :h- Nhy` ",
" -mh. h. `Ndho ",
" hmh+ oNm. oNdhh ",
" `Nmhd` /NNmd /NNhhd ",
" -NNhhy `hMNmmm`+NNdhhh ",
" .NNmhhs ```....`..-:/./mNdhhh+ ",
" mNNdhhh- `.-::///+++////++//:--.`-/sd` ",
" oNNNdhhdo..://++//++++++/+++//++///++/-.` ",
" y. `mNNNmhhhdy+/++++//+/////++//+++///++////-` `/oos: ",
" . Nmy: :NNNNmhhhhdy+/++/+++///:.....--:////+++///:.`:s+ ",
" h- dNmNmy oNNNNNdhhhhy:/+/+++/- ---:/+++//++//.` ",
" hd+` -NNNy`./dNNNNNhhhh+-:///// -+oo:` ::-:+////++///:` ",
" /Nmhs+oss-:++/dNNNmhho:--::/// /mmmmmo ../-///++///////. ",
" oNNdhhhhhhhs//osso/:---:::/// /yyyyso ..o+-//////////:/. ",
" /mNNNmdhhhh/://+///:::////// -:::- ..+sy+:////////::/:/. ",
" /hNNNdhhs--:/+++////++/////. ..-/yhhs-/////////::/::/` ",
" .ooo+/-::::/+///////++++//-/ossyyhhhhs/:///////:::/::::/: ",
" -///:::::::////++///+++/////:/+ooo+/::///////.::://::---+` ",
" /////+//++++/////+////-..//////////::-:::--`.:///:---:::/: ",
" //+++//++++++////+++///::-- .::::-------:: ",
" :/++++///////////++++//////. -:/:----::../- ",
" -/++++//++///+////////////// .::::---:::-.+` ",
" `////////////////////////////:. --::-----...-/ ",
" -///://////////////////////::::-.. :-:-:-..-::.`.+` ",
" :/://///:///::://::://::::::/:::::::-:---::-.-....``/- - ",
" ::::://::://::::::::::::::----------..-:....`.../- -+oo/ ",
" -/:::-:::::---://:-::-::::----::---.-.......`-/. ``",
" s-`::--:::------:////----:---.-:::...-.....`./: ",
" yMNy.`::-.--::..-dmmhhhs-..-.-.......`.....-/:` ",
" oMNNNh. `-::--...:NNNdhhh/.--.`..``.......:/- ",
" :dy+:` .-::-..NNNhhd+``..`...````.-::-` ",
" .-:mNdhh:.......--::::-` ",
" yNh/..------..` ",
" ",
}
-- Keep the logo as a single string to preserve formatting
dashboard.section.header.val = logo
dashboard.section.header.opts = {
position = "center",
hl = "AlphaHeaderRed",
shrink_margin = false,
}
end
return M

View File

@@ -0,0 +1,48 @@
local M = {}
M.setup = function(dashboard)
vim.api.nvim_set_hl(0, "AlphaHeaderGreen", { fg = _G.matugen_palette.color12, bold = true })
local logo = [[
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⡿⠛⢶⣦⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣴⣦⠀⣠⡾⠛⠙⠛⠋⠀⠀⠀⠈⠉⠛⣦⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢾⡇⠙⠛⠋⢀⣤⣀⠀⣀⣤⣤⡀⠀⠀⠀⠈⠻⣦⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⡤⠤⠴⠾⠋⠉⠛⢾⡏⠙⠿⠦⠤⢤⣀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣼⣧⡀⢀⡤⠋⠀⠈⠉⠉⠀⠉⠳⠤⠤⠴⢦⡄⠸⣷⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⡤⢶⣿⠉⢀⣀⡠⠆⠀⠀⠀⠀⠀⠀⠀⢤⣀⣀⠈⢹⣦⢤⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⣀⡿⠿⠾⠀⠀⠀⠀⠀⢴⣦⡀⠀⠀⠀⣠⠟⠀⢹⡇⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⢀⣠⣤⣿⣁⡡⣴⡏⠀⠀⠀⢀⠀⢧⣀⠄⠀⠀⠀⣀⣰⠆⢀⠁⠀⠀⢈⣶⡤⣀⢹⣦⣄⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣸⡟⠀⣴⡄⠀⢀⡄⠀⠀⣦⡈⠃⠀⠀⡾⣳⣄⠀⣼⡇⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⣠⢴⠟⢁⡝⠀⠁⠀⠃⠉⠀⠀⠘⣯⠀⡀⠾⣤⣄⣠⢤⠾⠄⠀⣸⠖⠀⠀⠈⠀⠃⠀⠀⠹⡄⠙⣶⢤⡀⠀⠀⠀⠀⠀⠀⠀⣠⡶⠟⠻⠶⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⡿⠀⠀⠿⠁⢀⡞⠁⠀⠀⣿⠗⠀⠀⠀⣟⢮⣿⣆⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⣠⠾⡇⠈⣀⡞⠀⠀⠀⠀⡀⠀⢀⣠⣄⣇⠀⣳⠴⠃⠀⠀⠀⠣⢴⠉⣰⣇⣀⣀⠀⠀⡄⠀⠀⠀⢹⣄⡘⠈⡷⣦⠀⠀⠀ ⠀⢸⠏⠀⠀⠀⣰⡏⠀⠀⠀⠀⠀⠀⠀⠀⠀⢰⡇⠀⠀⠀⠰⣯⡀⠀⠀⠀⠀⠀⠀⠀⠀⠪⣳⡵⡿⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠀⢠⠞⠉⢻⡄⠀⠀⠈⠙⠀⠀⠀⠀⠙⣶⣏⣤⣤⠟⠉⠁⠀⠀⠀⠀⠀⠀⠀⠉⠙⢦⣱⣌⣷⠊⠀⠀⠀⠀⠈⠁⠀⠀⠀⡝⠉⠻⣄ ⢸⡀⠀⠀⢰⡟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠸⣇⠀⣦⣀⠀⠈⠉⢀⣀⣰⣦⡀⠀⠀⠀⠀⠈⠉⣷⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⣴⠛⢀⡠⢼⡇⠀⠀⢀⡄⠀⢀⣀⡽⠚⠁⠀⠀⠀⢠⡀⢠⣀⠠⣔⢁⡀⠀⣄⠀⡄⠀⠀⠀⠈⠑⠺⣄⡀⠀⠠⡀⠀⠀⢠⡧⠄⠀⠘⢧ ⠘⣷⠀⠀⠘⢷⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢿⡆⠻⠦⣌⣉⣉⣁⡤⠔⠻⡇⠀⠀⠀⣀⣠⣼⠏⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⣿⡶⠋⠀⠀⠈⣠⣈⣩⠗⠒⠋⠀⠀⠀⠀⣀⣠⣆⡼⣷⣞⠛⠻⡉⠉⡟⠒⡛⣶⠧⣀⣀⣀⠀⠀⠀⠀⠈⠓⠺⢏⣉⣠⠋⠀⠀⠀⡾⠛⠉⠙⠛⠲⢦⣄⠀⠙⣦⡀⠀⠀⠀⠀⠀⠀⠀⠀⠈⢿⣄⠀⠀⠲⠇⠀⠀⠀⠀⠀⠀⢀⣴⢏⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⣿⠇⠐⠤⠤⠖⠁⣿⣀⣀⠀⠀⠀⠀⠀⠉⠁⠈⠉⠙⠛⢿⣷⡄⢣⡼⠀⣾⣿⠧⠒⠓⠚⠛⠉⠀⠀⠀⠀⠀⢀⣀⣾⡉⠓⠤⡤⠄⣇⣀⣀⣀⡀⠀⠀⠈⣧⠀⠈⣿⣦⣄⡀⠀⠀⠀⠀⠀⠀⢀⣻⣦⣄⠀⠀⠀⠀⠀⠀⡠⠔⣿⠓⢶⣤⣄⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
⠹⣆⣤⠀⠀⠠⠀⠈⠓⠈⠓⠤⡀⠀⠀⠀⠀⠀⠀⠀⠀⠈⣿⣿⢸⠀⢸⣿⠇⠀⠀⠀⠀⠀⠀⠀⠀⢀⡤⠒⠁⠰⠃⠀⠠⠀⠀⢀⠟⠁⠀⠈⠉⠙⠳⢴⡏⠀⠀⣿⡇⠈⠙⠻⠶⠤⠴⠶⠛⠋⠹⡀⠈⠻⣶⣤⠤⠄⣀⣠⠞⠁⠀⢸⠀⠈⠙⠳⢦⣄⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠉⠓⢲⣄⡈⢀⣠⠀⠀⠀⡸⠶⠂⠀⠀⢀⠀⠀⠤⠞⢻⡇⠀⠀⢘⡟⠑⠤⠄⠀⢀⠀⠀⠐⠲⢿⡀⠀⠀⢤⣀⢈⣀⡴⠖⠋⣧⣤⣤⣤⣤⣀⡀⠀⣷⢀⣼⠃⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠙⢦⣀⠀⠉⠉⠉⠉⠀⠀⢀⣴⠏⠀⠀⠀⠀⠀⠉⠻⣦⣄⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠈⠉⠉⠙⠓⠒⣾⣁⣀⣴⠀⣀⠙⢧⠂⢀⣆⣀⣷⣤⣀⣾⣇⣀⡆⠀⢢⠛⢁⠀⢰⣀⣀⣹⠒⠒⠛⠉⠉⠉⠀⠀⠀⡏⠀⢠⠀⠀⠈⠉⢺⠁⢈⡞⢀⠇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠛⠒⢦⠀⠀⠀⢸⠋⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠙⢷⡄⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠁⠈⠉⠉⠛⠉⠙⠉⠀⠀⣿⡟⣿⣿⠀⠀⠈⠉⠉⠙⠋⠉⠉⠀⠉⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠻⣦⣈⠙⠶⠤⠴⢞⣠⠞⢀⡞⠀⠀⠀⠀⠀⠀⠀⠀⢀⣦⠀⠀⠀⠀⠀⠀⢸⠀⠀⠀⠈⡆⠀⠀⠀⢰⠀⠀⠀⠀⠀⠀⠀⠈⠻⣆⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⡇⢻⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠉⠉⠛⠛⠛⠯⢤⣤⣎⣀⠀⠀⠀⢀⣀⣠⣤⣾⠛⠁⠀⠀⠀⠀⠀⠀⠀⡇⠀⠀⠀⢻⠀⠀⠀⠈⡆⠀⠀⡀⠀⠀⠀⠀⠀⠙⣇
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⣤⣶⣾⣿⣿⠁⠀⢹⡛⣟⡶⢤⣀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠉⠙⠛⠛⠛⠛⠉⠉⠠⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⢇⠀⠀⠀⠀⡇⠀⠀⠀⡇⠀⣰⠏⠀⠀⠀⠀⠀⠀⡿
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣴⠛⢯⣽⡟⢿⣿⠛⠿⠳⠞⠻⣿⠻⣆⢽⠟⣶⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢿⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⠀⠀⠀⠀⢃⠀⠀⠀⢸⣰⠁⠀⠀⠀⠀⠀⠀⣸⠇
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠛⠃⠲⠯⠴⣦⣼⣷⣤⣤⣶⣤⣩⡧⠽⠷⠐⠛⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⡄⠀⠀⠀⠀⠀⠀⠀⠀⢸⡄⠀⠀⠀⢸⠀⠀⢀⣸⡇⠀⠀⠀⠀⠀⠀⣰⠏⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣿⡇⠀⣿⡆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⠛⠢⣄⡀⠀⠀⠀⠀⠀⢸⡇⠀⠀⠀⠸⣤⠴⠛⠁⣿⠤⢤⡀⠀⢀⡼⠏⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣀⣄⡀⢀⣀⣠⡾⡿⢡⢐██████⣀⣄⡀█████⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀███⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⠀⠀⠀⠉⠉⠓⠒⠶⠶⠞⠁⠀⠀⠀⠀⠁⠀⠀⠀⢿⠀⠀⠈⢳⡟⠁⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣤⢴⡏⠁⠀⠝⠉⣡⠟⣰⠃⢸░░██████⠀░░███⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀░░░⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣸⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⡴⢻⠀⠀⣀⡼⠃⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣴⡟⠀⠈⣿⢄⡴⠞⠻⣄⣰⣡⠤⣞⣸░███░███⣶░███⡀⠀█████⠀█████⠀████⠀⠀█████████████⡀⠀⠀⠀⠀⠀⠀⠀⣀⣀⣤⡴⠞⠋⠀⠀⡇⠛⣻⡄⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠀⢀⣴⣶⡿⠃⠉⢺⠁⠙⠒⠀⠀⣠⡉⠀⠉⠚⠉⠉░███░░███░███⢻░░███⠀░░███⠀░░███⠀░░███░░███░░███⠉⠛⠛⠛⠛⠛⠉⠉⠉⠀⠀⠀⠀⠀⠀⡟⠛⠋⠁⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⣠⣾⣿⣇⠁⢈⡦⠀⡍⠋⠁⡀⠸⡋⠀⠀⠀⢘⠏⠉░███⢉░░██████⠈⢁░███⠀⠀░███⠀ ░███⠀⠀░███⠀░███⠀░███⠀⠀⠀⠀⠀⢰⡖⠀⠀⠀⠀⠀⠀⠀⠀⡇⠀⠀⠀⠀⠀⠀⠀⠀
⠀⠀⠀⠀⠀⠀⠉⣁⠀⠉⠉⠉⠙⠛⠛⠒⠚⠳⠤⢼⣤⣠⠤⣮⣠⣤░███⣿⠤░░█████⠉⠉░░███⠀███⠀⠀ ░███⠀⠀░███⠀░███⠀░███⠀⠀⠀⠀⢠⠏⠀⠀⠀⠀⠀⠀⠀⠀⠀⡇⠀⠀⠀⠀⠀⠀⠀⠀
█████ ░░█████ ░░█████ █████ █████░███ █████
░░░░░ ░░░░░ ░░░░░ ░░░░░ ░░░░░ ░░░ ░░░░░
]]
-- Keep the logo as a single string to preserve formatting
dashboard.section.header.val = vim.split(logo, "\n")
dashboard.section.header.opts = {
position = "center",
hl = "AlphaHeaderGreen",
shrink_margin = false,
}
end
return M

View File

@@ -0,0 +1,124 @@
local function getLen(str, start_pos)
local byte = string.byte(str, start_pos)
if not byte then
return nil
end
return (byte < 0x80 and 1) or (byte < 0xE0 and 2) or (byte < 0xF0 and 3) or (byte < 0xF8 and 4) or 1
end
local function colorize(header, header_color_map, colors)
for letter, color in pairs(colors) do
local color_name = "AlphaJemuelKwelKwelWalangTatay" .. letter
vim.api.nvim_set_hl(0, color_name, color)
colors[letter] = color_name
end
local colorized = {}
for i, line in ipairs(header_color_map) do
local colorized_line = {}
local pos = 0
for j = 1, #line do
local start = pos
pos = pos + getLen(header[i], start + 1)
local color_name = colors[line:sub(j, j)]
if color_name then
table.insert(colorized_line, { color_name, start, pos })
end
end
table.insert(colorized, colorized_line)
end
return colorized
end
local M = {}
M.setup = function(dashboard)
local header = {
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
[[ ██████████████████████████████████████████████████████████████████████████████████████████████████████ ]],
}
local color_map = {
[[ WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBWWWWWWWWWWWWWW ]],
[[ RRRRWWWWWWWWWWWWWWWWRRRRRRRRRRRRRRRRWWWWWWWWWWWWWWWWBBPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPBBWWWWWWWWWWWW ]],
[[ RRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRBBPPPPPPHHHHHHHHHHHHHHHHHHHHHHHHHHPPPPPPBBWWWWWWWWWW ]],
[[ RRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRBBPPPPHHHHHHHHHHHHFFHHHHFFHHHHHHHHHHPPPPBBWWWWWWWWWW ]],
[[ OOOORRRRRRRRRRRRRRRROOOOOOOOOOOOOOOORRRRRRRRRRRRRRBBPPHHHHFFHHHHHHHHHHHHHHHHHHHHHHHHHHHHPPBBWWWWWWWWWW ]],
[[ OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOBBPPHHHHHHHHHHHHHHHHHHHHBBBBHHHHFFHHHHPPBBWWBBBBWWWW ]],
[[ OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOBBPPHHHHHHHHHHHHHHHHHHBBMMMMBBHHHHHHHHPPBBBBMMMMBBWW ]],
[[ YYYYOOOOOOOOOOOOOOOOYYYYYYYYYYYYYYYYOOBBBBBBBBOOOOBBPPHHHHHHHHHHHHFFHHHHBBMMMMMMBBHHHHHHPPBBMMMMMMBBWW ]],
[[ YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYBBMMMMBBBBOOBBPPHHHHHHHHHHHHHHHHHHBBMMMMMMMMBBBBBBBBMMMMMMMMBBWW ]],
[[ YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYBBBBMMMMBBBBBBPPHHHHHHFFHHHHHHHHHHBBMMMMMMMMMMMMMMMMMMMMMMMMBBWW ]],
[[ GGGGYYYYYYYYYYYYYYYYGGGGGGGGGGGGGGGGYYYYBBBBMMMMBBBBPPHHHHHHHHHHHHHHFFBBMMMMMMMMMMMMMMMMMMMMMMMMMMMMBB ]],
[[ GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGBBBBMMMMBBPPHHFFHHHHHHHHHHHHBBMMMMMMCCBBMMMMMMMMMMCCBBMMMMBB ]],
[[ GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGBBBBBBBBPPHHHHHHHHHHHHHHHHBBMMMMMMBBBBMMMMMMBBMMBBBBMMMMBB ]],
[[ UUUUGGGGGGGGGGGGGGGGUUUUUUUUUUUUUUUUGGGGGGGGGGGGBBBBPPHHHHHHHHHHFFHHHHBBMMRRRRMMMMMMMMMMMMMMMMMMRRRRBB ]],
[[ UUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUBBPPPPHHFFHHHHHHHHHHBBMMRRRRMMBBMMMMBBMMMMBBMMRRRRBB ]],
[[ UUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUBBPPPPPPHHHHHHHHHHHHHHBBMMMMMMBBBBBBBBBBBBBBMMMMBBWW ]],
[[ VVVVUUUUUUUUUUUUUUUUVVVVVVVVVVVVVVVVUUUUUUUUUUUUBBBBBBPPPPPPPPPPPPPPPPPPPPBBMMMMMMMMMMMMMMMMMMMMBBWWWW ]],
[[ VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVBBMMMMMMBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBWWWWWW ]],
[[ VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVBBMMMMBBBBWWBBMMMMBBWWWWWWWWWWBBMMMMBBWWBBMMMMBBWWWWWWWW ]],
[[ WWWWVVVVVVVVVVVVVVVVWWWWWWWWWWWWWWWWVVVVVVVVVVBBBBBBBBWWWWBBBBBBWWWWWWWWWWWWWWBBBBBBWWWWBBBBWWWWWWWWWW ]],
}
local c = {
color0 = "#191724",
color1 = "#eb6f92",
color2 = "#31748f",
color3 = "#f6c177",
color4 = "#9ccfd8",
color5 = "#c4a7e7",
color6 = "#ebbcba",
color7 = "#908caa",
color8 = "#26233a",
color15 = "#e0def4",
}
local colors = {
["W"] = { fg = c.color0 },
["C"] = { fg = c.color15 },
["B"] = { fg = c.color8 },
["R"] = { fg = c.color1 },
["O"] = { fg = c.color6 },
["Y"] = { fg = c.color3 },
["G"] = { fg = c.color4 },
["U"] = { fg = c.color2 },
["P"] = { fg = c.color3 },
["H"] = { fg = c.color5 },
["F"] = { fg = c.color1 },
["M"] = { fg = c.color7 },
["V"] = { fg = c.color5 },
}
dashboard.section.header.val = header
dashboard.section.header.opts = {
hl = colorize(header, color_map, colors),
position = "center",
}
end
return M

View File

@@ -0,0 +1,31 @@
local M = {}
M.setup = function(dashboard)
vim.api.nvim_set_hl(0, "AlphaHeaderColor", { fg = _G.matugen_palette.color12, bold = true })
dashboard.section.header.val = {
"",
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢠⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⣴⣾⣿⣄⠀⠀⠀⠀⠀⠈⢿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡿⠃⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⣿⣿⣄⠀⠀⠀⠀⠀⠀⢴⣾⣿⣄⠀⠀⠀⠀⠀⠀⠀⠀",
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣤⣶⣿⣿⣿⡿⠛⠉⠀⠀⠀⠀⠀⠀⠈⢿⣿⣿⣟⠛⠛⠛⠛⣻⣿⣿⡿⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣰⣿⣿⣿⣿⣆⠀⠀⠀⠀⠀⠈⢿⣿⣿⣆⠀⠀⠀⠀⠀⠀⠀",
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⣴⣾⣿⣿⣿⠟⠋⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⢻⣿⣿⣦⠀⠀⣼⣿⣿⡟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣼⣿⣿⡟⢻⣿⣿⣆⠀⠀⠀⠀⠀⠀⢻⣿⣿⣧⠀⠀⠀⠀⠀⠀",
"⠀⠀⠀⠀⠀⠀⢀⣤⣶⣿⣿⣿⡿⠛⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠹⣿⣿⣷⣼⣿⣿⡟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣼⣿⣿⡟⠀⠀⠻⣿⣿⣧⡀⠀⠀⠀⠀⠀⢻⣿⣿⣧⠀⠀⠀⠀⠀",
"⠀⠀⠀⣀⣤⣾⣿⣿⣿⠟⠛⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠹⣿⣿⣿⣿⠏⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣾⣿⣿⠏⠀⠀⠀⠀⠙⣿⣿⣷⡀⠀⠀⠀⠀⠀⠹⣿⣿⣷⡀⠀⠀⠀",
"⠀⠀⠀⠙⣿⣿⣿⡍⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢠⣿⣿⣿⣷⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⣿⣿⣷⡄⠀⠀⠀⠀⠀⠙⣿⣿⣷⡀⠀⠀⠀⠀⢠⣾⣿⣿⠃⠀⠀⠀",
"⠀⠀⠀⠀⠈⢿⣿⣿⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢠⣿⣿⣿⢿⣿⣿⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⢿⣿⣿⣄⠀⠀⠀⠀⠀⠘⢿⣿⣿⣄⠀⠀⣠⣿⣿⡿⠁⠀⠀⠀⠀",
"⠀⠀⠀⠀⠀⠈⢿⣿⣿⣆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣰⣿⣿⡿⠁⠈⢿⣿⣿⣆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⢿⣿⣿⣆⠀⠀⠀⠀⠀⠈⢿⣿⣿⣆⣰⣿⣿⡿⠁⠀⠀⠀⠀⠀",
"⠀⠀⠀⠀⠀⠀⠈⢻⣿⣿⣦⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣴⣿⣿⡟⠁⠀⠀⠈⢻⣿⣿⣦⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⢻⣿⣿⣦⠀⠀⠀⠀⠀⠀⢿⣿⣿⣿⣿⡟⠁⠀⠀⠀⠀⠀⠀",
"⠀⠀⠀⠀⠀⠀⠀⠀⢻⣿⣿⡧⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢼⣿⣿⡟⠀⠀⠀⠀⠀⠀⢻⣿⣿⡧⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢻⣿⣿⡧⠀⠀⠀⠀⠀⠀⢻⣿⣿⡟⠀⠀⠀⠀⠀⠀⠀⠀",
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠋⠀⠀⠀⠀⠀⠀⠀⠀⠉⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠉⠀⠀⠀⠀⠀⠀⠀⠀⠹⠏⠀⠀⠀⠀⠀⠀⠀⠀⠀",
"",
"",
}
dashboard.section.header.opts = {
position = "center",
hl = "AlphaHeaderColor",
shrink_margin = false,
}
end
return M

View File

@@ -0,0 +1,99 @@
return {
-- Autocompletion
"saghen/blink.cmp",
event = "VimEnter",
version = "1.*",
dependencies = {
-- Snippet Engine
{
"L3MON4D3/LuaSnip",
version = "2.*",
build = (function()
-- Build Step is needed for regex support in snippets.
-- This step is not supported in many windows environments.
-- Remove the below condition to re-enable on windows.
if vim.fn.has("win32") == 1 or vim.fn.executable("make") == 0 then
return
end
return "make install_jsregexp"
end)(),
dependencies = {
-- `friendly-snippets` contains a variety of premade snippets.
-- See the README about individual language/framework/plugin snippets:
-- https://github.com/rafamadriz/friendly-snippets
-- {
-- 'rafamadriz/friendly-snippets',
-- config = function()
-- require('luasnip.loaders.from_vscode').lazy_load()
-- end,
-- },
},
opts = {},
},
"folke/lazydev.nvim",
},
--- @module 'blink.cmp'
--- @type blink.cmp.Config
opts = {
keymap = {
-- 'default' (recommended) for mappings similar to built-in completions
-- <c-y> to accept ([y]es) the completion.
-- This will auto-import if your LSP supports it.
-- This will expand snippets if the LSP sent a snippet.
-- 'super-tab' for tab to accept
-- 'enter' for enter to accept
-- 'none' for no mappings
--
-- For an understanding of why the 'default' preset is recommended,
-- you will need to read `:help ins-completion`
--
-- No, but seriously. Please read `:help ins-completion`, it is really good!
--
-- All presets have the following mappings:
-- <tab>/<s-tab>: move to right/left of your snippet expansion
-- <c-space>: Open menu or open docs if already open
-- <c-n>/<c-p> or <up>/<down>: Select next/previous item
-- <c-e>: Hide menu
-- <c-k>: Toggle signature help
--
-- See :h blink-cmp-config-keymap for defining your own keymap
preset = "default",
-- For more advanced Luasnip keymaps (e.g. selecting choice nodes, expansion) see:
-- https://github.com/L3MON4D3/LuaSnip?tab=readme-ov-file#keymaps
},
appearance = {
-- 'mono' (default) for 'Nerd Font Mono' or 'normal' for 'Nerd Font'
-- Adjusts spacing to ensure icons are aligned
nerd_font_variant = "mono",
},
completion = {
-- By default, you may press `<c-space>` to show the documentation.
-- Optionally, set `auto_show = true` to show the documentation after a delay.
documentation = { auto_show = false, auto_show_delay_ms = 500 },
},
sources = {
default = { "lsp", "path", "snippets", "lazydev" },
providers = {
lazydev = { module = "lazydev.integrations.blink", score_offset = 100 },
},
},
snippets = { preset = "luasnip" },
-- Blink.cmp includes an optional, recommended rust fuzzy matcher,
-- which automatically downloads a prebuilt binary when enabled.
--
-- By default, we use the Lua implementation instead, but you may enable
-- the rust implementation via `'prefer_rust_with_warning'`
--
-- See :h blink-cmp-config-fuzzy for more information
fuzzy = { implementation = "lua" },
-- Shows a signature help window while you type arguments for a function
signature = { enabled = true },
},
}

View File

@@ -0,0 +1,19 @@
return {
'xvzc/chezmoi.nvim',
dependencies = { 'nvim-lua/plenary.nvim' },
config = function()
require("chezmoi").setup {
-- e.g. ~/.local/share/chezmoi/*
vim.api.nvim_create_autocmd({ "BufRead", "BufNewFile" }, {
pattern = { os.getenv("HOME") .. "/.local/share/chezmoi/*" },
callback = function(ev)
local bufnr = ev.buf
local edit_watch = function()
require("chezmoi.commands.__edit").watch(bufnr)
end
vim.schedule(edit_watch)
end,
})
}
end
}

View File

@@ -0,0 +1,90 @@
return {
{
"rose-pine/neovim",
name = "rose-pine",
enabled = false,
config = function()
vim.opt.laststatus = 2 -- Or 3 for global statusline
vim.opt.statusline = " %f %m %= %l:%c ♥ "
require("rose-pine").setup({
variant = "moon", -- auto, main, moon, or dawn
dark_variant = "moon", -- main, moon, or dawn
dim_inactive_windows = false,
extend_background_behind_borders = true,
enable = {
terminal = true,
legacy_highlights = true, -- Improve compatibility for previous versions of Neovim
migrations = true, -- Handle deprecated options automatically
},
styles = {
bold = true,
italic = true,
transparency = true,
},
groups = {
border = "muted",
link = "iris",
panel = "surface",
error = "love",
hint = "iris",
info = "foam",
note = "pine",
todo = "rose",
warn = "gold",
git_add = "foam",
git_change = "rose",
git_delete = "love",
git_dirty = "rose",
git_ignore = "muted",
git_merge = "iris",
git_rename = "pine",
git_stage = "iris",
git_text = "rose",
git_untracked = "subtle",
h1 = "iris",
h2 = "foam",
h3 = "rose",
h4 = "gold",
h5 = "pine",
h6 = "foam",
},
highlight_groups = {
-- Comment = { fg = "foam" },
-- VertSplit = { fg = "muted", bg = "muted" },
StatusLine = { fg = "love", bg = "love", blend = 10 },
StatusLineNC = { fg = "subtle", bg = "surface" },
-- Transparent Telescope
TelescopeBorder = { fg = "highlight_high", bg = "none" },
TelescopeNormal = { bg = "none" },
TelescopePromptNormal = { bg = "base" },
TelescopeResultsNormal = { fg = "subtle", bg = "none" },
TelescopeSelection = { fg = "text", bg = "base" },
TelescopeSelectionCaret = { fg = "rose", bg = "rose" },
},
before_highlight = function(group, highlight, palette)
-- Disable all undercurls
-- if highlight.undercurl then
-- highlight.undercurl = false
-- end
--
-- Change palette colour
-- if highlight.fg == palette.pine then
-- highlight.fg = palette.foam
-- end
end,
})
vim.cmd("colorscheme rose-pine")
end,
},
}

View File

@@ -0,0 +1,66 @@
return {
"stevearc/conform.nvim",
event = { "BufReadPre", "BufNewFile" },
config = function()
local conform = require("conform")
conform.setup({
formatters_by_ft = {
javascript = { "prettierd" },
typescript = { "prettierd" },
javascriptreact = { "prettierd" },
typescriptreact = { "prettierd" },
svelte = { "prettierd" },
vue = { "prettierd" },
css = { "prettierd" },
html = { "prettierd" },
json = { "prettierd" },
yaml = { "prettierd" },
markdown = { "prettierd" },
graphql = { "prettierd" },
lua = { "stylua" },
python = { "isort", "black" },
astro = { "prettierd" },
nix = { "alejandra" },
},
format_on_save = function(bufnr)
-- Disable with a global or buffer-local variable
if vim.g.disable_autoformat or vim.b[bufnr].disable_autoformat then
return
end
return { timeout_ms = 1000, lsp_format = "fallback" }
end,
})
vim.api.nvim_create_user_command("Format", function(args)
local range = nil
if args.count ~= -1 then
local end_line = vim.api.nvim_buf_get_lines(0, args.line2 - 1, args.line2, true)[1]
range = {
start = { args.line1, 0 },
["end"] = { args.line2, end_line:len() },
}
end
require("conform").format({ async = true, lsp_fallback = true, range = range })
end, { range = true })
vim.api.nvim_create_user_command("FormatDisable", function(args)
if args.bang then
-- FormatDisable! will disable formatting just for this buffer
vim.b.disable_autoformat = true
else
vim.g.disable_autoformat = true
end
end, {
desc = "Disable autoformat-on-save",
bang = true,
})
vim.api.nvim_create_user_command("FormatEnable", function()
vim.b.disable_autoformat = false
vim.g.disable_autoformat = false
end, {
desc = "Re-enable autoformat-on-save",
})
end,
}

View File

@@ -0,0 +1,24 @@
return {
"nvim-treesitter/nvim-treesitter-context",
config = function()
local c = _G.matugen_palette
or {
color0 = "#191724",
color1 = "#eb6f92",
color2 = "#31748f",
color3 = "#f6c177",
color4 = "#9ccfd8",
color5 = "#c4a7e7",
color6 = "#ebbcba",
color7 = "#908caa",
color8 = "#26233a",
color15 = "#e0def4",
}
local color = require("util.color")
vim.api.nvim_set_hl(0, "TreesitterContext", {
bg = color.blend(c.color15, c.color0, 0.8),
ctermbg = "blue",
})
end,
}

View File

@@ -0,0 +1,78 @@
return {
"zbirenbaum/copilot.lua",
cmd = "Copilot",
event = "InsertEnter",
enabled = false,
config = function()
require("copilot").setup({
panel = {
enabled = true,
auto_refresh = false,
keymap = {
jump_prev = "[[",
jump_next = "]]",
accept = "<CR>",
refresh = "gr",
open = "<M-CR>",
},
layout = {
position = "bottom", -- | top | left | right | bottom |
ratio = 0.4,
},
},
suggestion = {
enabled = true,
auto_trigger = false,
hide_during_completion = true,
debounce = 75,
trigger_on_accept = true,
keymap = {
accept = "<C-l>",
accept_word = false,
accept_line = false,
next = "<C-k>",
prev = "<C-j>",
dismiss = "<C-/>",
},
},
nes = {
enabled = false, -- requires copilot-lsp as a dependency
auto_trigger = false,
keymap = {
accept_and_goto = false,
accept = false,
dismiss = false,
},
},
})
end,
-- opts = {
-- suggestion = {
-- enabled = true,
-- auto_trigger = false, -- Don't show suggestions automatically
-- keymap = {
-- accept = "<C-y>",
-- accept_word = "<C-w>",
-- accept_line = "<C-l>",
-- next = "<C-]>", -- Request/cycle suggestions
-- prev = "<C-[>",
-- dismiss = "<C-e>",
-- },
-- },
-- panel = {
-- enabled = true,
-- },
-- },
-- keys = {
-- {
-- "<leader>ct",
-- "<cmd>Copilot toggle<cr>",
-- desc = "Copilot: Toggle auto-suggestions",
-- },
-- {
-- "<leader>cp",
-- "<cmd>Copilot panel<cr>",
-- desc = "Copilot: Open panel",
-- },
-- },
}

View File

@@ -0,0 +1,124 @@
-- Matugen-generated palette for use by other plugins
_G.matugen_palette = {
color0 = "#19120d",
color1 = "#ff7972",
color2 = "#95ff7f",
color3 = "#ffe672",
color4 = "#f2a063",
color5 = "#76380b",
color6 = "#ffb782",
color7 = "#fff6ef",
color8 = "#a59e99",
color9 = "#ffa49f",
color10 = "#b5ffa5",
color11 = "#ffefa5",
color12 = "#ffc194",
color13 = "#ffcca7",
color14 = "#ffdec6",
color15 = "#fffbf8",
}
return {
{
"RRethy/base16-nvim",
priority = 1000,
config = function()
require("base16-colorscheme").setup({
base00 = "#19120d",
base01 = "#19120d",
base02 = "#a59e99",
base03 = "#a59e99",
base04 = "#fff6ef",
base05 = "#fffbf8",
base06 = "#fffbf8",
base07 = "#fffbf8",
base08 = "#ffa49f",
base09 = "#ffa49f",
base0A = "#ffc194",
base0B = "#b5ffa5",
base0C = "#ffdec6",
base0D = "#ffc194",
base0E = "#ffcca7",
base0F = "#ffcca7",
})
vim.api.nvim_set_hl(0, "Visual", {
bg = "#a59e99",
fg = "#fffbf8",
bold = true,
})
vim.api.nvim_set_hl(0, "Statusline", {
bg = "#ffc194",
fg = "#19120d",
})
vim.api.nvim_set_hl(0, "LineNr", { fg = "#a59e99" })
vim.api.nvim_set_hl(0, "CursorLineNr", { fg = "#ffdec6", bold = true })
vim.api.nvim_set_hl(0, "Statement", {
fg = "#ffcca7",
bold = true,
})
vim.api.nvim_set_hl(0, "Keyword", { link = "Statement" })
vim.api.nvim_set_hl(0, "Repeat", { link = "Statement" })
vim.api.nvim_set_hl(0, "Conditional", { link = "Statement" })
vim.api.nvim_set_hl(0, "Function", {
fg = "#ffc194",
bold = true,
})
vim.api.nvim_set_hl(0, "Macro", {
fg = "#ffc194",
italic = true,
})
vim.api.nvim_set_hl(0, "@function.macro", { link = "Macro" })
vim.api.nvim_set_hl(0, "Type", {
fg = "#ffdec6",
bold = true,
italic = true,
})
vim.api.nvim_set_hl(0, "Structure", { link = "Type" })
vim.api.nvim_set_hl(0, "String", {
fg = "#b5ffa5",
italic = true,
})
vim.api.nvim_set_hl(0, "Operator", { fg = "#fff6ef" })
vim.api.nvim_set_hl(0, "Delimiter", { fg = "#fff6ef" })
vim.api.nvim_set_hl(0, "@punctuation.bracket", { link = "Delimiter" })
vim.api.nvim_set_hl(0, "@punctuation.delimiter", { link = "Delimiter" })
vim.api.nvim_set_hl(0, "Comment", {
fg = "#a59e99",
italic = true,
})
-- Transparent background
vim.api.nvim_set_hl(0, "Normal", { bg = "NONE" })
vim.api.nvim_set_hl(0, "NormalNC", { bg = "NONE" })
vim.api.nvim_set_hl(0, "NormalFloat", { bg = "NONE" })
vim.api.nvim_set_hl(0, "SignColumn", { bg = "NONE" })
vim.api.nvim_set_hl(0, "EndOfBuffer", { bg = "NONE" })
-- Emit event for other plugins to react to theme changes
vim.api.nvim_exec_autocmds("User", { pattern = "MatugenReload" })
local current_file_path = vim.fn.stdpath("config") .. "/lua/plugins/dankcolors.lua"
if not _G._matugen_theme_watcher then
local uv = vim.uv or vim.loop
_G._matugen_theme_watcher = uv.new_fs_event()
_G._matugen_theme_watcher:start(
current_file_path,
{},
vim.schedule_wrap(function()
local new_spec = dofile(current_file_path)
if new_spec and new_spec[1] and new_spec[1].config then
new_spec[1].config()
end
end)
)
end
end,
},
}

View File

@@ -0,0 +1,4 @@
return {
"tpope/vim-fugitive",
enabled = true,
}

View File

@@ -0,0 +1,10 @@
return {
"f-person/git-blame.nvim",
-- enabled = false,
config = function()
require("gitblame").setup({ enabled = false })
vim.keymap.set("n", "<leader>gb", ":GitBlameToggle<CR>", {
desc = "Toggle git blame",
})
end,
}

View File

@@ -0,0 +1,51 @@
return {
"lewis6991/gitsigns.nvim",
config = function(bufnr)
require("gitsigns").setup({
on_attach = function(bufnr)
local gitsigns = require("gitsigns")
local function map(mode, l, r, opts)
opts = opts or {}
opts.buffer = bufnr
vim.keymap.set(mode, l, r, opts)
end
-- Navigation
-- map('n', ']c', function()
-- if vim.wo.diff then
-- vim.cmd.normal({ ']c', bang = true })
-- else
-- gitsigns.nav_hunk('next')
-- end
-- end)
-- map('n', '[c', function()
-- if vim.wo.diff then
-- vim.cmd.normal({ '[c', bang = true })
-- else
-- gitsigns.nav_hunk('prev')
-- end
-- end)
-- -- Actions
-- map('n', '<leader>hs', gitsigns.stage_hunk)
-- map('n', '<leader>hr', gitsigns.reset_hunk)
-- map('v', '<leader>hs', function() gitsigns.stage_hunk { vim.fn.line('.'), vim.fn.line('v') } end)
-- map('v', '<leader>hr', function() gitsigns.reset_hunk { vim.fn.line('.'), vim.fn.line('v') } end)
-- map('n', '<leader>hS', gitsigns.stage_buffer)
-- map('n', '<leader>hu', gitsigns.undo_stage_hunk)
-- map('n', '<leader>hR', gitsigns.reset_buffer)
map("n", "<leader>gp", gitsigns.preview_hunk, { desc = "Preview hunk" })
-- map('n', '<leader>hb', function() gitsigns.blame_line { full = true } end)
-- map('n', '<leader>tb', gitsigns.toggle_current_line_blame)
map("n", "<leader>gD", gitsigns.diffthis, { desc = "Diff this" })
-- map('n', '<leader>hD', function() gitsigns.diffthis('~') end)
-- map('n', '<leader>td', gitsigns.toggle_deleted)
-- -- Text object
-- map({ 'o', 'x' }, 'ih', ':<C-U>Gitsigns select_hunk<CR>')
end,
})
end,
}

View File

@@ -0,0 +1,79 @@
return {
"theprimeagen/harpoon",
branch = "harpoon2",
dependencies = { "nvim-lua/plenary.nvim", "nvim-telescope/telescope.nvim" },
config = function()
local harpoon = require("harpoon")
harpoon:setup({
settings = { save_on_toggle = true },
})
vim.keymap.set("n", "<leader>a", function()
harpoon:list():add()
end)
vim.keymap.set("n", "<leader>h", function()
harpoon.ui:toggle_quick_menu(harpoon:list())
end, { desc = "Toggle harpoon quick menu" })
vim.keymap.set("n", "<leader>1", function()
harpoon:list():select(1)
end)
vim.keymap.set("n", "<leader>2", function()
harpoon:list():select(2)
end)
vim.keymap.set("n", "<leader>3", function()
harpoon:list():select(3)
end)
vim.keymap.set("n", "<leader>4", function()
harpoon:list():select(4)
end)
vim.keymap.set("n", "<leader>5", function()
harpoon:list():select(5)
end)
vim.keymap.set("n", "<leader>6", function()
harpoon:list():select(6)
end)
vim.keymap.set("n", "<leader>7", function()
harpoon:list():select(7)
end)
vim.keymap.set("n", "<leader>8", function()
harpoon:list():select(8)
end)
vim.keymap.set("n", "<leader>9", function()
harpoon:list():select(9)
end)
-- Toggle previous & next buffers stored within Harpoon list
vim.keymap.set("n", "<C-S-P>", function()
harpoon:list():prev()
end)
vim.keymap.set("n", "<C-S-N>", function()
harpoon:list():next()
end)
-- basic telescope configuration
local conf = require("telescope.config").values
local function toggle_telescope(harpoon_files)
local file_paths = {}
for _, item in ipairs(harpoon_files.items) do
table.insert(file_paths, item.value)
end
require("telescope.pickers")
.new({}, {
prompt_title = "Harpoon",
finder = require("telescope.finders").new_table({
results = file_paths,
}),
previewer = conf.file_previewer({}),
sorter = conf.generic_sorter({}),
})
:find()
end
vim.keymap.set("n", "<C-e>", function()
toggle_telescope(harpoon:list())
end, { desc = "Open harpoon window" })
end,
}

View File

@@ -0,0 +1,7 @@
return {
"lukas-reineke/indent-blankline.nvim",
enabled = true,
config = function()
require("ibl").setup()
end,
}

View File

@@ -0,0 +1,10 @@
return {
"NMAC427/guess-indent.nvim", -- Detect tabstop and shiftwidth automatically
-- Highlight todo, notes, etc in comments
{
"folke/todo-comments.nvim",
event = "VimEnter",
dependencies = { "nvim-lua/plenary.nvim" },
opts = { signs = false },
},
}

View File

@@ -0,0 +1,22 @@
return {
"HotThoughts/jjui.nvim",
cmd = {
"JJUI",
"JJUICurrentFile",
"JJUIFilter",
"JJUIFilterCurrentFile",
"JJConfig",
},
-- Setting the keybinding here helps lazy-loading
keys = {
{ "<leader>jj", "<cmd>JJUI<cr>", desc = "JJUI" },
{ "<leader>jc", "<cmd>JJUICurrentFile<cr>", desc = "JJUI (current file)" },
{ "<leader>jl", "<cmd>JJUIFilter<cr>", desc = "JJUI Log" },
{ "<leader>jf", "<cmd>JJUIFilterCurrentFile<cr>", desc = "JJUI Log (current file)" },
},
config = function()
require("jjui").setup({
-- configuration options (see below)
})
end,
}

View File

@@ -0,0 +1,12 @@
return {
-- `lazydev` configures Lua LSP for your Neovim config, runtime and plugins
-- used for completion, annotations and signatures of Neovim apis
"folke/lazydev.nvim",
ft = "lua",
opts = {
library = {
-- Load luvit types when the `vim.uv` word is found
{ path = "${3rd}/luv/library", words = { "vim%.uv" } },
},
},
}

View File

@@ -0,0 +1,221 @@
return {
-- Mason for installing LSP servers
{ "mason-org/mason.nvim", opts = {} },
"WhoIsSethDaniel/mason-tool-installer.nvim",
-- Useful status updates for LSP.
{ "j-hui/fidget.nvim", opts = {} },
-- Allows extra capabilities provided by blink.cmp
{
"saghen/blink.cmp",
config = function(_, opts)
require("blink.cmp").setup(opts)
-- Add blink.cmp capabilities to the default LSP client capabilities
vim.lsp.config("*", {
capabilities = require("blink.cmp").get_lsp_capabilities(),
})
end,
},
-- LSP Configuration (using native vim.lsp.config for Neovim 0.11+)
{
"neovim/nvim-lspconfig",
config = function()
-- This function gets run when an LSP attaches to a particular buffer.
vim.api.nvim_create_autocmd("LspAttach", {
group = vim.api.nvim_create_augroup("kickstart-lsp-attach", { clear = true }),
callback = function(event)
local map = function(keys, func, desc, mode)
mode = mode or "n"
vim.keymap.set(mode, keys, func, { buffer = event.buf, desc = "LSP: " .. desc })
end
-- map("gd", require("telescope.builtin").lsp_definitions, "[G]oto [D]efinition")
map("<leader>lr", ":LspRestart<CR>", "Restart LSP")
map("K", function()
vim.lsp.buf.hover({ border = "rounded" })
end, "Show documentation for symbol under cursor")
-- Rename the variable under your cursor.
map("<leader>rn", function()
vim.api.nvim_create_autocmd({ "CmdlineEnter" }, {
callback = function()
local key = vim.api.nvim_replace_termcodes("<C-f>", true, false, true)
vim.api.nvim_feedkeys(key, "c", false)
vim.api.nvim_feedkeys("0", "n", false)
return true
end,
})
vim.lsp.buf.rename()
end, "[R]e[n]ame")
-- Execute a code action
map("<leader>ca", vim.lsp.buf.code_action, "[C]ode [A]ction", { "n", "x" })
-- Find references for the word under your cursor.
map("gtref", require("telescope.builtin").lsp_references, "[G]oto [R]eferences")
-- Jump to the implementation of the word under your cursor.
-- map("gI", require("telescope.builtin").lsp_implementations, "[G]oto [I]mplementation")
-- Goto Declaration (e.g., in C this would take you to the header)
map("gD", vim.lsp.buf.declaration, "[G]oto [D]eclaration")
-- Fuzzy find all the symbols in your current document.
-- map("<leader>ds", require("telescope.builtin").lsp_document_symbols, "[D]ocument [S]ymbols")
-- Fuzzy find all the symbols in your current workspace.
-- map("gW", require("telescope.builtin").lsp_dynamic_workspace_symbols, "Open Workspace Symbols")
-- Jump to the type of the word under your cursor.
-- map("gt", require("telescope.builtin").lsp_type_definitions, "[G]oto [T]ype Definition")
map("<leader>vd", function()
vim.diagnostic.open_float()
end, "[V]iew [D]iagnostics")
map("[d", function()
vim.diagnostic.goto_prev()
end, "Prev Diagnostic")
map("]d", function()
vim.diagnostic.goto_next()
end, "Next Diagnostic")
local client = vim.lsp.get_client_by_id(event.data.client_id)
-- Highlight references of the word under cursor
if
client
and client:supports_method(vim.lsp.protocol.Methods.textDocument_documentHighlight, event.buf)
then
local highlight_augroup =
vim.api.nvim_create_augroup("kickstart-lsp-highlight", { clear = false })
vim.api.nvim_create_autocmd({ "CursorHold", "CursorHoldI" }, {
buffer = event.buf,
group = highlight_augroup,
callback = vim.lsp.buf.document_highlight,
})
vim.api.nvim_create_autocmd({ "CursorMoved", "CursorMovedI" }, {
buffer = event.buf,
group = highlight_augroup,
callback = vim.lsp.buf.clear_references,
})
vim.api.nvim_create_autocmd("LspDetach", {
group = vim.api.nvim_create_augroup("kickstart-lsp-detach", { clear = true }),
callback = function(event2)
vim.lsp.buf.clear_references()
vim.api.nvim_clear_autocmds({ group = "kickstart-lsp-highlight", buffer = event2.buf })
end,
})
end
-- Toggle inlay hints keymap
if
client and client:supports_method(vim.lsp.protocol.Methods.textDocument_inlayHint, event.buf)
then
map("<leader>th", function()
vim.lsp.inlay_hint.enable(not vim.lsp.inlay_hint.is_enabled({ bufnr = event.buf }))
end, "[T]oggle Inlay [H]ints")
end
-- Svelte-specific: notify on TS/JS file changes
-- https://github.com/sveltejs/language-tools/issues/2008#issuecomment-2351976230
if client and client.name == "svelte" then
vim.api.nvim_create_autocmd("BufWritePost", {
pattern = { "*.js", "*.ts" },
group = vim.api.nvim_create_augroup("svelte-on-did-change-ts-or-js-file", { clear = true }),
callback = function(args)
client:notify("$/onDidChangeTsOrJsFile", {
uri = args.match,
})
end,
})
end
end,
})
-- Extra keymaps
vim.keymap.set("n", "<leader>oi", function()
vim.lsp.buf.code_action({
context = {
only = { "source.organizeImports" },
diagnostics = {},
},
apply = true,
})
end, { desc = "Organize Imports" })
-- Diagnostic Config
vim.diagnostic.config({
severity_sort = true,
float = { border = "rounded", source = "if_many" },
underline = { severity = vim.diagnostic.severity.ERROR },
signs = vim.g.have_nerd_font and {
text = {
[vim.diagnostic.severity.ERROR] = "󰅚 ",
[vim.diagnostic.severity.WARN] = "󰀪 ",
[vim.diagnostic.severity.INFO] = "󰋽 ",
[vim.diagnostic.severity.HINT] = "󰌶 ",
},
} or {},
virtual_text = {
source = "if_many",
spacing = 2,
format = function(diagnostic)
local diagnostic_message = {
[vim.diagnostic.severity.ERROR] = diagnostic.message,
[vim.diagnostic.severity.WARN] = diagnostic.message,
[vim.diagnostic.severity.INFO] = diagnostic.message,
[vim.diagnostic.severity.HINT] = diagnostic.message,
}
return diagnostic_message[diagnostic.severity]
end,
},
})
-- Install tools via mason-tool-installer
require("mason-tool-installer").setup({
ensure_installed = {
"stylua",
"lua-language-server",
"pyright",
"css-lsp",
"eslint-lsp",
"vtsls",
"tailwindcss-language-server",
"biome",
},
})
-- Load custom LSP configs from nvim/lsp/*.lua to override nvim-lspconfig defaults
local lsp_path = vim.fn.stdpath("config") .. "/lsp"
for _, file in ipairs(vim.fn.readdir(lsp_path)) do
if file:match("%.lua$") then
local name = file:gsub("%.lua$", "")
local config = dofile(lsp_path .. "/" .. file)
if type(config) == "table" then
vim.lsp.config(name, config)
end
end
end
-- Enable LSP servers (configs are in nvim/lsp/*.lua)
vim.lsp.enable({
"lua_ls",
"pyright",
"cssls",
"eslint",
"gdscript",
-- "vtsls",
"tsgo",
"svelte",
"tailwindcss",
"biome",
})
end,
},
}

View File

@@ -0,0 +1,136 @@
local fallback_palette = {
color0 = "#191724",
color1 = "#eb6f92",
color2 = "#31748f",
color3 = "#f6c177",
color4 = "#9ccfd8",
color5 = "#c4a7e7",
color6 = "#ebbcba",
color7 = "#908caa",
color8 = "#26233a",
color9 = "#eb6f92",
color10 = "#31748f",
color11 = "#f6c177",
color12 = "#9ccfd8",
color13 = "#c4a7e7",
color14 = "#ebbcba",
color15 = "#e0def4",
}
local function build_theme()
local c = _G.matugen_palette or fallback_palette
local bg_base = "NONE"
local dark = "#000000"
local color = require("util.color")
return {
normal = {
a = { bg = c.color4, fg = dark, gui = "bold" },
b = { bg = color.darken(c.color4, 50), fg = c.color15 },
c = { bg = c.color0, fg = c.color15 },
},
insert = {
a = { bg = c.color2, fg = dark, gui = "bold" },
b = { bg = color.darken(c.color2, 50), fg = c.color15 },
},
visual = {
a = { bg = c.color5, fg = dark, gui = "bold" },
b = { bg = color.darken(c.color5, 50), fg = c.color15 },
},
replace = {
a = { bg = c.color3, fg = dark, gui = "bold" },
b = { bg = color.darken(c.color3, 50), fg = c.color15 },
},
command = {
a = { bg = c.color1, fg = dark, gui = "bold" },
b = { bg = color.darken(c.color1, 50), fg = c.color15 },
},
inactive = {
a = { bg = bg_base, fg = c.color7, gui = "bold" },
b = { bg = bg_base, fg = c.color7 },
},
}
end
local function setup_macro_refresh(lualine)
vim.api.nvim_create_autocmd("RecordingEnter", {
callback = function()
lualine.refresh({ place = { "statusline" } })
end,
})
vim.api.nvim_create_autocmd("RecordingLeave", {
callback = function()
local timer = vim.loop.new_timer()
timer:start(
50,
0,
vim.schedule_wrap(function()
lualine.refresh({ place = { "statusline" } })
end)
)
end,
})
end
local function macro_recording_status()
return {
"macro-recording",
fmt = function()
local register = vim.fn.reg_recording()
return register == "" and "" or "RECORDING @" .. register
end,
}
end
local function heart()
return [[♥ ]]
end
return {
"nvim-lualine/lualine.nvim",
event = "VeryLazy",
dependencies = { "nvim-tree/nvim-web-devicons" },
init = function()
vim.opt.laststatus = 0
end,
config = function()
vim.opt.laststatus = 3
local lualine = require("lualine")
setup_macro_refresh(lualine)
local function do_setup()
lualine.setup({
options = {
theme = build_theme(),
component_separators = "",
section_separators = { left = "", right = "" },
disabled_filetypes = { "alpha" },
},
sections = {
lualine_a = {
{ "mode", separator = { left = "", right = "" }, right_padding = 2 },
macro_recording_status(),
},
lualine_b = { "diff", "diagnostics" },
lualine_c = { { "filename", path = 1 } },
lualine_x = { "filetype" },
lualine_y = { "progress" },
lualine_z = {
{ "location", separator = { left = "" }, left_padding = 2 },
{ heart, separator = { right = "" } },
},
},
extensions = { "nvim-tree", "fzf" },
})
end
do_setup()
-- Re-setup lualine when matugen reloads theme
vim.api.nvim_create_autocmd("User", {
pattern = "MatugenReload",
callback = do_setup,
})
end,
}

View File

@@ -0,0 +1,5 @@
return {
"chentoast/marks.nvim",
event = "VeryLazy",
opts = {},
}

View File

@@ -0,0 +1,3 @@
return {
'andymass/vim-matchup',
}

View File

@@ -0,0 +1,6 @@
return {
"davidmh/mdx.nvim",
config = true,
enabled = false,
dependencies = { "nvim-treesitter/nvim-treesitter" },
}

View File

@@ -0,0 +1,450 @@
return {
"echasnovski/mini.nvim",
version = false,
config = function()
require("mini.ai").setup({
-- Table with textobject id as fields, textobject specification as values.
-- Also use this to disable builtin textobjects. See |MiniAi.config|.
custom_textobjects = nil,
-- Module mappings. Use `''` (empty string) to disable one.
mappings = {
-- Main textobject prefixes
around = "a",
inside = "i",
-- Next/last variants
around_next = "an",
inside_next = "in",
around_last = "al",
inside_last = "il",
-- Move cursor to corresponding edge of `a` textobject
goto_left = "g[",
goto_right = "g]",
},
-- Number of lines within which textobject is searched
n_lines = 1000,
-- How to search for object (first inside current line, then inside
-- neighborhood). One of 'cover', 'cover_or_next', 'cover_or_prev',
-- 'cover_or_nearest', 'next', 'previous', 'nearest'.
search_method = "cover_or_next",
-- Whether to disable showing non-error feedback
-- This also affects (purely informational) helper messages shown after
-- idle time if user input is required.
silent = false,
})
require("mini.surround").setup(
-- No need to copy this inside `setup()`. Will be used automatically.
{
-- Add custom surroundings to be used on top of builtin ones. For more
-- information with examples, see `:h MiniSurround.config`.
custom_surroundings = nil,
-- Duration (in ms) of highlight when calling `MiniSurround.highlight()`
highlight_duration = 500,
-- Module mappings. Use `''` (empty string) to disable one.
mappings = {
add = "sa", -- Add surrounding in Normal and Visual modes
delete = "sd", -- Delete surrounding
find = "sf", -- Find surrounding (to the right)
find_left = "sF", -- Find surrounding (to the left)
highlight = "sh", -- Highlight surrounding
replace = "sr", -- Replace surrounding
update_n_lines = "sn", -- Update `n_lines`
suffix_last = "l", -- Suffix to search with "prev" method
suffix_next = "n", -- Suffix to search with "next" method
},
-- Number of lines within which surrounding is searched
n_lines = 1000,
-- Whether to respect selection type:
-- - Place surroundings on separate lines in linewise mode.
-- - Place surroundings on each line in blockwise mode.
respect_selection_type = false,
-- How to search for surrounding (first inside current line, then inside
-- neighborhood). One of 'cover', 'cover_or_next', 'cover_or_prev',
-- 'cover_or_nearest', 'next', 'prev', 'nearest'. For more details,
-- see `:h MiniSurround.config`.
search_method = "cover",
-- Whether to disable showing non-error feedback
-- This also affects (purely informational) helper messages shown after
-- idle time if user input is required.
silent = false,
}
)
-- Create a custom command to wrap double quotes with {[]} at cursor position
vim.api.nvim_create_user_command("WrapQuotesWithBrackets", function()
-- Get cursor position (1-indexed for line, 0-indexed for column)
local cursor = vim.api.nvim_win_get_cursor(0)
local line_num = cursor[1]
local col_num = cursor[2] + 1 -- Convert to 1-indexed for string operations
-- Get the current line
local line = vim.api.nvim_get_current_line()
-- Find all quote pairs in the line
local quote_start, quote_end = nil, nil
local pos = 1
while pos <= #line do
local start_pos = line:find('"', pos)
if not start_pos then
break
end
local end_pos = line:find('"', start_pos + 1)
if not end_pos then
break
end
-- Check if cursor is within or on this quote pair
if col_num >= start_pos and col_num <= end_pos then
quote_start = start_pos
quote_end = end_pos
break
end
pos = end_pos + 1
end
-- If we found quotes surrounding the cursor, wrap them
if quote_start and quote_end then
local before = line:sub(1, quote_start - 1)
local quoted_content = line:sub(quote_start, quote_end)
local after = line:sub(quote_end + 1)
local new_line = before .. "{[" .. quoted_content .. "]}" .. after
-- Replace the line
vim.api.nvim_set_current_line(new_line)
-- Adjust cursor position (move it after the inserted characters)
local new_col = col_num + 2 -- Account for the added '{[' characters
vim.api.nvim_win_set_cursor(0, { line_num, new_col - 1 }) -- Convert back to 0-indexed
else
print("No quotes found at cursor position")
end
end, {
desc = "Wrap double quotes at cursor with {[]}",
})
-- require("mini.pairs").setup({
-- -- In which modes mappings from this `config` should be created
-- modes = { insert = true, command = false, terminal = false },
--
-- -- Global mappings. Each right hand side should be a pair information, a
-- -- table with at least these fields (see more in |MiniPairs.map|):
-- -- - <action> - one of 'open', 'close', 'closeopen'.
-- -- - <pair> - two character string for pair to be used.
-- -- By default pair is not inserted after `\`, quotes are not recognized by
-- -- `<CR>`, `'` does not insert pair after a letter.
-- -- Only parts of tables can be tweaked (others will use these defaults).
-- mappings = {
-- ["("] = { action = "open", pair = "()", neigh_pattern = "[^\\]." },
-- ["["] = { action = "open", pair = "[]", neigh_pattern = "[^\\]." },
-- ["{"] = { action = "open", pair = "{}", neigh_pattern = "[^\\]." },
-- ["<"] = { action = "open", pair = "<>", neigh_pattern = "[^\\]." },
--
-- [")"] = { action = "close", pair = "()", neigh_pattern = "[^\\]." },
-- ["]"] = { action = "close", pair = "[]", neigh_pattern = "[^\\]." },
-- ["}"] = { action = "close", pair = "{}", neigh_pattern = "[^\\]." },
-- [">"] = { action = "close", pair = "<>", neigh_pattern = "[^\\]." },
--
-- ['"'] = { action = "closeopen", pair = '""', neigh_pattern = "[^\\].", register = { cr = false } },
-- ["'"] = { action = "closeopen", pair = "''", neigh_pattern = "[^%a\\].", register = { cr = false } },
-- ["`"] = { action = "closeopen", pair = "``", neigh_pattern = "[^\\].", register = { cr = false } },
-- },
-- })
require("mini.comment").setup({
-- Options which control module behavior
options = {
-- Function to compute custom 'commentstring' (optional)
custom_commentstring = nil,
-- Whether to ignore blank lines when commenting
ignore_blank_line = false,
-- Whether to recognize as comment only lines without indent
start_of_line = false,
-- Whether to force single space inner padding for comment parts
pad_comment_parts = true,
},
-- Module mappings. Use `''` (empty string) to disable one.
mappings = {
-- Toggle comment (like `gcip` - comment inner paragraph) for both
-- Normal and Visual modes
comment = "gc",
-- Toggle comment on current line
comment_line = "gcc",
-- Toggle comment on visual selection
comment_visual = "gc",
-- Define 'comment' textobject (like `dgc` - delete whole comment block)
-- Works also in Visual mode if mapping differs from `comment_visual`
textobject = "gc",
},
-- Hook functions to be executed at certain stage of commenting
hooks = {
-- Before successful commenting. Does nothing by default.
pre = function() end,
-- After successful commenting. Does nothing by default.
post = function() end,
},
})
local miniclue = require("mini.clue")
miniclue.setup({
triggers = {
-- Leader triggers
{ mode = "n", keys = "<Leader>" },
{ mode = "x", keys = "<Leader>" },
-- Built-in completion
{ mode = "i", keys = "<C-x>" },
-- `g` key
{ mode = "n", keys = "g" },
{ mode = "x", keys = "g" },
-- Marks
{ mode = "n", keys = "'" },
{ mode = "n", keys = "`" },
{ mode = "x", keys = "'" },
{ mode = "x", keys = "`" },
-- Registers
{ mode = "n", keys = '"' },
{ mode = "x", keys = '"' },
{ mode = "i", keys = "<C-r>" },
{ mode = "c", keys = "<C-r>" },
-- Window commands
{ mode = "n", keys = "<C-w>" },
-- `z` key
{ mode = "n", keys = "z" },
{ mode = "x", keys = "z" },
},
clues = {
-- Enhance this by adding descriptions for <Leader> mapping groups
miniclue.gen_clues.builtin_completion(),
miniclue.gen_clues.g(),
miniclue.gen_clues.marks(),
miniclue.gen_clues.registers(),
miniclue.gen_clues.windows(),
miniclue.gen_clues.z(),
},
})
-- local starter = require("mini.starter")
-- starter.setup({
-- evaluate_single = true,
-- header = "hi",
-- items = {
-- starter.sections.builtin_actions(),
-- starter.sections.telescope(),
-- starter.sections.sessions(5, true),
-- },
-- })
-- local sessions = require("mini.sessions")
-- sessions.setup({
-- autoread = true,
-- })
require("mini.move").setup({
-- Module mappings. Use `''` (empty string) to disable one.
mappings = {
-- Move visual selection in Visual mode. Defaults are Alt (Meta) + hjkl.
left = "<C-S-Left>",
right = "<C-S-Right>",
down = "<C-S-Down>",
up = "<C-S-Up>",
-- Move current line in Normal mode
line_left = "<C-S-Left>",
line_right = "<C-S-Right>",
line_down = "<C-S-Down>",
line_up = "<C-S-Up>",
},
-- Options which control moving behavior
options = {
-- Automatically reindent selection during linewise vertical move
reindent_linewise = true,
},
})
require("mini.icons").setup({
extension = {
["spec.ts"] = { glyph = "", hl = "MiniIconsAzure" },
["test.ts"] = { glyph = "", hl = "MiniIconsAzure" },
["spec.svelte.ts"] = { glyph = "", hl = "MiniIconsAzure" },
["test.svelte.ts"] = { glyph = "", hl = "MiniIconsAzure" },
["svelte.ts"] = { glyph = "", hl = "MiniIconsAzure" },
},
})
require("mini.files").setup({
-- Customization of shown content
content = {
-- Predicate for which file system entries to show
filter = nil,
-- What prefix to show to the left of file system entry
prefix = nil,
-- In which order to show file system entries
sort = nil,
},
-- Module mappings created only inside explorer.
-- Use `''` (empty string) to not create one.
mappings = {
close = "q",
go_in = "<Right>",
go_in_plus = "L",
go_out = "<Left>",
go_out_plus = "H",
mark_goto = "'",
mark_set = "m",
reset = "<BS>",
reveal_cwd = "@",
show_help = "g?",
synchronize = "=",
trim_left = "<",
trim_right = ">",
},
-- General options
options = {
-- Whether to delete permanently or move into module-specific trash
permanent_delete = true,
-- Whether to use for editing directories
use_as_default_explorer = false,
},
-- Customization of explorer windows
windows = {
-- Maximum number of windows to show side by side
max_number = math.huge,
-- Whether to show preview of file/directory under cursor
preview = false,
-- Width of focused window
width_focus = 50,
-- Width of other windows
width_nofocus = 15,
},
})
vim.api.nvim_create_autocmd("User", {
pattern = "MiniFilesActionRename",
callback = function(event)
Snacks.rename.on_rename_file(event.data.from, event.data.to)
end,
})
-- local MiniPick = require("mini.pick")
-- MiniPick.setup({
-- -- Delays (in ms; should be at least 1)
-- delay = {
-- -- Delay between forcing asynchronous behavior
-- async = 10,
--
-- -- Delay between computation start and visual feedback about it
-- busy = 50,
-- },
--
-- -- Keys for performing actions. See `:h MiniPick-actions`.
-- mappings = {
-- caret_left = "<Left>",
-- caret_right = "<Right>",
--
-- choose = "<CR>",
-- choose_in_split = "<C-s>",
-- choose_in_tabpage = "<C-t>",
-- choose_in_vsplit = "<C-v>",
-- choose_marked = "<M-CR>",
--
-- delete_char = "<BS>",
-- delete_char_right = "<Del>",
-- delete_left = "<C-u>",
-- delete_word = "<C-w>",
--
-- mark = "<C-x>",
-- mark_all = "<C-a>",
--
-- move_down = "<C-n>",
-- move_start = "<C-g>",
-- move_up = "<C-p>",
--
-- paste = "<C-r>",
--
-- refine = "<C-Space>",
-- refine_marked = "<M-Space>",
--
-- scroll_down = "<C-f>",
-- scroll_left = "<C-h>",
-- scroll_right = "<C-l>",
-- scroll_up = "<C-b>",
--
-- stop = "<Esc>",
--
-- toggle_info = "<S-Tab>",
-- toggle_preview = "<Tab>",
-- },
--
-- -- General options
-- options = {
-- -- Whether to show content from bottom to top
-- content_from_bottom = false,
--
-- -- Whether to cache matches (more speed and memory on repeated prompts)
-- use_cache = false,
-- },
--
-- -- Source definition. See `:h MiniPick-source`.
-- source = {
-- items = nil,
-- name = nil,
-- cwd = nil,
--
-- match = nil,
-- show = nil,
-- preview = nil,
--
-- choose = nil,
-- choose_marked = nil,
-- },
--
-- -- Window related options
-- window = {
-- -- Float window config (table or callable returning it)
-- config = nil,
--
-- -- String to use as caret in prompt
-- prompt_caret = "▏",
--
-- -- String to use as prefix in prompt
-- prompt_prefix = "> ",
-- },
-- })
--
-- vim.keymap.set("n", "<leader>pf", function()
-- MiniPick.builtin.files({ tool = "git" })
-- end, { desc = "Find [F]iles" })
end,
}

View File

@@ -0,0 +1,61 @@
return {
{
"milanglacier/minuet-ai.nvim",
priority = 1000,
config = function()
require("minuet").setup({
provider = "openai_compatible",
request_timeout = 2.5,
throttle = 1500, -- Increase to reduce costs and avoid rate limits
debounce = 600, -- Increase to reduce costs and avoid rate limits
provider_options = {
openai_compatible = {
api_key = "OPENROUTER_API_KEY",
end_point = "https://openrouter.ai/api/v1/chat/completions",
model = "moonshotai/kimi-k2",
name = "Openrouter",
optional = {
max_tokens = 56,
top_p = 0.9,
provider = {
-- Prioritize throughput for faster completion
sort = "throughput",
},
},
},
},
})
end,
},
{ "nvim-lua/plenary.nvim" },
-- optional, if you are using virtual-text frontend, blink is not required.
{
"Saghen/blink.cmp",
config = function()
require("blink-cmp").setup({
keymap = {
-- Manually invoke minuet completion.
["<A-y>"] = require("minuet").make_blink_map(),
},
sources = {
-- Enable minuet for autocomplete
default = { "lsp", "path", "buffer", "snippets", "minuet" },
-- For manual completion only, remove 'minuet' from default
providers = {
minuet = {
name = "minuet",
module = "minuet.blink",
async = true,
-- Should match minuet.config.request_timeout * 1000,
-- since minuet.config.request_timeout is in seconds
timeout_ms = 3000,
score_offset = 50, -- Gives minuet higher priority among suggestions
},
},
},
-- Recommended to avoid unnecessary request
completion = { trigger = { prefetch_on_insert = false } },
})
end,
},
}

View File

@@ -0,0 +1,85 @@
return {
"jake-stewart/multicursor.nvim",
branch = "1.0",
enabled = true,
config = function()
local mc = require("multicursor-nvim")
mc.setup()
-- Add cursors above/below the main cursor.
vim.keymap.set({ "n", "v" }, "<C-up>", function()
mc.addCursor("k")
end)
vim.keymap.set({ "n", "v" }, "<C-down>", function()
mc.addCursor("j")
end)
-- Add a cursor and jump to the next word under cursor.
vim.keymap.set({ "n", "v" }, "<c-n>", function()
mc.addCursor("*")
end)
-- Jump to the next word under cursor but do not add a cursor.
vim.keymap.set({ "n", "v" }, "<c-s>", function()
mc.skipCursor("*")
end)
-- Rotate the main cursor.
vim.keymap.set({ "n", "v" }, "<C-left>", mc.nextCursor)
vim.keymap.set({ "n", "v" }, "<C-right>", mc.prevCursor)
-- Delete the main cursor.
vim.keymap.set({ "n", "v" }, "<leader>x", mc.deleteCursor)
-- Add and remove cursors with control + left click.
vim.keymap.set("n", "<c-leftmouse>", mc.handleMouse)
vim.keymap.set({ "n", "v" }, "<c-q>", function()
if mc.cursorsEnabled() then
-- Stop other cursors from moving.
-- This allows you to reposition the main cursor.
mc.disableCursors()
else
mc.addCursor()
end
end)
vim.keymap.set("n", "<esc>", function()
if not mc.cursorsEnabled() then
mc.enableCursors()
elseif mc.hasCursors() then
mc.clearCursors()
else
-- Default <esc> handler.
end
end)
-- Align cursor columns.
-- vim.keymap.set("n", "<leader>a", mc.alignCursors)
-- Split visual selections by regex.
vim.keymap.set("v", "S", mc.splitCursors)
-- Append/insert for each line of visual selections.
vim.keymap.set("v", "I", mc.insertVisual)
vim.keymap.set("v", "A", mc.appendVisual)
-- match new cursors within visual selections by regex.
vim.keymap.set("v", "M", mc.matchCursors)
-- Rotate visual selection contents.
vim.keymap.set("v", "<leader>t", function()
mc.transposeCursors(1)
end)
vim.keymap.set("v", "<leader>T", function()
mc.transposeCursors(-1)
end)
-- Customize how cursors look.
vim.api.nvim_set_hl(0, "MultiCursorCursor", { link = "Cursor" })
vim.api.nvim_set_hl(0, "MultiCursorVisual", { link = "Visual" })
vim.api.nvim_set_hl(0, "MultiCursorDisabledCursor", { link = "Visual" })
vim.api.nvim_set_hl(0, "MultiCursorDisabledVisual", { link = "Visual" })
end,
}

View File

@@ -0,0 +1,14 @@
return {
"shortcuts/no-neck-pain.nvim",
opts = {
width = 140,
autocmds = {
enableOnVimEnter = true,
},
integrations = {
dashboard = {
enabled = true,
},
},
},
}

View File

@@ -0,0 +1,210 @@
return {
"stevearc/oil.nvim",
---@module 'oil'
---@type oil.SetupOpts
opts = {
-- Oil will take over directory buffers (e.g. `vim .` or `:e src/`)
-- Set to false if you want some other plugin (e.g. netrw) to open when you edit directories.
default_file_explorer = true,
-- Id is automatically added at the beginning, and name at the end
-- See :help oil-columns
columns = {
"icon",
-- "permissions",
-- "size",
-- "mtime",
},
-- Buffer-local options to use for oil buffers
buf_options = {
buflisted = false,
bufhidden = "hide",
},
-- Window-local options to use for oil buffers
win_options = {
wrap = false,
signcolumn = "no",
cursorcolumn = false,
foldcolumn = "0",
spell = false,
list = false,
conceallevel = 3,
concealcursor = "nvic",
},
-- Send deleted files to the trash instead of permanently deleting them (:help oil-trash)
delete_to_trash = false,
-- Skip the confirmation popup for simple operations (:help oil.skip_confirm_for_simple_edits)
skip_confirm_for_simple_edits = false,
-- Selecting a new/moved/renamed file or directory will prompt you to save changes first
-- (:help prompt_save_on_select_new_entry)
prompt_save_on_select_new_entry = true,
-- Oil will automatically delete hidden buffers after this delay
-- You can set the delay to false to disable cleanup entirely
-- Note that the cleanup process only starts when none of the oil buffers are currently displayed
cleanup_delay_ms = 2000,
lsp_file_methods = {
-- Enable or disable LSP file operations
enabled = true,
-- Time to wait for LSP file operations to complete before skipping
timeout_ms = 1000,
-- Set to true to autosave buffers that are updated with LSP willRenameFiles
-- Set to "unmodified" to only save unmodified buffers
autosave_changes = false,
},
-- Constrain the cursor to the editable parts of the oil buffer
-- Set to `false` to disable, or "name" to keep it on the file names
constrain_cursor = "editable",
-- Set to true to watch the filesystem for changes and reload oil
watch_for_changes = true,
-- Keymaps in oil buffer. Can be any value that `vim.keymap.set` accepts OR a table of keymap
-- options with a `callback` (e.g. { callback = function() ... end, desc = "", mode = "n" })
-- Additionally, if it is a string that matches "actions.<name>",
-- it will use the mapping at require("oil.actions").<name>
-- Set to `false` to remove a keymap
-- See :help oil-actions for a list of all available actions
keymaps = {
["g?"] = "actions.show_help",
["<CR>"] = "actions.select",
["<C-s>"] = { "actions.select", opts = { vertical = true }, desc = "Open the entry in a vertical split" },
["<C-h>"] = {
"actions.select",
opts = { horizontal = true },
desc = "Open the entry in a horizontal split",
},
["<C-t>"] = { "actions.select", opts = { tab = true }, desc = "Open the entry in new tab" },
["<C-p>"] = "actions.preview",
["<C-c>"] = "actions.close",
["<C-l>"] = "actions.refresh",
["-"] = "actions.parent",
["_"] = "actions.open_cwd",
["`"] = "actions.cd",
["~"] = { "actions.cd", opts = { scope = "tab" }, desc = ":tcd to the current oil directory", mode = "n" },
["gs"] = "actions.change_sort",
["gx"] = "actions.open_external",
["g."] = "actions.toggle_hidden",
["g\\"] = "actions.toggle_trash",
["<C-q>"] = "actions.send_to_qflist",
},
-- Set to false to disable all of the above keymaps
use_default_keymaps = true,
view_options = {
-- Show files and directories that start with "."
show_hidden = true,
-- This function defines what is considered a "hidden" file
is_hidden_file = function(name, bufnr)
local m = name:match("^%.")
return m ~= nil
end,
-- This function defines what will never be shown, even when `show_hidden` is set
is_always_hidden = function(name, bufnr)
return false
end,
-- Sort file names with numbers in a more intuitive order for humans.
-- Can be "fast", true, or false. "fast" will turn it off for large directories.
natural_order = "fast",
-- Sort file and directory names case insensitive
case_insensitive = false,
sort = {
-- sort order can be "asc" or "desc"
-- see :help oil-columns to see which columns are sortable
{ "type", "asc" },
{ "name", "asc" },
},
},
-- Extra arguments to pass to SCP when moving/copying files over SSH
extra_scp_args = {},
-- EXPERIMENTAL support for performing file operations with git
git = {
-- Return true to automatically git add/mv/rm files
add = function(path)
return false
end,
mv = function(src_path, dest_path)
return false
end,
rm = function(path)
return false
end,
},
-- Configuration for the floating window in oil.open_float
float = {
-- Padding around the floating window
padding = 2,
max_width = 0,
max_height = 0,
border = "rounded",
win_options = {
winblend = 0,
},
-- optionally override the oil buffers window title with custom function: fun(winid: integer): string
get_win_title = nil,
-- preview_split: Split direction: "auto", "left", "right", "above", "below".
preview_split = "auto",
-- This is the config that will be passed to nvim_open_win.
-- Change values here to customize the layout
override = function(conf)
return conf
end,
},
-- Configuration for the file preview window
preview_win = {
-- Whether the preview window is automatically updated when the cursor is moved
update_on_cursor_moved = true,
-- How to open the preview window "load"|"scratch"|"fast_scratch"
preview_method = "fast_scratch",
-- A function that returns true to disable preview on a file e.g. to avoid lag
disable_preview = function(filename)
return false
end,
-- Window-local options to use for preview window buffers
win_options = {},
},
-- Configuration for the floating action confirmation window
confirmation = {
-- Width dimensions can be integers or a float between 0 and 1 (e.g. 0.4 for 40%)
-- min_width and max_width can be a single value or a list of mixed integer/float types.
-- max_width = {100, 0.8} means "the lesser of 100 columns or 80% of total"
max_width = 0.9,
-- min_width = {40, 0.4} means "the greater of 40 columns or 40% of total"
min_width = { 40, 0.4 },
-- optionally define an integer/float for the exact width of the preview window
width = nil,
-- Height dimensions can be integers or a float between 0 and 1 (e.g. 0.4 for 40%)
-- min_height and max_height can be a single value or a list of mixed integer/float types.
-- max_height = {80, 0.9} means "the lesser of 80 columns or 90% of total"
max_height = 0.9,
-- min_height = {5, 0.1} means "the greater of 5 columns or 10% of total"
min_height = { 5, 0.1 },
-- optionally define an integer/float for the exact height of the preview window
height = nil,
border = "rounded",
win_options = {
winblend = 0,
},
},
-- Configuration for the floating progress window
progress = {
max_width = 0.9,
min_width = { 40, 0.4 },
width = nil,
max_height = { 10, 0.9 },
min_height = { 5, 0.1 },
height = nil,
border = "rounded",
minimized_border = "none",
win_options = {
winblend = 0,
},
},
-- Configuration for the floating SSH window
ssh = {
border = "rounded",
},
-- Configuration for the floating keymaps help window
keymaps_help = {
border = "rounded",
},
},
-- Optional dependencies
dependencies = { { "echasnovski/mini.icons", opts = {} } },
-- dependencies = { "nvim-tree/nvim-web-devicons" }, -- use if prefer nvim-web-devicons
}

View File

@@ -0,0 +1,7 @@
return {
"Ripple-TS/ripple",
config = function(plugin)
vim.opt.rtp:append(plugin.dir .. "/packages/nvim-plugin")
require("ripple").setup(plugin)
end,
}

View File

@@ -0,0 +1,540 @@
return {
"folke/snacks.nvim",
priority = 1000,
lazy = false,
opts = {
-- your configuration comes here
-- or leave it empty to use the default settings
-- refer to the configuration section below
bigfile = { enabled = true },
notifier = { enabled = true },
quickfile = { enabled = true },
statuscolumn = { enabled = true },
words = { enabled = true },
picker = {},
explorer = {},
},
keys = {
{
"<leader>.",
function()
Snacks.scratch()
end,
desc = "Toggle Scratch Buffer",
},
{
"<leader>S",
function()
Snacks.scratch.select()
end,
desc = "Select Scratch Buffer",
},
{
"<leader>n",
function()
Snacks.notifier.show_history()
end,
desc = "Notification History",
},
{
"<leader>gB",
function()
Snacks.gitbrowse()
end,
desc = "Git Browse",
},
-- {
-- "<leader>gb",
-- function()
-- Snacks.git.blame_line()
-- end,
-- desc = "Git Blame Line",
-- },
{
"<leader>gf",
function()
Snacks.lazygit.log_file()
end,
desc = "Lazygit Current File History",
},
{
"<leader>lg",
function()
Snacks.lazygit()
end,
desc = "Lazygit",
},
{
"<leader>gl",
function()
Snacks.lazygit.log()
end,
desc = "Lazygit Log (cwd)",
},
{
"<leader>dn",
function()
Snacks.notifier.hide()
end,
desc = "Dismiss All Notifications",
},
{
"<c-/>",
function()
Snacks.terminal()
end,
desc = "Toggle Terminal",
},
{
"<c-_>",
function()
Snacks.terminal()
end,
desc = "which_key_ignore",
},
{
"]]",
function()
Snacks.words.jump(vim.v.count1)
end,
desc = "Next Reference",
mode = { "n", "t" },
},
{
"[[",
function()
Snacks.words.jump(-vim.v.count1)
end,
desc = "Prev Reference",
mode = { "n", "t" },
},
{
"<leader>N",
desc = "Neovim News",
function()
Snacks.win({
file = vim.api.nvim_get_runtime_file("doc/news.txt", false)[1],
width = 0.6,
height = 0.6,
wo = {
spell = false,
wrap = false,
signcolumn = "yes",
statuscolumn = " ",
conceallevel = 3,
},
})
end,
},
-- Snacks Picker
-- Top Pickers & Explorer
{
"<leader><space>",
function()
Snacks.picker.smart()
end,
desc = "Smart Find Files",
},
{
"<leader>,",
function()
Snacks.picker.buffers()
end,
desc = "Buffers",
},
{
"<leader>/",
function()
Snacks.picker.grep()
end,
desc = "Grep",
},
{
"<leader>:",
function()
Snacks.picker.command_history()
end,
desc = "Command History",
},
{
"<leader>n",
function()
Snacks.picker.notifications()
end,
desc = "Notification History",
},
{
"<leader>e",
function()
Snacks.explorer()
end,
desc = "File Explorer",
},
-- find
{
"<leader>fb",
function()
Snacks.picker.buffers()
end,
desc = "Buffers",
},
{
"<leader>fc",
function()
Snacks.picker.files({ cwd = vim.fn.stdpath("config") })
end,
desc = "Find Config File",
},
{
"<leader>ff",
function()
Snacks.picker.files()
end,
desc = "Find Files",
},
{
"<leader>fg",
function()
Snacks.picker.git_files()
end,
desc = "Find Git Files",
},
{
"<leader>fp",
function()
Snacks.picker.projects()
end,
desc = "Projects",
},
{
"<leader>fr",
function()
Snacks.picker.recent()
end,
desc = "Recent",
},
-- git
{
"<leader>gb",
function()
Snacks.picker.git_branches()
end,
desc = "Git Branches",
},
{
"<leader>gl",
function()
Snacks.picker.git_log()
end,
desc = "Git Log",
},
{
"<leader>gL",
function()
Snacks.picker.git_log_line()
end,
desc = "Git Log Line",
},
{
"<leader>gs",
function()
Snacks.picker.git_status()
end,
desc = "Git Status",
},
{
"<leader>gS",
function()
Snacks.picker.git_stash()
end,
desc = "Git Stash",
},
{
"<leader>gd",
function()
Snacks.picker.git_diff()
end,
desc = "Git Diff (Hunks)",
},
{
"<leader>gf",
function()
Snacks.picker.git_log_file()
end,
desc = "Git Log File",
},
-- gh
{
"<leader>gi",
function()
Snacks.picker.gh_issue()
end,
desc = "GitHub Issues (open)",
},
{
"<leader>gI",
function()
Snacks.picker.gh_issue({ state = "all" })
end,
desc = "GitHub Issues (all)",
},
{
"<leader>gp",
function()
Snacks.picker.gh_pr()
end,
desc = "GitHub Pull Requests (open)",
},
{
"<leader>gP",
function()
Snacks.picker.gh_pr({ state = "all" })
end,
desc = "GitHub Pull Requests (all)",
},
-- Grep
{
"<leader>sb",
function()
Snacks.picker.lines()
end,
desc = "Buffer Lines",
},
{
"<leader>sB",
function()
Snacks.picker.grep_buffers()
end,
desc = "Grep Open Buffers",
},
{
"<leader>sg",
function()
Snacks.picker.grep()
end,
desc = "Grep",
},
{
"<leader>sw",
function()
Snacks.picker.grep_word()
end,
desc = "Visual selection or word",
mode = { "n", "x" },
},
-- search
{
'<leader>s"',
function()
Snacks.picker.registers()
end,
desc = "Registers",
},
{
"<leader>s/",
function()
Snacks.picker.search_history()
end,
desc = "Search History",
},
{
"<leader>sa",
function()
Snacks.picker.autocmds()
end,
desc = "Autocmds",
},
{
"<leader>sb",
function()
Snacks.picker.lines()
end,
desc = "Buffer Lines",
},
{
"<leader>sc",
function()
Snacks.picker.command_history()
end,
desc = "Command History",
},
{
"<leader>sC",
function()
Snacks.picker.commands()
end,
desc = "Commands",
},
{
"<leader>sd",
function()
Snacks.picker.diagnostics()
end,
desc = "Diagnostics",
},
{
"<leader>sD",
function()
Snacks.picker.diagnostics_buffer()
end,
desc = "Buffer Diagnostics",
},
{
"<leader>sh",
function()
Snacks.picker.help()
end,
desc = "Help Pages",
},
{
"<leader>sH",
function()
Snacks.picker.highlights()
end,
desc = "Highlights",
},
{
"<leader>si",
function()
Snacks.picker.icons()
end,
desc = "Icons",
},
{
"<leader>sj",
function()
Snacks.picker.jumps()
end,
desc = "Jumps",
},
{
"<leader>sk",
function()
Snacks.picker.keymaps()
end,
desc = "Keymaps",
},
{
"<leader>sl",
function()
Snacks.picker.loclist()
end,
desc = "Location List",
},
{
"<leader>sm",
function()
Snacks.picker.marks()
end,
desc = "Marks",
},
{
"<leader>sM",
function()
Snacks.picker.man()
end,
desc = "Man Pages",
},
{
"<leader>sp",
function()
Snacks.picker.lazy()
end,
desc = "Search for Plugin Spec",
},
{
"<leader>sq",
function()
Snacks.picker.qflist()
end,
desc = "Quickfix List",
},
{
"<leader>sr",
function()
Snacks.picker.resume()
end,
desc = "Resume",
},
{
"<leader>su",
function()
Snacks.picker.undo()
end,
desc = "Undo History",
},
{
"<leader>uC",
function()
Snacks.picker.colorschemes()
end,
desc = "Colorschemes",
},
-- LSP
{
"gd",
function()
Snacks.picker.lsp_definitions()
end,
desc = "Goto Definition",
},
{
"gD",
function()
Snacks.picker.lsp_declarations()
end,
desc = "Goto Declaration",
},
{
"gref",
function()
Snacks.picker.lsp_references()
end,
nowait = true,
desc = "References",
},
{
"gI",
function()
Snacks.picker.lsp_implementations()
end,
desc = "Goto Implementation",
},
{
"gy",
function()
Snacks.picker.lsp_type_definitions()
end,
desc = "Goto T[y]pe Definition",
},
{
"gai",
function()
Snacks.picker.lsp_incoming_calls()
end,
desc = "C[a]lls Incoming",
},
{
"gao",
function()
Snacks.picker.lsp_outgoing_calls()
end,
desc = "C[a]lls Outgoing",
},
{
"<leader>ss",
function()
Snacks.picker.lsp_symbols()
end,
desc = "LSP Symbols",
},
{
"<leader>sS",
function()
Snacks.picker.lsp_workspace_symbols()
end,
desc = "LSP Workspace Symbols",
},
},
}

View File

@@ -0,0 +1,3 @@
return {
"sQVe/sort.nvim",
}

View File

@@ -0,0 +1,3 @@
return {
'lambdalisue/vim-suda'
}

View File

@@ -0,0 +1,7 @@
return {
"supermaven-inc/supermaven-nvim",
enabled = false,
config = function()
require("supermaven-nvim").setup({})
end,
}

View File

@@ -0,0 +1,8 @@
return {
"nvim-svelte/nvim-svelte-check",
config = function()
require("svelte-check").setup({
command = "pnpm run check", -- Default command for pnpm
})
end,
}

View File

@@ -0,0 +1,124 @@
return { -- Fuzzy Finder (files, lsp, etc)
"nvim-telescope/telescope.nvim",
event = "VimEnter",
dependencies = {
"nvim-lua/plenary.nvim",
{ -- If encountering errors, see telescope-fzf-native README for installation instructions
"nvim-telescope/telescope-fzf-native.nvim",
-- `build` is used to run some command when the plugin is installed/updated.
-- This is only run then, not every time Neovim starts up.
build = "make",
-- `cond` is a condition used to determine whether this plugin should be
-- installed and loaded.
cond = function()
return vim.fn.executable("make") == 1
end,
},
{ "nvim-telescope/telescope-ui-select.nvim" },
-- Useful for getting pretty icons, but requires a Nerd Font.
{ "nvim-tree/nvim-web-devicons", enabled = vim.g.have_nerd_font },
},
config = function()
-- Telescope is a fuzzy finder that comes with a lot of different things that
-- it can fuzzy find! It's more than just a "file finder", it can search
-- many different aspects of Neovim, your workspace, LSP, and more!
--
-- The easiest way to use Telescope, is to start by doing something like:
-- :Telescope help_tags
--
-- After running this command, a window will open up and you're able to
-- type in the prompt window. You'll see a list of `help_tags` options and
-- a corresponding preview of the help.
--
-- Two important keymaps to use while in Telescope are:
-- - Insert mode: <c-/>
-- - Normal mode: ?
--
-- This opens a window that shows you all of the keymaps for the current
-- Telescope picker. This is really useful to discover what Telescope can
-- do as well as how to actually do it!
-- [[ Configure Telescope ]]
-- See `:help telescope` and `:help telescope.setup()`
require("telescope").setup({
-- You can put your default mappings / updates / etc. in here
-- All the info you're looking for is in `:help telescope.setup()`
--
-- defaults = {
-- mappings = {
-- i = { ['<c-enter>'] = 'to_fuzzy_refine' },
-- },
-- },
defaults = {
file_ignore_patterns = { "node_modules", ".git" },
},
pickers = {
find_files = {
hidden = true,
find_command = {
"fd",
"--type",
"f",
"--strip-cwd-prefix",
"--follow",
"--hidden",
"--exclude",
".git",
},
},
},
extensions = {
["ui-select"] = {
require("telescope.themes").get_dropdown(),
},
fzf = {
fuzzy = true,
override_generic_sorter = true,
override_file_sorter = true,
case_mode = "smart_case",
},
},
})
-- Enable Telescope extensions if they are installed
pcall(require("telescope").load_extension, "fzf")
pcall(require("telescope").load_extension, "ui-select")
-- See `:help telescope.builtin`
local builtin = require("telescope.builtin")
-- vim.keymap.set("n", "<leader>t", ":Telescope<CR>", {})
-- vim.keymap.set("n", "<leader>pf", function()
-- builtin.find_files({
-- file_ignore_patterns = { "node%_modules/.*", ".git/.*" },
-- })
-- end, { desc = "Find [F]iles" })
-- vim.keymap.set("n", "<leader>ph", builtin.help_tags, { desc = "Search [H]elp" })
-- vim.keymap.set("n", "<leader>pk", builtin.keymaps, { desc = "Search [K]eymaps" })
-- vim.keymap.set("n", "<leader>ps", builtin.builtin, { desc = "Search [S]elect Telescope" })
-- vim.keymap.set("n", "<leader>ps", function()
-- -- builtin.live_grep()
-- builtin.grep_string({ search = vim.fn.input("Grep > ") })
-- end, { desc = "[P]roject [S]earch" })
-- vim.keymap.set("n", "<leader>pw", builtin.grep_string, { desc = "[S]earch current [W]ord" })
-- vim.keymap.set("n", "<leader>pg", builtin.live_grep, { desc = "Search by [G]rep" })
-- vim.keymap.set("n", "<leader>pd", builtin.diagnostics, { desc = "Search [D]iagnostics" })
-- vim.keymap.set("n", "<leader>pr", builtin.resume, { desc = "Search [R]esume" })
-- vim.keymap.set("n", "<leader>p.", builtin.oldfiles, { desc = 'Search Recent Files ("." for repeat)' })
-- vim.keymap.set("n", "<leader><leader>", builtin.buffers, { desc = "[ ] Find existing buffers" })
-- Slightly advanced example of overriding default behavior and theme
-- vim.keymap.set("n", "<leader>/", function()
-- -- You can pass additional configuration to Telescope to change the theme, layout, etc.
-- builtin.current_buffer_fuzzy_find(require("telescope.themes").get_dropdown({
-- winblend = 10,
-- previewer = false,
-- }))
-- end, { desc = "[/] Fuzzily search in current buffer" })
--
-- vim.keymap.set("n", "<leader>ch", builtin.command_history, { desc = "[C]ommand [H]istory" })
-- vim.keymap.set("n", "<leader>cc", builtin.commands, { desc = "[C]ommands" })
end,
}

View File

@@ -0,0 +1,39 @@
return {
-- Highlight, edit, and navigate code
"nvim-treesitter/nvim-treesitter",
lazy = false,
build = ":TSUpdate",
config = function()
require("nvim-treesitter").setup({
install_dir = vim.fn.stdpath("data") .. "/site",
})
-- Install parsers (async, no-op if already installed)
require("nvim-treesitter").install({
"vimdoc",
"javascript",
"typescript",
"tsx",
"ripple",
"c",
"lua",
"rust",
"jsdoc",
"bash",
"svelte",
"astro",
"vue",
"css",
"scss",
"gdscript",
})
-- Enable treesitter highlighting and indentation
vim.api.nvim_create_autocmd("FileType", {
callback = function()
pcall(vim.treesitter.start)
vim.bo.indentexpr = "v:lua.require'nvim-treesitter'.indentexpr()"
end,
})
end,
}

View File

@@ -0,0 +1,37 @@
return {
"folke/trouble.nvim",
opts = {}, -- for default options, refer to the configuration section for custom setup.
cmd = "Trouble",
keys = {
{
"<leader>xx",
"<cmd>Trouble diagnostics toggle<cr>",
desc = "Diagnostics (Trouble)",
},
{
"<leader>xX",
"<cmd>Trouble diagnostics toggle filter.buf=0<cr>",
desc = "Buffer Diagnostics (Trouble)",
},
{
"<leader>cs",
"<cmd>Trouble symbols toggle focus=false<cr>",
desc = "Symbols (Trouble)",
},
{
"<leader>cl",
"<cmd>Trouble lsp toggle focus=false win.position=right<cr>",
desc = "LSP Definitions / references / ... (Trouble)",
},
{
"<leader>xL",
"<cmd>Trouble loclist toggle<cr>",
desc = "Location List (Trouble)",
},
{
"<leader>xq",
"<cmd>Trouble qflist toggle<cr>",
desc = "Quickfix List (Trouble)",
},
},
}

View File

@@ -0,0 +1,56 @@
return {
"pmizio/typescript-tools.nvim",
enabled = false,
dependencies = { "nvim-lua/plenary.nvim", "neovim/nvim-lspconfig" },
opts = {},
config = function()
require("typescript-tools").setup({
-- on_attach = function() ... end,
-- handlers = { ... },
-- ...
settings = {
-- spawn additional tsserver instance to calculate diagnostics on it
separate_diagnostic_server = true,
-- "change"|"insert_leave" determine when the client asks the server about diagnostic
publish_diagnostic_on = "insert_leave",
-- array of strings("fix_all"|"add_missing_imports"|"remove_unused"|
-- "remove_unused_imports"|"organize_imports") -- or string "all"
-- to include all supported code actions
-- specify commands exposed as code_actions
expose_as_code_action = {},
-- string|nil - specify a custom path to `tsserver.js` file, if this is nil or file under path
-- not exists then standard path resolution strategy is applied
tsserver_path = nil,
-- specify a list of plugins to load by tsserver, e.g., for support `styled-components`
-- (see 💅 `styled-components` support section)
tsserver_plugins = {},
-- this value is passed to: https://nodejs.org/api/cli.html#--max-old-space-sizesize-in-megabytes
-- memory limit in megabytes or "auto"(basically no limit)
tsserver_max_memory = "auto",
-- described below
tsserver_format_options = {},
tsserver_file_preferences = {},
-- locale of all tsserver messages, supported locales you can find here:
-- https://github.com/microsoft/TypeScript/blob/3c221fc086be52b19801f6e8d82596d04607ede6/src/compiler/utilitiesPublic.ts#L620
tsserver_locale = "en",
-- mirror of VSCode's `typescript.suggest.completeFunctionCalls`
complete_function_calls = false,
include_completions_with_insert_text = true,
-- CodeLens
-- WARNING: Experimental feature also in VSCode, because it might hit performance of server.
-- possible values: ("off"|"all"|"implementations_only"|"references_only")
code_lens = "off",
-- by default code lenses are displayed on all referencable values and for some of you it can
-- be too much this option reduce count of them by removing member references from lenses
disable_member_code_lens = true,
-- JSXCloseTag
-- WARNING: it is disabled by default (maybe you configuration or distro already uses nvim-ts-autotag,
-- that maybe have a conflict if enable this feature. )
jsx_close_tag = {
enable = false,
filetypes = { "javascriptreact", "typescriptreact" },
},
},
})
end,
}

View File

@@ -0,0 +1,7 @@
return {
"mbbill/undotree",
config = function()
vim.keymap.set("n", "<leader>u", vim.cmd.UndotreeToggle)
end
}

View File

@@ -0,0 +1,53 @@
return {
"folke/which-key.nvim",
enabled = false,
event = "VimEnter", -- Sets the loading event to 'VimEnter'
opts = {
-- delay between pressing a key and opening which-key (milliseconds)
-- this setting is independent of vim.o.timeoutlen
delay = 0,
icons = {
-- set icon mappings to true if you have a Nerd Font
mappings = vim.g.have_nerd_font,
-- If you are using a Nerd Font: set icons.keys to an empty table which will use the
-- default which-key.nvim defined Nerd Font icons, otherwise define a string table
keys = vim.g.have_nerd_font and {} or {
Up = "<Up> ",
Down = "<Down> ",
Left = "<Left> ",
Right = "<Right> ",
C = "<C-…> ",
M = "<M-…> ",
D = "<D-…> ",
S = "<S-…> ",
CR = "<CR> ",
Esc = "<Esc> ",
ScrollWheelDown = "<ScrollWheelDown> ",
ScrollWheelUp = "<ScrollWheelUp> ",
NL = "<NL> ",
BS = "<BS> ",
Space = "<Space> ",
Tab = "<Tab> ",
F1 = "<F1>",
F2 = "<F2>",
F3 = "<F3>",
F4 = "<F4>",
F5 = "<F5>",
F6 = "<F6>",
F7 = "<F7>",
F8 = "<F8>",
F9 = "<F9>",
F10 = "<F10>",
F11 = "<F11>",
F12 = "<F12>",
},
},
-- Document existing key chains
spec = {
{ "<leader>s", group = "[S]earch" },
{ "<leader>t", group = "[T]oggle" },
{ "<leader>h", group = "Git [H]unk", mode = { "n", "v" } },
},
},
}

108
nvim/files/lua/remap.lua Normal file
View File

@@ -0,0 +1,108 @@
local map = function(keys, func, desc, mode)
mode = mode or "n"
vim.keymap.set(mode, keys, func, { desc = desc })
end
-- Project view (mini.files)
map("<leader>pv", function()
MiniFiles.open(vim.api.nvim_buf_get_name(0))
end, "Open file explorer")
-- Move lines around
map("J", ":m '>+1<CR>gv=gv", "Move line down", "v")
map("<S-Down>", ":m '>+1<CR>gv=gv", "Move line down", "v")
map("K", ":m '<-2<CR>gv=gv", "Move line up", "v")
map("<S-Up>", ":m '<-2<CR>gv=gv", "Move line up", "v")
-- Keep cursor in center throughout operations
map("J", "mzJ`z", "Join lines and keep cursor")
map("<C-d>", "<C-d>zz", "Scroll down and center")
map("<C-u>", "<C-u>zz", "Scroll up and center")
map("n", "nzzzv", "Next search result and center")
map("N", "Nzzzv", "Previous search result and center")
-- Clipboard operations
map("<leader>p", '"_dP', "Paste without updating register", "x")
map("<leader>pc", '"+p', "Paste from system clipboard")
map("<leader>y", '"+y', "Yank to system clipboard")
map("<leader>y", '"+y', "Yank to system clipboard", "v")
map("<leader>Y", '"+Y', "Yank line to system clipboard")
map("<C-v>", '<Esc>"+pa', "Paste from system clipboard", "i")
-- Delete without register
map("<leader>d", '"_d', "Delete without updating register")
map("<leader>d", '"_d', "Delete without updating register", "v")
-- Disable Q
map("Q", "<nop>", "Disable Q")
-- Formatting
map("<leader>fo", function()
vim.cmd("Format")
vim.notify("Formatted file", vim.log.levels.INFO, { title = "Formatting" })
end, "Format file")
map("<leader>fe", function()
vim.cmd("FormatEnable")
vim.notify("Enabled auto-format", vim.log.levels.INFO, { title = "Formatting" })
end, "Enable auto-format")
map("<leader>fd", function()
vim.cmd("FormatDisable")
vim.notify("Disabled auto-format", vim.log.levels.INFO, { title = "Formatting" })
end, "Disable auto-format")
-- Organize Imports
map("<leader>oi", function()
vim.lsp.buf.code_action({
context = {
only = { "source.organizeImports" },
diagnostics = vim.diagnostic.get(0),
},
apply = true,
})
end, "Organize Imports")
-- map("<leader>l", function()
-- local lint = require("lint")
-- lint.try_lint()
-- end, "Lint file")
map("<leader>esf", function()
vim.cmd("EslintFixAll")
end, "Fix ESLint issues")
-- Window management
map("<leader>ws", "<C-w>s", "Split window horizontally")
map("<leader>wv", "<C-w>v", "Split window vertically")
map("<leader>wh", "<C-w>h", "Move to left window")
map("<leader>w<Left>", "<C-w>h", "Move to left window")
map("<leader>wj", "<C-w>j", "Move to bottom window")
map("<leader>w<Down>", "<C-w>j", "Move to bottom window")
map("<leader>wk", "<C-w>k", "Move to top window")
map("<leader>w<Up>", "<C-w>k", "Move to top window")
map("<leader>wl", "<C-w>l", "Move to right window")
map("<leader>w<Right>", "<C-w>l", "Move to right window")
map("<leader>wq", "<C-w>q", "Close window")
map("<leader>wf", "<C-w>f <C-w>L", "Open file under cursor in new window")
-- Buffer operations
map("<leader>rf", ":e<CR>", "Refresh buffer")
map("<leader>sf", ":w<CR>", "Save file")
-- Terminal
map("<Esc>", [[<C-\><C-n>]], "Exit terminal insert mode", "t")
-- Close quickfix menu after selecting choice
vim.api.nvim_create_autocmd("FileType", {
pattern = { "qf" },
command = [[nnoremap <buffer> <CR> <CR>:cclose<CR>]],
})
vim.api.nvim_create_user_command("Cppath", function()
local path = vim.fn.expand("%:p")
vim.fn.setreg("+", path)
vim.notify('Copied "' .. path .. '" to the clipboard!')
end, {})
-- Kickstart keymaps
vim.keymap.set("n", "<leader>q", vim.diagnostic.setloclist, { desc = "Open diagnostic [Q]uickfix list" })

97
nvim/files/lua/set.lua Normal file
View File

@@ -0,0 +1,97 @@
vim.g.mapleader = " "
vim.g.maplocalleader = " "
vim.opt.nu = true
vim.opt.relativenumber = true
vim.opt.tabstop = 2
vim.opt.softtabstop = 2
vim.opt.shiftwidth = 2
vim.opt.expandtab = false
vim.opt.smartindent = true
vim.opt.swapfile = false
vim.opt.backup = false
vim.opt.undodir = os.getenv("HOME") .. "/.vim/undodir"
vim.opt.undofile = true
vim.opt.hlsearch = false
vim.opt.incsearch = true
vim.opt.termguicolors = true
vim.opt.scrolloff = 8
vim.opt.updatetime = 50
vim.opt.ignorecase = true
vim.opt.smartcase = true
-- vim.opt.colorcolumn = "80"
vim.opt.inccommand = "nosplit"
vim.opt.cursorline = true
vim.g.have_nerd_font = true
-- Enable mouse mode, can be useful for resizing splits for example!
vim.o.mouse = "a"
-- Don't show the mode, since it's already in the status line
vim.o.showmode = false
-- Enable break indent
vim.o.breakindent = true
-- Save undo history
vim.o.undofile = true
-- Keep signcolumn on by default
vim.o.signcolumn = "yes"
-- Decrease update time
-- vim.o.updatetime = 250
-- Decrease mapped sequence wait time
vim.o.timeoutlen = 300
-- Configure how new splits should be opened
vim.o.splitright = true
vim.o.splitbelow = true
-- Sets how neovim will display certain whitespace characters in the editor.
-- See `:help 'list'`
-- and `:help 'listchars'`
--
-- Notice listchars is set using `vim.opt` instead of `vim.o`.
-- It is very similar to `vim.o` but offers an interface for conveniently interacting with tables.
-- See `:help lua-options`
-- and `:help lua-options-guide`
vim.o.list = true
vim.opt.listchars = { tab = "» ", trail = "·", nbsp = "" }
-- Preview substitutions live, as you type!
vim.o.inccommand = "split"
-- Show which line your cursor is on
vim.o.cursorline = true
-- Minimal number of screen lines to keep above and below the cursor.
vim.o.scrolloff = 10
-- if performing an operation that would fail due to unsaved changes in the buffer (like `:q`),
-- instead raise a dialog asking if you wish to save the current file(s)
-- See `:help 'confirm'`
vim.o.confirm = true
-- vim.o.winborder = "rounded"
-- Highlight text on yank
vim.api.nvim_create_autocmd("TextYankPost", {
callback = function()
vim.highlight.on_yank({ timeout = 100 })
end,
})

View File

@@ -0,0 +1,72 @@
local M = {}
-- Convert hex color to RGB values
local function hex_to_rgb(hex)
hex = hex:gsub("#", "")
return tonumber("0x" .. hex:sub(1, 2)), tonumber("0x" .. hex:sub(3, 4)), tonumber("0x" .. hex:sub(5, 6))
end
-- Convert RGB values to hex color
local function rgb_to_hex(r, g, b)
return string.format("#%02X%02X%02X", r, g, b)
end
-- Clamp a value between min and max
local function clamp(value, min, max)
return math.min(math.max(value, min), max)
end
-- Darken a color by a percentage (0-100)
function M.darken(hex, percent)
if not hex or not percent then
return hex
end
local r, g, b = hex_to_rgb(hex)
local factor = (100 - percent) / 100
r = clamp(math.floor(r * factor), 0, 255)
g = clamp(math.floor(g * factor), 0, 255)
b = clamp(math.floor(b * factor), 0, 255)
return rgb_to_hex(r, g, b)
end
-- Lighten a color by a percentage (0-100)
function M.lighten(hex, percent)
if not hex or not percent then
return hex
end
local r, g, b = hex_to_rgb(hex)
local factor = 1 + (percent / 100)
r = clamp(math.floor(r * factor), 0, 255)
g = clamp(math.floor(g * factor), 0, 255)
b = clamp(math.floor(b * factor), 0, 255)
return rgb_to_hex(r, g, b)
end
-- Blend two colors with a given weight (0-1)
function M.blend(color1, color2, weight)
weight = weight or 0.5
local r1, g1, b1 = hex_to_rgb(color1)
local r2, g2, b2 = hex_to_rgb(color2)
local r = math.floor(r1 * (1 - weight) + r2 * weight)
local g = math.floor(g1 * (1 - weight) + g2 * weight)
local b = math.floor(b1 * (1 - weight) + b2 * weight)
return rgb_to_hex(r, g, b)
end
-- Check if a color is light or dark
function M.is_light(hex)
local r, g, b = hex_to_rgb(hex)
-- Using relative luminance formula
local luminance = (0.299 * r + 0.587 * g + 0.114 * b) / 255
return luminance > 0.5
end
return M

6
opencode/config.lua Normal file
View File

@@ -0,0 +1,6 @@
return {
target = {
linux = "~/.config/opencode",
default = "~/.config/opencode",
},
}

3
opencode/files/AGENTS.md Normal file
View File

@@ -0,0 +1,3 @@
## Git
- When asked to commit, always check the users previous commits, copy the style

View File

@@ -0,0 +1,4 @@
{
"$schema": "https://opencode.ai/config.json",
"autoupdate": true
}

6
paru/config.lua Normal file
View File

@@ -0,0 +1,6 @@
return {
target = {
linux = "~/.config/paru",
default = "~/.config/paru",
},
}

2
paru/files/paru.conf Normal file
View File

@@ -0,0 +1,2 @@
[options]
BottomUp

6
yazi/config.lua Normal file
View File

@@ -0,0 +1,6 @@
return {
target = {
linux = "~/.config/yazi",
default = "~/.config/yazi",
},
}

165
yazi/files/theme.toml Normal file
View File

@@ -0,0 +1,165 @@
# : Manager [[[
[manager]
cwd = { fg = "#f0dfd6" }
# Tab
tab_active = { fg = "#4f2500", bg = "#ffb782", bold = true }
tab_inactive = { fg = "#ffdcc5", bg = "#301400" }
tab_width = 1
# Find
find_keyword = { fg = "#ffb4ab", bold = true, italic = true, underline = true }
find_position = { fg = "#ffb4ab", bold = true, italic = true }
# Marker
marker_copied = { fg = "#c8ce61", bg = "#c8ce61" }
marker_cut = { fg = "#e3e6af", bg = "#e3e6af" }
marker_marked = { fg = "#ffb4ab", bg = "#ffb4ab" }
marker_selected = { fg = "#c7ca95", bg = "#c7ca95" }
# Count
count_copied = { fg = "#1b1d00", bg = "#e3e6af" }
count_cut = { fg = "#1b1d00", bg = "#e3e6af" }
count_selected = { fg = "#4f2500", bg = "#c7ca95" }
# Border
border_symbol = "│"
border_style = { fg = "#ffb782" }
# : ]]]
# : Status [[[
[status]
separator_open = "🭁"
separator_close = "🭠"
separator_style = { bg = "#4f2500", fg = "#F4A261" }
[mode]
# Mode
normal_main = { bg = "#ffb782", fg = "#4f2500", bold = true }
normal_alt = { bg = "#52443b", fg = "#d6c3b7" }
# Select mode
select_main = { bg = "#e4bfa7", fg = "#422b1a", bold = true }
select_alt = { bg = "#52443b", fg = "#d6c3b7" }
# Unset mode
unset_main = { bg = "#c7ca95", fg = "#30330b", bold = true }
unset_alt = { bg = "#52443b", fg = "#d6c3b7" }
# Progress
progress_label = { bold = true }
progress_normal = { fg = "#ffb782", bg = "#413731" }
progress_error = { fg = "#ffb4ab", bg = "#413731" }
# Permissions
permissions_t = { fg = "#b96b39" }
permissions_w = { fg = "#808442" }
permissions_x = { fg = "#ff2b12" }
permissions_r = { fg = "#b9c03c" }
permissions_s = { fg = "#ff802c" }
# : ]]]
# : Select [[[
[select]
border = { fg = "#ffb782" }
active = { fg = "#c7ca95", bold = true }
inactive = {}
# : ]]]
# : Input [[[
[input]
border = { fg = "#ffb782" }
value = { fg = "#f0dfd6" }
# : ]]]
# : Completion [[[
[completion]
border = { fg = "#ffb782", bg = "#4f2500" }
# : ]]]
# : Tasks [[[
[tasks]
border = { fg = "#ffb782" }
title = {}
hovered = { fg = "#e3e6af", underline = true }
# : ]]]
# : Which [[[
[which]
cols = 3
mask = { bg = "#413731" }
cand = { fg = "#ffb782" }
rest = { fg = "#4f2500" }
desc = { fg = "#f0dfd6" }
separator = " ▶ "
separator_style = { fg = "#f0dfd6" }
# : ]]]
# : Help [[[
[help]
on = { fg = "#f0dfd6" }
run = { fg = "#f0dfd6" }
footer = { fg = "#422b1a", bg = "#e4bfa7" }
# : ]]]
# : Notify [[[
[notify]
title_info = { fg = "#c7ca95" }
title_warn = { fg = "#ffb782" }
title_error = { fg = "#ffb4ab" }
# : ]]]
# : File-specific styles [[[
[filetype]
rules = [
# Images
{ mime = "image/*", fg = "#94e2d5" },
# Media
{ mime = "{audio,video}/*", fg = "#f9e2af" },
# Archives
{ mime = "application/{zip,rar,7z*,tar,gzip,xz,zstd,bzip*,lzma,compress,archive,cpio,arj,xar,ms-cab*}", fg = "#f5c2e7" },
# Documents
{ mime = "application/{pdf,doc,rtf}", fg = "#a6e3a1" },
# Special files
{ name = "*", is = "orphan", bg = "#93000a" },
{ name = "*", is = "exec", fg = "#ffdad6" },
# Fallback
{ name = "*", fg = "#f0dfd6" },
{ name = "*/", fg = "#ffb782" },
]
# : ]]]

159
yazi/files/yazi.toml Normal file
View File

@@ -0,0 +1,159 @@
"$schema" = "https://yazi-rs.github.io/schemas/yazi.json"
[mgr]
ratio = [ 1, 4, 3 ]
sort_by = "alphabetical"
sort_sensitive = false
sort_reverse = false
sort_dir_first = true
sort_translit = false
linemode = "none"
show_hidden = false
show_symlink = true
scrolloff = 5
mouse_events = [ "click", "scroll" ]
title_format = "Yazi: {cwd}"
[preview]
wrap = "no"
tab_size = 2
max_width = 2000
max_height = 2000
cache_dir = ""
image_delay = 30
image_filter = "triangle"
image_quality = 75
sixel_fraction = 15
ueberzug_scale = 1
ueberzug_offset = [ 0, 0, 0, 0 ]
[opener]
edit = [
{ run = '${EDITOR:-vi} "$@"', desc = "$EDITOR", block = true, for = "unix" },
{ run = 'code %*', orphan = true, desc = "code", for = "windows" },
{ run = 'code -w %*', block = true, desc = "code (block)", for = "windows" },
]
open = [
{ run = 'xdg-open "$1"', desc = "Open", for = "linux" },
{ run = 'open "$@"', desc = "Open", for = "macos" },
{ run = 'start "" "%1"', orphan = true, desc = "Open", for = "windows" },
{ run = 'termux-open "$1"', desc = "Open", for = "android" },
]
reveal = [
{ run = 'xdg-open "$(dirname "$1")"', desc = "Reveal", for = "linux" },
{ run = 'open -R "$1"', desc = "Reveal", for = "macos" },
{ run = 'explorer /select,"%1"', orphan = true, desc = "Reveal", for = "windows" },
{ run = 'termux-open "$(dirname "$1")"', desc = "Reveal", for = "android" },
{ run = '''clear; exiftool "$1"; echo "Press enter to exit"; read _''', block = true, desc = "Show EXIF", for = "unix" },
]
extract = [
{ run = 'ya pub extract --list "$@"', desc = "Extract here", for = "unix" },
{ run = 'ya pub extract --list %*', desc = "Extract here", for = "windows" },
]
play = [
{ run = 'mpv --force-window "$@"', orphan = true, for = "unix" },
{ run = 'mpv --force-window %*', orphan = true, for = "windows" },
{ run = '''mediainfo "$1"; echo "Press enter to exit"; read _''', block = true, desc = "Show media info", for = "unix" },
]
[open]
rules = [
# Folder
{ name = "*/", use = [ "edit", "open", "reveal" ] },
# Text
{ mime = "text/*", use = [ "edit", "reveal" ] },
# Image
{ mime = "image/*", use = [ "open", "reveal" ] },
# Media
{ mime = "{audio,video}/*", use = [ "play", "reveal" ] },
# Archive
{ mime = "application/{zip,rar,7z*,tar,gzip,xz,zstd,bzip*,lzma,compress,archive,cpio,arj,xar,ms-cab*}", use = [ "extract", "reveal" ] },
# JSON
{ mime = "application/{json,ndjson}", use = [ "edit", "reveal" ] },
{ mime = "*/javascript", use = [ "edit", "reveal" ] },
# Empty file
{ mime = "inode/empty", use = [ "edit", "reveal" ] },
# Fallback
{ name = "*", use = [ "open", "reveal" ] },
]
[tasks]
micro_workers = 10
macro_workers = 10
bizarre_retry = 3
image_alloc = 536870912 # 512MB
image_bound = [ 0, 0 ]
suppress_preload = false
[plugin]
fetchers = [
# Mimetype
{ id = "mime", name = "*", run = "mime", prio = "high" },
]
spotters = [
{ name = "*/", run = "folder" },
# Code
{ mime = "text/*", run = "code" },
{ mime = "application/{mbox,javascript,wine-extension-ini}", run = "code" },
# Image
{ mime = "image/{avif,hei?,jxl}", run = "magick" },
{ mime = "image/svg+xml", run = "svg" },
{ mime = "image/*", run = "image" },
# Video
{ mime = "video/*", run = "video" },
# Fallback
{ name = "*", run = "file" },
]
preloaders = [
# Image
{ mime = "image/{avif,hei?,jxl}", run = "magick" },
{ mime = "image/svg+xml", run = "svg" },
{ mime = "image/*", run = "image" },
# Video
{ mime = "video/*", run = "video" },
# PDF
{ mime = "application/pdf", run = "pdf" },
# Font
{ mime = "font/*", run = "font" },
{ mime = "application/ms-opentype", run = "font" },
]
previewers = [
{ name = "*/", run = "folder" },
# Code
{ mime = "text/*", run = "code" },
{ mime = "application/{mbox,javascript,wine-extension-ini}", run = "code" },
# JSON
{ mime = "application/{json,ndjson}", run = "json" },
# Image
{ mime = "image/{avif,hei?,jxl}", run = "magick" },
{ mime = "image/svg+xml", run = "svg" },
{ mime = "image/*", run = "image" },
# Video
{ mime = "video/*", run = "video" },
# PDF
{ mime = "application/pdf", run = "pdf" },
# Archive
{ mime = "application/{zip,rar,7z*,tar,gzip,xz,zstd,bzip*,lzma,compress,archive,cpio,arj,xar,ms-cab*}", run = "archive" },
{ mime = "application/{debian*-package,redhat-package-manager,rpm,android.package-archive}", run = "archive" },
{ name = "*.{AppImage,appimage}", run = "archive" },
# Virtual Disk / Disk Image
{ mime = "application/{iso9660-image,qemu-disk,ms-wim,apple-diskimage}", run = "archive" },
{ mime = "application/virtualbox-{vhd,vhdx}", run = "archive" },
{ name = "*.{img,fat,ext,ext2,ext3,ext4,squashfs,ntfs,hfs,hfsx}", run = "archive" },
# Font
{ mime = "font/*", run = "font" },
{ mime = "application/ms-opentype", run = "font" },
# Empty file
{ mime = "inode/empty", run = "empty" },
# Fallback
{ name = "*", run = "file" },
]
[input]
cursor_blink = false
# cd
cd_title = "Change directory:"
cd_origin = "top-center"
cd_offset = [ 0, 2, 50, 3 ]