Compare commits
10 commits
047a4808cc
...
20799af627
Author | SHA1 | Date | |
---|---|---|---|
20799af627 | |||
b4eece087b | |||
6d21f3887c | |||
5f0343b67b | |||
666fc20045 | |||
90e01eaea4 | |||
6df433b2fd | |||
2b10bd8763 | |||
557f33c14a | |||
285360a1dc |
62 changed files with 627 additions and 925 deletions
|
@ -2,8 +2,8 @@ color_theme = "Default"
|
|||
theme_background = False
|
||||
truecolor = True
|
||||
force_tty = False
|
||||
presets = "cpu:1:default,proc:0:default cpu:0:default,mem:0:default,net:0:default cpu:0:block,net:0:tty"
|
||||
vim_keys = False
|
||||
presets = "proc:0:default,cpu:1:default mem:0:default net:0:tty"
|
||||
vim_keys = True
|
||||
rounded_corners = True
|
||||
graph_symbol = "braille"
|
||||
graph_symbol_cpu = "default"
|
||||
|
@ -48,7 +48,7 @@ mem_below_net = False
|
|||
zfs_arc_cached = True
|
||||
show_swap = True
|
||||
swap_disk = True
|
||||
show_disks = True
|
||||
show_disks = False
|
||||
only_physical = True
|
||||
use_fstab = True
|
||||
zfs_hide_datasets = False
|
||||
|
|
|
@ -1,16 +1,5 @@
|
|||
{
|
||||
"input": {
|
||||
"bass_enhancer#0": {
|
||||
"amount": 3.0,
|
||||
"blend": 0.0,
|
||||
"bypass": false,
|
||||
"floor": 12.0,
|
||||
"floor-active": true,
|
||||
"harmonics": 10.0,
|
||||
"input-gain": 0.0,
|
||||
"output-gain": 0.0,
|
||||
"scope": 150.0
|
||||
},
|
||||
"blocklist": [],
|
||||
"limiter#0": {
|
||||
"alr": false,
|
||||
|
@ -34,7 +23,7 @@
|
|||
},
|
||||
"plugins_order": [
|
||||
"rnnoise#0",
|
||||
"bass_enhancer#0",
|
||||
"speex#0",
|
||||
"limiter#0"
|
||||
],
|
||||
"rnnoise#0": {
|
||||
|
@ -46,6 +35,20 @@
|
|||
"release": 20.0,
|
||||
"vad-thres": 50.0,
|
||||
"wet": 0.0
|
||||
},
|
||||
"speex#0": {
|
||||
"bypass": false,
|
||||
"enable-agc": false,
|
||||
"enable-denoise": true,
|
||||
"enable-dereverb": true,
|
||||
"input-gain": 0.0,
|
||||
"noise-suppression": -70,
|
||||
"output-gain": 0.0,
|
||||
"vad": {
|
||||
"enable": true,
|
||||
"probability-continue": 90,
|
||||
"probability-start": 95
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,15 +1,15 @@
|
|||
{
|
||||
"output": {
|
||||
"bass_enhancer#0": {
|
||||
"amount": 3.0,
|
||||
"amount": 0.0,
|
||||
"blend": 0.0,
|
||||
"bypass": false,
|
||||
"floor": 12.0,
|
||||
"floor-active": true,
|
||||
"harmonics": 10.0,
|
||||
"harmonics": 8.5,
|
||||
"input-gain": 0.0,
|
||||
"output-gain": 0.0,
|
||||
"scope": 150.0
|
||||
"scope": 100.0
|
||||
},
|
||||
"blocklist": [],
|
||||
"filter#0": {
|
||||
|
|
|
@ -1,6 +0,0 @@
|
|||
XDG_CACHE_HOME=$HOME/.cache
|
||||
XDG_CONFIG_HOME=$HOME/.config
|
||||
XDG_DATA_HOME=$HOME/.local/share
|
||||
XDG_BIN_HOME=$HOME/.local/bin
|
||||
XDG_LIB_HOME=$HOME/.local/lib
|
||||
XDG_STATE_HOME=$HOME/.local/state
|
|
@ -1,11 +0,0 @@
|
|||
CARGO_HOME=$XDG_DATA_HOME/cargo
|
||||
CUDA_CACHE_PATH=$XDG_CACHE_HOME/nv
|
||||
DOTNET_CLI_HOME=$XDG_DATA_HOME/dotnet
|
||||
GOPATH=$XDG_DATA_HOME/go
|
||||
GTK2_RC_FILES=$XDG_CONFIG_HOME/gtk-2.0/gtkrc
|
||||
HISTFILE=$XDG_STATE_HOME/bash/history
|
||||
NIMBLE_DIR=$XDG_DATA_HOME/nimble
|
||||
NUGET_PACKAGES=$XDG_CACHE_HOME/nuget
|
||||
RUSTUP_HOME=$XDG_DATA_HOME/rustup
|
||||
W3M_DIR=$XDG_DATA_HOME/w3m
|
||||
WINEPREFIX=$XDG_DATA_HOME/wine
|
|
@ -1,6 +0,0 @@
|
|||
BROWSER=firefox
|
||||
EDITOR=nvim
|
||||
LANG=en_US.UTF-8
|
||||
PAGER=less
|
||||
SSH_AUTH_SOCK=$XDG_RUNTIME_DIR/ssh-agent.socket
|
||||
TERMINAL=foot
|
|
@ -1,84 +1,124 @@
|
|||
# Git
|
||||
alias g "git"
|
||||
alias gc "git clone"
|
||||
alias gd "git diff --ignore-space-at-eol"
|
||||
alias gl "git log --oneline"
|
||||
alias gp "git pull"
|
||||
alias gs "git status"
|
||||
if command -q git
|
||||
alias g "git"
|
||||
alias gc "git clone"
|
||||
alias gd "git diff --ignore-space-at-eol"
|
||||
alias gds "git diff --ignore-space-at-eol --compact-summary"
|
||||
alias gl "git log --oneline"
|
||||
alias gp "git pull"
|
||||
alias gs "git status"
|
||||
alias home "git --git-dir=$HOME/.home/ --work-tree=$HOME"
|
||||
alias homeinit "git clone --bare https://git.urbach.dev/sys/home $HOME/.home && home checkout"
|
||||
alias h "home"
|
||||
alias hs "home status"
|
||||
alias hd "home diff --ignore-space-at-eol"
|
||||
alias hds "home diff --ignore-space-at-eol --compact-summary"
|
||||
alias hp "home pull"
|
||||
end
|
||||
|
||||
# Go
|
||||
alias gb "go build -v"
|
||||
alias godeps "go list -f '{{ join .Deps \"\n\"}}' ."
|
||||
alias gt "go test -v"
|
||||
alias gts "gotestsum"
|
||||
|
||||
# Home
|
||||
alias home "git --git-dir=$HOME/.home/ --work-tree=$HOME"
|
||||
alias homeinit "git clone --bare https://git.urbach.dev/sys/home $HOME/.home && home checkout"
|
||||
alias h "home"
|
||||
alias hs "home status"
|
||||
alias hd "home diff --ignore-space-at-eol"
|
||||
alias hp "home pull"
|
||||
if command -q go
|
||||
alias gb "go build -v"
|
||||
alias godeps "go list -f '{{ join .Deps \"\n\"}}' ."
|
||||
alias gt "go test -v"
|
||||
alias gts "gotestsum"
|
||||
end
|
||||
|
||||
# Hyperfine
|
||||
alias bench "hyperfine --shell=none"
|
||||
if command -q hyperfine
|
||||
alias bench "hyperfine --shell=none"
|
||||
end
|
||||
|
||||
# Kernel
|
||||
alias kerr "sudo dmesg --level=emerg,alert,crit,err"
|
||||
alias klog "sudo dmesg"
|
||||
if command -q dmesg
|
||||
alias kerr "sudo dmesg --level=emerg,alert,crit,err"
|
||||
alias klog "sudo dmesg"
|
||||
end
|
||||
|
||||
# List
|
||||
alias l "ls"
|
||||
alias ll "ls -l"
|
||||
alias l2 "ls -T -L2"
|
||||
alias lu "ls -l --total-size --sort=size --reverse --no-permissions --no-user --no-time"
|
||||
alias lp "ls -l --no-filesize --no-time"
|
||||
if command -q ls
|
||||
alias l "ls"
|
||||
alias ll "ls -l"
|
||||
alias l2 "ls -T -L2"
|
||||
alias lu "ls -l --total-size --sort=size --reverse --no-permissions --no-user --no-time"
|
||||
alias lp "ls -l --no-filesize --no-time"
|
||||
end
|
||||
|
||||
# Lsof
|
||||
alias tcp "lsof -PniTCP"
|
||||
alias udp "lsof -PniUDP"
|
||||
if command -q lsof
|
||||
alias tcp "lsof -PniTCP"
|
||||
alias udp "lsof -PniUDP"
|
||||
end
|
||||
|
||||
# MPV
|
||||
if command -q mpv
|
||||
alias music "mpv music --shuffle --no-video"
|
||||
end
|
||||
|
||||
# Neovim
|
||||
alias e "nvim"
|
||||
alias n "nvim"
|
||||
if command -q nvim
|
||||
alias e nvim
|
||||
end
|
||||
|
||||
# Pacman
|
||||
alias p "pacman"
|
||||
alias pi "sudo pacman -S"
|
||||
alias pr "sudo pacman -Rs"
|
||||
alias pu "sudo pacman -Syu"
|
||||
alias pl "pacman -Qq"
|
||||
alias pe "pacman -Qe"
|
||||
alias pc "sudo pacman -Sc"
|
||||
alias paur "pacman -Qm"
|
||||
alias pfiles "pacman -Ql"
|
||||
alias porphan "pacman -Qtdq"
|
||||
alias powner "pacman -Qo"
|
||||
if command -q apk
|
||||
alias p "apk"
|
||||
alias pi "sudo apk add"
|
||||
alias pr "sudo apk del"
|
||||
alias pu "sudo apk update && sudo apk upgrade"
|
||||
alias pl "apk info"
|
||||
alias po "apk info --who-owns"
|
||||
else if command -q pacman
|
||||
alias p "pacman"
|
||||
alias pi "sudo pacman -S"
|
||||
alias pr "sudo pacman -Rs"
|
||||
alias pu "sudo pacman -Syu"
|
||||
alias pl "pacman -Qq"
|
||||
alias pe "pacman -Qe"
|
||||
alias pc "sudo pacman -Sc"
|
||||
alias paur "pacman -Qm"
|
||||
alias pfiles "pacman -Ql"
|
||||
alias porphan "pacman -Qtdq"
|
||||
alias po "pacman -Qo"
|
||||
end
|
||||
|
||||
# Sudo
|
||||
if command -q doas
|
||||
alias sudo "doas"
|
||||
end
|
||||
|
||||
# Systemctl
|
||||
alias start "sudo systemctl start"
|
||||
alias stop "sudo systemctl stop"
|
||||
alias enable "sudo systemctl enable"
|
||||
alias disable "sudo systemctl disable"
|
||||
alias restart "sudo systemctl restart"
|
||||
alias running "systemctl list-units --type=service --state=running"
|
||||
alias disabled "systemctl list-unit-files --type=service --state=disabled"
|
||||
alias enabled "systemctl list-unit-files --type=service --state=enabled"
|
||||
alias timers "systemctl list-timers"
|
||||
if command -q service
|
||||
alias services "service -l"
|
||||
else if command -q systemctl
|
||||
alias start "sudo systemctl start"
|
||||
alias stop "sudo systemctl stop"
|
||||
alias enable "sudo systemctl enable"
|
||||
alias disable "sudo systemctl disable"
|
||||
alias restart "sudo systemctl restart"
|
||||
alias running "systemctl list-units --type=service --state=running"
|
||||
alias disabled "systemctl list-unit-files --type=service --state=disabled"
|
||||
alias enabled "systemctl list-unit-files --type=service --state=enabled"
|
||||
alias timers "systemctl list-timers"
|
||||
alias bios "systemctl reboot --firmware-setup"
|
||||
end
|
||||
|
||||
# Tmux
|
||||
alias ta "tmux attach"
|
||||
alias td "tmux detach"
|
||||
alias tl "tmux ls"
|
||||
alias tk "tmux kill-server"
|
||||
if command -q tmux
|
||||
alias ta "tmux attach"
|
||||
alias td "tmux detach"
|
||||
alias tl "tmux ls"
|
||||
alias tk "tmux kill-server"
|
||||
end
|
||||
|
||||
# ...
|
||||
alias bios "systemctl reboot --firmware-setup"
|
||||
alias align "column -t -o ' '"
|
||||
alias cfg "config"
|
||||
alias cls "clear"
|
||||
alias debug "blinkenlights"
|
||||
alias disasm "llvm-objdump --disassembler-color=on --x86-asm-syntax=intel -d"
|
||||
alias ff "fastfetch"
|
||||
alias fn "rg --files | rg"
|
||||
alias hex "hexdump -C"
|
||||
alias log "journalctl"
|
||||
alias utc "date -u +'%Y-%m-%dT%H:%M:%SZ'"
|
||||
|
|
|
@ -1,16 +1,13 @@
|
|||
# Interactive mode
|
||||
if status is-interactive
|
||||
# Aliases
|
||||
source $HOME/.config/fish/alias.fish
|
||||
set -x LS_COLORS di=0:ln=0:so=0:pi=0:ex=0:bd=0:cd=0:su=0:sg=0:tw=0:ow=0
|
||||
|
||||
# Set environment variables from .env
|
||||
while read -la line
|
||||
set -l keyval (string split -m1 "=" $line)
|
||||
set -l key (string trim $keyval[1])
|
||||
set -l value (string trim $keyval[2..])
|
||||
set -l value (eval echo $value)
|
||||
set -xg $key $value
|
||||
end < ~/.env
|
||||
end
|
||||
|
||||
# Load systemd user environment
|
||||
set GENERATOR /usr/lib/systemd/user-environment-generators/30-systemd-environment-d-generator
|
||||
|
||||
if test -e $GENERATOR
|
||||
export ($GENERATOR)
|
||||
end
|
||||
|
||||
# Add to PATH
|
||||
fish_add_path (go env GOPATH)/bin
|
||||
fish_add_path $XDG_CONFIG_HOME/fish/scripts
|
|
@ -42,4 +42,3 @@ SETUVAR fish_pager_color_selected_completion:\x1d
|
|||
SETUVAR fish_pager_color_selected_description:\x1d
|
||||
SETUVAR fish_pager_color_selected_prefix:\x1d
|
||||
SETUVAR fish_prompt_pwd_dir_length:0
|
||||
SETUVAR fish_user_paths:/home/eduard/\x2econfig/fish/scripts\x1e/home/eduard/\x2elocal/share/go/bin\x1e/home/eduard/\x2elocal/bin
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
function config
|
||||
$EDITOR $HOME/.config/$argv
|
||||
f $HOME/.config/$argv
|
||||
end
|
||||
|
|
|
@ -1,8 +1,19 @@
|
|||
function f
|
||||
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"
|
||||
function f --wraps nnn --description 'support nnn quit and change directory'
|
||||
if test -n "$NNNLVL" -a "$NNNLVL" -ge 1
|
||||
echo "nnn is already running"
|
||||
return
|
||||
end
|
||||
|
||||
if test -n "$XDG_CONFIG_HOME"
|
||||
set -x NNN_TMPFILE "$XDG_CONFIG_HOME/nnn/.lastd"
|
||||
else
|
||||
set -x NNN_TMPFILE "$HOME/.config/nnn/.lastd"
|
||||
end
|
||||
|
||||
command nnn $argv
|
||||
|
||||
if test -e $NNN_TMPFILE
|
||||
source $NNN_TMPFILE
|
||||
rm -- $NNN_TMPFILE
|
||||
end
|
||||
rm -f -- "$tmp"
|
||||
end
|
|
@ -1,4 +1,4 @@
|
|||
function ls
|
||||
function ls --wraps eza
|
||||
if command -q eza
|
||||
eza --group-directories-first --time-style relative -T -L1 $argv
|
||||
else
|
||||
|
|
|
@ -8,7 +8,13 @@ end
|
|||
|
||||
function init_session
|
||||
tmux new-session -d -s main -d -x (tput cols) -y (tput lines)
|
||||
|
||||
if command -q journalctl
|
||||
tmux split-window -v -l 10 journalctl -f
|
||||
else if command -q logread
|
||||
tmux split-window -v -l 10 logread -f
|
||||
end
|
||||
|
||||
tmux select-pane -t 0
|
||||
tmux split-window -h -l 50 btop
|
||||
tmux select-pane -t 0
|
||||
|
|
|
@ -1,20 +1,26 @@
|
|||
#!/bin/fish
|
||||
#!/usr/bin/fish
|
||||
set DIRECTORIES documents music pictures projects videos
|
||||
set EXCLUDES node_modules .cache .godot .svelte-kit
|
||||
set FLAGS -avz --delete
|
||||
set FLAGS --archive --compress --delete --human-readable --progress
|
||||
set HOSTS $argv
|
||||
set USER (whoami)
|
||||
set DESTINATION "~/files/"
|
||||
set DESTINATION "~/"
|
||||
|
||||
for exclude in $EXCLUDES
|
||||
set -a FLAGS --exclude $exclude
|
||||
end
|
||||
|
||||
for host in $HOSTS
|
||||
echo "[$host]"
|
||||
set_color yellow
|
||||
echo " $host"
|
||||
|
||||
for DIR in $DIRECTORIES
|
||||
echo "Backing up $DIR..."
|
||||
rsync $FLAGS ~/$DIR $USER@$host:$DESTINATION
|
||||
for dir in $DIRECTORIES
|
||||
set_color blue
|
||||
echo " $dir"
|
||||
|
||||
set_color normal
|
||||
rsync $FLAGS ~/$dir $host:$DESTINATION
|
||||
end
|
||||
|
||||
echo ""
|
||||
end
|
|
@ -1,4 +1,4 @@
|
|||
#!/bin/fish
|
||||
#!/usr/bin/fish
|
||||
echo "This will modify your git repository to count the lines of code for each commit."
|
||||
read -l -P "Do you want to continue? [y/N] " CONFIRM
|
||||
|
||||
|
|
|
@ -1,5 +1,12 @@
|
|||
exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP
|
||||
exec-once = /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
|
||||
exec-once = waypaper --restore
|
||||
# Autostart
|
||||
exec-once = swaybg -i ~/pictures/wallpapers/01.png
|
||||
exec-once = wl-paste --watch cliphist store
|
||||
exec-once = $statusbar
|
||||
exec-once = ssh-agent -D -a $SSH_AUTH_SOCK
|
||||
exec-once = openrc --user gui
|
||||
|
||||
# Disabled
|
||||
#exec-once = /usr/libexec/pipewire-launcher
|
||||
#exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP
|
||||
#exec-once = /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
|
||||
#exec-once = waypaper --restore
|
|
@ -46,6 +46,7 @@ misc {
|
|||
vfr = true
|
||||
animate_manual_resizes = false
|
||||
render_ahead_of_time = false
|
||||
disable_hyprland_qtutils_check = true
|
||||
}
|
||||
|
||||
cursor {
|
||||
|
@ -55,7 +56,7 @@ cursor {
|
|||
|
||||
input {
|
||||
accel_profile = flat
|
||||
sensitivity = 0
|
||||
sensitivity = -0.75
|
||||
}
|
||||
|
||||
dwindle {
|
||||
|
@ -67,6 +68,10 @@ ecosystem {
|
|||
no_donation_nag = true
|
||||
}
|
||||
|
||||
xwayland {
|
||||
enabled = false
|
||||
}
|
||||
|
||||
debug {
|
||||
overlay = false
|
||||
}
|
|
@ -2,24 +2,26 @@ $main = SUPER
|
|||
|
||||
# Apps
|
||||
bind = $main, B, exec, $browser
|
||||
bind = $main, D, exec, $editor
|
||||
bind = $main, E, exec, $files
|
||||
bind = $main, F1, exec, $systeminfo
|
||||
bind = $main, E, exec, $editor
|
||||
bind = $main, F, exec, $files
|
||||
bind = $main, K, exec, $calendar
|
||||
bind = $main, L, exec, $lockscreen
|
||||
bind = $main, M, exec, $email
|
||||
bind = $main, P, exec, $processmonitor
|
||||
bind = $main, Return, exec, $floating
|
||||
bind = $main, S, exec, pkill $statusbar || $statusbar
|
||||
bind = $main, Space, exec, pkill $menu || $menu
|
||||
bind = $main, T, exec, $terminal
|
||||
bind = $main, W, exec, $wallpaper
|
||||
bind = $main, U, exec, $update
|
||||
bind = , Print, exec, $screenshot
|
||||
bind = $main, F1, exec, $systeminfo
|
||||
bind = $main, Return, exec, $floating
|
||||
bind = $main, Space, exec, pkill $menu || $menu
|
||||
bind =, Print, exec, $screenshot
|
||||
|
||||
# Window management
|
||||
bind = $main, C, killactive,
|
||||
bind = $main, F, fullscreen,
|
||||
bind = $main, V, togglefloating,
|
||||
bind = $main, J, togglesplit,
|
||||
bind = $main, V, togglefloating,
|
||||
bind = $main, Super_R, fullscreen,
|
||||
|
||||
# Session management
|
||||
bind = $main, Backspace, exit,
|
||||
|
@ -88,6 +90,6 @@ bindl =, XF86AudioNext, exec, playerctl next
|
|||
bindl =, XF86AudioPrev, exec, playerctl previous
|
||||
|
||||
# Volume control
|
||||
bindle =, XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.05+
|
||||
bindle =, XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.05-
|
||||
bindle =, XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.02+
|
||||
bindle =, XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.02-
|
||||
bindl =, XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle
|
|
@ -1,19 +1,21 @@
|
|||
# Apps
|
||||
$browser = firefox
|
||||
$email = evolution
|
||||
$files = thunar
|
||||
$logout = wlogout
|
||||
$lockscreen = swaylock
|
||||
$menu = fuzzel
|
||||
$screenshot = IMG=~/pictures/screenshots/$(date +%Y-%m-%d_%H-%M-%S).png && grim -g "$(slurp -d)" $IMG && wl-copy < $IMG
|
||||
$shell = fish
|
||||
$statusbar = waybar
|
||||
$terminal = foot
|
||||
$wallpaper = waypaper
|
||||
|
||||
# Terminal based
|
||||
$calendar = $terminal -e calcurse
|
||||
$editor = $terminal -e nvim
|
||||
$email = $terminal -e aerc
|
||||
$files = $terminal -e nnn
|
||||
$center = [float;size 960 540;center]
|
||||
$floating = $center $terminal
|
||||
$systeminfo = $center $terminal --hold -e fastfetch
|
||||
$processmonitor = $terminal -e btop
|
||||
$update = $floating -e sudo pacman -Syu
|
||||
$systeminfo = $floating --hold -e fastfetch
|
||||
$processmonitor = $floating -e btop
|
||||
$update = $floating -e fish
|
246
.config/nvim/colors/monokai.lua
Normal file
246
.config/nvim/colors/monokai.lua
Normal file
|
@ -0,0 +1,246 @@
|
|||
vim.cmd("highlight clear")
|
||||
vim.o.background = "dark"
|
||||
vim.o.termguicolors = true
|
||||
vim.g.colors_name = "monokai"
|
||||
|
||||
local c = {
|
||||
base0 = "#222426",
|
||||
base1 = "#272a30",
|
||||
base2 = "#26292C",
|
||||
base3 = "#2E323C",
|
||||
base4 = "#333842",
|
||||
base5 = "#4d5154",
|
||||
base6 = "#9ca0a4",
|
||||
base7 = "#b1b1b1",
|
||||
base8 = "#e3e3e1",
|
||||
border = "#a1b5b1",
|
||||
brown = "#504945",
|
||||
white = "#f8f8f0",
|
||||
grey = "#8F908A",
|
||||
black = "#000000",
|
||||
pink = "#f92672",
|
||||
green = "#a6e22e",
|
||||
aqua = "#66d9ef",
|
||||
yellow = "#e6db74",
|
||||
orange = "#fd971f",
|
||||
purple = "#ae81ff",
|
||||
red = "#e95678",
|
||||
diff_add = "#3d5213",
|
||||
diff_remove = "#4a0f23",
|
||||
diff_change = "#27406b",
|
||||
diff_text = "#23324d",
|
||||
}
|
||||
|
||||
local hl = function(group, opts)
|
||||
vim.api.nvim_set_hl(0, group, opts)
|
||||
end
|
||||
|
||||
-- Syntax
|
||||
hl("Normal", { fg = c.white, bg = c.base2 })
|
||||
hl("NormalFloat", { bg = c.base1 })
|
||||
hl("Pmenu", { fg = c.white, bg = c.base3 })
|
||||
hl("PmenuSel", { fg = c.base4, bg = c.orange })
|
||||
hl("PmenuSelBold", { fg = c.base4, bg = c.orange })
|
||||
hl("PmenuThumb", { fg = c.purple, bg = c.green })
|
||||
hl("PmenuSbar", { bg = c.base3 })
|
||||
hl("Cursor", { reverse = true })
|
||||
hl("ColorColumn", { bg = c.base3 })
|
||||
hl("CursorLine", { bg = c.base3 })
|
||||
hl("NonText", { fg = c.base5 })
|
||||
hl("Visual", { bg = c.base4 })
|
||||
hl("VisualNOS", { bg = c.base3 })
|
||||
hl("Search", { fg = c.base2, bg = c.yellow })
|
||||
hl("IncSearch", { fg = c.base2, bg = c.orange })
|
||||
hl("CursorLineNr", { fg = c.orange, bg = c.base2 })
|
||||
hl("MatchParen", { fg = c.pink })
|
||||
hl("Question", { fg = c.yellow })
|
||||
hl("ModeMsg", { fg = c.white, bold = true })
|
||||
hl("MoreMsg", { fg = c.white, bold = true })
|
||||
hl("ErrorMsg", { fg = c.red, bold = true })
|
||||
hl("WarningMsg", { fg = c.yellow, bold = true })
|
||||
hl("VertSplit", { fg = c.brown })
|
||||
hl("LineNr", { fg = c.base5, bg = c.base2 })
|
||||
hl("SignColumn", { fg = c.white, bg = c.base2 })
|
||||
hl("StatusLine", { fg = c.base7, bg = c.base3 })
|
||||
hl("StatusLineNC", { fg = c.grey, bg = c.base3 })
|
||||
hl("Tabline", {})
|
||||
hl("TabLineFill", {})
|
||||
hl("TabLineSel", { bg = c.base4 })
|
||||
hl("SpellBad", { fg = c.red, undercurl = true })
|
||||
hl("SpellCap", { fg = c.purple, undercurl = true })
|
||||
hl("SpellRare", { fg = c.aqua, undercurl = true })
|
||||
hl("SpellLocal", { fg = c.pink, undercurl = true })
|
||||
hl("SpecialKey", { fg = c.pink })
|
||||
hl("Title", { fg = c.yellow, bold = true })
|
||||
hl("Directory", { fg = c.aqua })
|
||||
hl("DiffAdd", { bg = c.diff_add })
|
||||
hl("DiffDelete", { bg = c.diff_remove })
|
||||
hl("DiffChange", { bg = c.diff_change })
|
||||
hl("DiffText", { bg = c.diff_text })
|
||||
hl("diffAdded", { fg = c.green })
|
||||
hl("diffRemoved", { fg = c.pink })
|
||||
hl("Folded", { fg = c.grey, bg = c.base3 })
|
||||
hl("FoldColumn", { fg = c.white, bg = c.black })
|
||||
hl("Constant", { fg = c.aqua })
|
||||
hl("Number", { fg = c.purple })
|
||||
hl("Float", { fg = c.purple })
|
||||
hl("Boolean", { fg = c.purple })
|
||||
hl("Character", { fg = c.yellow })
|
||||
hl("String", { fg = c.yellow })
|
||||
hl("Type", { fg = c.aqua })
|
||||
hl("Structure", { fg = c.aqua })
|
||||
hl("StorageClass", { fg = c.aqua })
|
||||
hl("Typedef", { fg = c.aqua })
|
||||
hl("Identifier", { fg = c.white })
|
||||
hl("Function", { fg = c.green, italic = true })
|
||||
hl("Statement", { fg = c.pink })
|
||||
hl("Operator", { fg = c.pink })
|
||||
hl("Label", { fg = c.pink })
|
||||
hl("Keyword", { fg = c.pink, italic = true })
|
||||
hl("PreProc", { fg = c.green })
|
||||
hl("Include", { fg = c.aqua, italic = true })
|
||||
hl("Define", { fg = c.pink })
|
||||
hl("Macro", { fg = c.pink })
|
||||
hl("PreCondit", { fg = c.pink })
|
||||
hl("Special", { fg = c.white })
|
||||
hl("SpecialChar", { fg = c.pink })
|
||||
hl("Delimiter", { fg = c.white })
|
||||
hl("SpecialComment", { fg = c.grey, italic = true })
|
||||
hl("Tag", { fg = c.orange })
|
||||
hl("Todo", { fg = c.orange })
|
||||
hl("Comment", { fg = c.base6, italic = true })
|
||||
hl("Underlined", { underline = true })
|
||||
hl("Ignore", {})
|
||||
hl("Error", { fg = c.red })
|
||||
hl("Terminal", { fg = c.white, bg = c.base2 })
|
||||
hl("EndOfBuffer", { fg = c.base2 })
|
||||
hl("Conceal", { fg = c.grey })
|
||||
hl("vCursor", { reverse = true })
|
||||
hl("iCursor", { reverse = true })
|
||||
hl("lCursor", { reverse = true })
|
||||
hl("CursorIM", { reverse = true })
|
||||
hl("CursorColumn", { bg = c.base3 })
|
||||
hl("Whitespace", { fg = c.base5 })
|
||||
hl("WildMenu", { fg = c.white, bg = c.orange })
|
||||
hl("QuickFixLine", { fg = c.purple, bold = true })
|
||||
hl("Debug", { fg = c.orange })
|
||||
hl("debugBreakpoint", { fg = c.base2, bg = c.red })
|
||||
hl("Conditional", { fg = c.pink })
|
||||
hl("Repeat", { fg = c.pink })
|
||||
hl("Exception", { fg = c.pink })
|
||||
|
||||
-- Plugins
|
||||
--hl("@annotation", { fg = c.green })
|
||||
--hl("@attribute", { fg = c.green })
|
||||
--hl("@boolean", { fg = c.purple })
|
||||
--hl("@character", { fg = c.yellow })
|
||||
--hl("@character.special", { fg = c.purple })
|
||||
--hl("@comment", { fg = c.base6, italic = true })
|
||||
--hl("@conceal", { fg = c.grey })
|
||||
--hl("@conditional", { fg = c.pink })
|
||||
--hl("@conditional.ternary", { fg = c.pink })
|
||||
--hl("@constant", { fg = c.aqua })
|
||||
--hl("@constant.builtin", { fg = c.purple })
|
||||
--hl("@constant.macro", { fg = c.purple })
|
||||
--hl("@constructor", { fg = c.aqua })
|
||||
--hl("@debug", { fg = c.pink })
|
||||
--hl("@define", { fg = c.aqua })
|
||||
--hl("@definition", { fg = c.green })
|
||||
--hl("@definition.associated", { fg = c.green })
|
||||
--hl("@definition.constant", { fg = c.green })
|
||||
--hl("@definition.enum", { fg = c.green })
|
||||
--hl("@definition.field", { fg = c.green })
|
||||
--hl("@definition.function", { fg = c.green })
|
||||
--hl("@definition.import", { fg = c.white })
|
||||
--hl("@definition.macro", { fg = c.green, italic = true })
|
||||
--hl("@definition.method", { fg = c.green })
|
||||
--hl("@definition.namespace", { fg = c.white })
|
||||
--hl("@definition.parameter", { fg = c.orange })
|
||||
--hl("@definition.type", { fg = c.green })
|
||||
--hl("@definition.var", { fg = c.green })
|
||||
--hl("@error", { fg = c.red })
|
||||
--hl("@exception", { fg = c.pink })
|
||||
--hl("@field", { fg = c.white })
|
||||
--hl("@float", { fg = c.purple })
|
||||
--hl("@function", { fg = c.green, italic = true })
|
||||
--hl("@function.builtin", { fg = c.aqua })
|
||||
--hl("@function.call", { fg = c.white })
|
||||
--hl("@function.macro", { fg = c.green, italic = true })
|
||||
--hl("@include", { fg = c.aqua, italic = true })
|
||||
--hl("@keyword", { fg = c.pink, italic = true })
|
||||
--hl("@keyword.function", { fg = c.aqua, italic = true })
|
||||
--hl("@keyword.operator", { fg = c.pink })
|
||||
--hl("@keyword.return", { fg = c.pink })
|
||||
--hl("@label", { fg = c.pink })
|
||||
--hl("@math", { fg = c.yellow })
|
||||
--hl("@method", { fg = c.green })
|
||||
--hl("@method.call", { fg = c.white })
|
||||
--hl("@namespace", { fg = c.purple })
|
||||
--hl("@number", { fg = c.purple })
|
||||
--hl("@operator", { fg = c.pink })
|
||||
--hl("@parameter", { fg = c.orange })
|
||||
--hl("@parameter.reference", { fg = c.white })
|
||||
--hl("@preproc", { fg = c.green })
|
||||
--hl("@property", { fg = c.white })
|
||||
--hl("@punctuation.bracket", { fg = c.white })
|
||||
--hl("@punctuation.delimiter", { fg = c.white })
|
||||
--hl("@punctuation.special", { fg = c.pink })
|
||||
--hl("@reference", { fg = c.white })
|
||||
--hl("@repeat", { fg = c.pink })
|
||||
--hl("@scope", { fg = c.white })
|
||||
--hl("@storageclass", { fg = c.aqua })
|
||||
--hl("@storageclass.lifetime", { fg = c.aqua })
|
||||
--hl("@strike", { fg = c.grey })
|
||||
--hl("@string", { fg = c.yellow })
|
||||
--hl("@string.escape", { fg = c.purple })
|
||||
--hl("@string.regex", { fg = c.purple })
|
||||
--hl("@string.special", { fg = c.purple })
|
||||
--hl("@symbol", { fg = c.purple })
|
||||
--hl("@tag", { fg = c.pink })
|
||||
--hl("@tag.attribute", { fg = c.green })
|
||||
--hl("@tag.delimiter", { fg = c.white })
|
||||
--hl("@text", { fg = c.green })
|
||||
--hl("@text.danger", { fg = c.red, bold = true })
|
||||
--hl("@text.diff.add", { fg = c.diff_add })
|
||||
--hl("@text.diff.delete", { fg = c.diff_remove })
|
||||
--hl("@text.emphasis", { bold = true })
|
||||
--hl("@text.environment", { fg = c.purple })
|
||||
--hl("@text.environment.name", { fg = c.aqua })
|
||||
--hl("@text.literal", { fg = c.yellow })
|
||||
--hl("@text.math", { fg = c.yellow })
|
||||
--hl("@text.note", { fg = c.aqua, bold = true })
|
||||
--hl("@text.quote", { fg = c.grey })
|
||||
--hl("@text.reference", { fg = c.orange, italic = true })
|
||||
--hl("@text.strike", { fg = c.grey })
|
||||
--hl("@text.strong", { bold = true })
|
||||
--hl("@text.title", { fg = c.yellow, bold = true })
|
||||
--hl("@text.todo", { fg = c.aqua })
|
||||
--hl("@text.underline", { underline = true })
|
||||
--hl("@text.uri", { fg = c.aqua, underline = true })
|
||||
--hl("@text.warning", { fg = c.yellow, bold = true })
|
||||
--hl("@todo", { fg = c.aqua })
|
||||
--hl("@type", { fg = c.aqua })
|
||||
--hl("@type.builtin", { fg = c.aqua })
|
||||
--hl("@type.definition", { fg = c.aqua })
|
||||
--hl("@type.qualifier", { fg = c.pink })
|
||||
--hl("@uri", { fg = c.aqua, underline = true })
|
||||
--hl("@variable", { fg = c.white })
|
||||
--hl("@variable.builtin", { fg = c.orange })
|
||||
--hl("dbui_tables", { fg = c.white })
|
||||
--hl("DiagnosticSignError", { fg = c.red })
|
||||
--hl("DiagnosticSignWarn", { fg = c.yellow })
|
||||
--hl("DiagnosticSignInfo", { fg = c.white })
|
||||
--hl("DiagnosticSignHint", { fg = c.aqua })
|
||||
--hl("DiagnosticVirtualTextError", { fg = c.red })
|
||||
--hl("DiagnosticVirtualTextWarn", { fg = c.yellow })
|
||||
--hl("DiagnosticVirtualTextInfo", { fg = c.white })
|
||||
--hl("DiagnosticVirtualTextHint", { fg = c.aqua })
|
||||
--hl("DiagnosticUnderlineError", { undercurl = true, sp = c.red })
|
||||
--hl("DiagnosticUnderlineWarn", { undercurl = true, sp = c.yellow })
|
||||
--hl("DiagnosticUnderlineInfo", { undercurl = true, sp = c.white })
|
||||
--hl("DiagnosticUnderlineHint", { undercurl = true, sp = c.aqua })
|
||||
--hl("CursorWord0", { bg = c.white, fg = c.black })
|
||||
--hl("CursorWord1", { bg = c.white, fg = c.black })
|
||||
--hl("NvimTreeFolderName", { fg = c.white })
|
||||
--hl("NvimTreeRootFolder", { fg = c.pink })
|
||||
--hl("NvimTreeSpecialFile", { fg = c.white })
|
|
@ -1,6 +1,7 @@
|
|||
require("boot")
|
||||
require("settings")
|
||||
require("lsp")
|
||||
require("packages")
|
||||
require("colors")
|
||||
require("keys")
|
||||
require("autocmds")
|
||||
require("usercmds")
|
||||
require("events")
|
||||
require("commands")
|
||||
require("languages")
|
|
@ -1,5 +1,5 @@
|
|||
return {
|
||||
cmd = { "clangd", "--background-index" },
|
||||
root_markers = { "meson_options.txt", "CMakePresets.json" },
|
||||
root_markers = { "meson_options.txt", "CMakePresets.json", "compile_commands.json" },
|
||||
filetypes = { "c", "cpp" },
|
||||
}
|
31
.config/nvim/lua/boot.lua
Normal file
31
.config/nvim/lua/boot.lua
Normal file
|
@ -0,0 +1,31 @@
|
|||
-- Disable providers
|
||||
local disabled_providers = {
|
||||
"node",
|
||||
"perl",
|
||||
"python3",
|
||||
"ruby",
|
||||
}
|
||||
|
||||
for _, provider in ipairs(disabled_providers) do
|
||||
vim.g["loaded_" .. provider .. "_provider"] = 0
|
||||
end
|
||||
|
||||
-- Disable plugins
|
||||
local disabled_plugins = {
|
||||
"2html_plugin",
|
||||
"ftplugin",
|
||||
"gzip",
|
||||
"man",
|
||||
"netrw",
|
||||
"matchit",
|
||||
"remote_plugins",
|
||||
"spellfile_plugin",
|
||||
"shada_plugin",
|
||||
"tarPlugin",
|
||||
"tutor_mode_plugin",
|
||||
"zipPlugin",
|
||||
}
|
||||
|
||||
for _, plugin in ipairs(disabled_plugins) do
|
||||
vim.g["loaded_" .. plugin] = 0
|
||||
end
|
1
.config/nvim/lua/colors.lua
Normal file
1
.config/nvim/lua/colors.lua
Normal file
|
@ -0,0 +1 @@
|
|||
vim.cmd("colorscheme monokai")
|
|
@ -11,6 +11,7 @@ vim.api.nvim_create_user_command("ToggleWord", function()
|
|||
["yes"] = "no",
|
||||
["Yes"] = "No",
|
||||
["YES"] = "NO",
|
||||
["y"] = "n",
|
||||
["1"] = "0",
|
||||
["<"] = ">",
|
||||
["("] = ")",
|
|
@ -1,101 +0,0 @@
|
|||
local icons = {
|
||||
Namespace = "",
|
||||
Text = "",
|
||||
Method = "",
|
||||
Function = "",
|
||||
Constructor = "",
|
||||
Field = "",
|
||||
Variable = "",
|
||||
Class = "",
|
||||
Interface = "",
|
||||
Module = "",
|
||||
Property = "",
|
||||
Unit = "",
|
||||
Value = "",
|
||||
Enum = "",
|
||||
Keyword = "",
|
||||
Snippet = "",
|
||||
Color = "",
|
||||
File = "",
|
||||
Reference = "",
|
||||
Folder = "",
|
||||
EnumMember = "",
|
||||
Constant = "",
|
||||
Struct = "",
|
||||
Event = "",
|
||||
Operator = "",
|
||||
TypeParameter = "",
|
||||
Table = "",
|
||||
Object = "",
|
||||
Tag = "",
|
||||
Array = "[]",
|
||||
Boolean = "",
|
||||
Number = "",
|
||||
Null = "",
|
||||
String = "",
|
||||
Calendar = "",
|
||||
Watch = "",
|
||||
Package = "",
|
||||
Copilot = "",
|
||||
Codeium = "",
|
||||
TabNine = "",
|
||||
}
|
||||
|
||||
return {
|
||||
"hrsh7th/nvim-cmp",
|
||||
event = "InsertEnter",
|
||||
dependencies = {
|
||||
-- "hrsh7th/cmp-nvim-lsp",
|
||||
-- "hrsh7th/cmp-buffer",
|
||||
-- "hrsh7th/cmp-path",
|
||||
-- "L3MON4D3/LuaSnip",
|
||||
},
|
||||
opts = {
|
||||
completion = {
|
||||
autocomplete = true,
|
||||
completeopt = "menu,menuone,noinsert",
|
||||
},
|
||||
formatting = {
|
||||
fields = { "abbr", "kind", "menu" },
|
||||
format = function(_, item)
|
||||
local icon = icons[item.kind] or ""
|
||||
item.kind = string.format(" %s %s", icon, item.kind)
|
||||
return item
|
||||
end,
|
||||
},
|
||||
-- snippet = {
|
||||
-- expand = function(args)
|
||||
-- require("luasnip").lsp_expand(args.body)
|
||||
-- end,
|
||||
-- },
|
||||
-- preselect = cmp.PreselectMode.None,
|
||||
sources = {
|
||||
-- { name = "nvim_lsp" },
|
||||
-- { name = "luasnip" },
|
||||
{ name = "buffer" },
|
||||
-- { name = "path" },
|
||||
},
|
||||
window = {
|
||||
completion = {
|
||||
border = "rounded",
|
||||
scrollbar = false,
|
||||
},
|
||||
documentation = {
|
||||
border = "rounded",
|
||||
}
|
||||
},
|
||||
},
|
||||
config = function(_, opts)
|
||||
local cmp = require("cmp")
|
||||
|
||||
opts.mapping = {
|
||||
["<C-space>"] = cmp.mapping.complete(),
|
||||
["<C-up>"] = cmp.mapping.select_prev_item(),
|
||||
["<C-down>"] = cmp.mapping.select_next_item(),
|
||||
["<C-x>"] = cmp.mapping.abort(),
|
||||
["<cr>"] = cmp.mapping.confirm({ select = true }),
|
||||
}
|
||||
|
||||
cmp.setup(opts)
|
||||
end,
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
return {
|
||||
"j-hui/fidget.nvim",
|
||||
opts = {
|
||||
integration = {
|
||||
["nvim-tree"] = {
|
||||
enable = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,15 +0,0 @@
|
|||
return {
|
||||
"lukas-reineke/indent-blankline.nvim",
|
||||
event = "VeryLazy",
|
||||
main = "ibl",
|
||||
opts = {
|
||||
indent = {
|
||||
char = "▏",
|
||||
},
|
||||
scope = {
|
||||
enabled = true,
|
||||
show_start = false,
|
||||
},
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,4 +0,0 @@
|
|||
return {
|
||||
"mrded/nvim-lsp-notify",
|
||||
config = true,
|
||||
}
|
|
@ -1,103 +0,0 @@
|
|||
return {
|
||||
"neovim/nvim-lspconfig",
|
||||
event = { "BufReadPre", "BufNewFile" },
|
||||
opts = {
|
||||
servers = {
|
||||
clangd = {},
|
||||
gdscript = {},
|
||||
gopls = {},
|
||||
lua_ls = {
|
||||
settings = {
|
||||
Lua = {
|
||||
completion = {
|
||||
callSnippet = "Replace",
|
||||
},
|
||||
runtime = {
|
||||
version = "LuaJIT",
|
||||
},
|
||||
workspace = {
|
||||
checkThirdParty = false,
|
||||
library = {
|
||||
"${3rd}/luv/library",
|
||||
unpack(vim.api.nvim_get_runtime_file("", true)),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
rust_analyzer = {
|
||||
settings = {
|
||||
["rust-analyzer"] = {
|
||||
imports = {
|
||||
granularity = {
|
||||
group = "module",
|
||||
},
|
||||
prefix = "self",
|
||||
},
|
||||
cargo = {
|
||||
buildScripts = {
|
||||
enable = true,
|
||||
},
|
||||
},
|
||||
procMacro = {
|
||||
enable = true
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
config = function(_, opts)
|
||||
-- Servers
|
||||
local servers = opts.servers
|
||||
|
||||
for server, server_opts in pairs(servers) do
|
||||
require("lspconfig")[server].setup(server_opts)
|
||||
end
|
||||
|
||||
-- Icons
|
||||
local icons = {
|
||||
Error = " ",
|
||||
Warn = " ",
|
||||
Hint = " ",
|
||||
Info = " ",
|
||||
}
|
||||
|
||||
for name, icon in pairs(icons) do
|
||||
name = "DiagnosticSign" .. name
|
||||
vim.fn.sign_define(name, { text = icon, texthl = name, numhl = "" })
|
||||
end
|
||||
|
||||
-- Runs when the LSP is attached
|
||||
vim.api.nvim_create_autocmd("LspAttach", {
|
||||
group = vim.api.nvim_create_augroup("lsp-attach", { clear = true }),
|
||||
callback = function(event)
|
||||
local function map(mode, lhs, rhs, info)
|
||||
vim.keymap.set(mode, lhs, rhs, { buffer = event.buf, desc = "LSP: " .. info })
|
||||
end
|
||||
|
||||
map("n", "gr", require("telescope.builtin").lsp_references, "References")
|
||||
map("n", "gd", require("telescope.builtin").lsp_definitions, "Definition")
|
||||
map({ "n", "i" }, "<f1>", vim.lsp.buf.hover, "Hover")
|
||||
map({ "n", "i" }, "<f2>", vim.lsp.buf.rename, "Rename")
|
||||
map({ "n", "i" }, "<C-f>", vim.lsp.buf.format, "Format")
|
||||
map("n", "<leader>ca", vim.lsp.buf.code_action, "Code action")
|
||||
|
||||
-- Highlight the word your cursor is on
|
||||
-- local client = vim.lsp.get_client_by_id(event.data.client_id)
|
||||
--
|
||||
-- if client and client.server_capabilities.documentHighlightProvider then
|
||||
-- vim.api.nvim_create_autocmd({ "CursorHold", "CursorHoldI" }, {
|
||||
-- buffer = event.buf,
|
||||
-- callback = vim.lsp.buf.document_highlight,
|
||||
-- })
|
||||
--
|
||||
-- vim.api.nvim_create_autocmd({ "CursorMoved", "CursorMovedI" }, {
|
||||
-- buffer = event.buf,
|
||||
-- callback = vim.lsp.buf.clear_references,
|
||||
-- })
|
||||
-- end
|
||||
end,
|
||||
})
|
||||
end,
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
return {
|
||||
"L3MON4D3/LuaSnip",
|
||||
dependencies = {
|
||||
"rafamadriz/friendly-snippets"
|
||||
},
|
||||
event = "InsertEnter",
|
||||
version = "v2.*",
|
||||
config = function()
|
||||
require("luasnip.loaders.from_vscode").lazy_load()
|
||||
end,
|
||||
}
|
|
@ -1,8 +0,0 @@
|
|||
return {
|
||||
"echasnovski/mini.completion",
|
||||
event = "InsertEnter",
|
||||
opts = {
|
||||
set_vim_settings = false,
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,18 +0,0 @@
|
|||
return {
|
||||
"echasnovski/mini.surround",
|
||||
event = { "BufReadPost", "BufNewFile" },
|
||||
opts = {
|
||||
mappings = {
|
||||
add = 'gsa',
|
||||
delete = 'gsd',
|
||||
find = 'gsf',
|
||||
find_left = 'gsF',
|
||||
highlight = 'gsh',
|
||||
replace = 'gsr',
|
||||
update_n_lines = 'gsn',
|
||||
suffix_last = '',
|
||||
suffix_next = '',
|
||||
},
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,14 +0,0 @@
|
|||
return {
|
||||
"mg979/vim-visual-multi",
|
||||
keys = {
|
||||
{ "<C-d>", mode = { "n", "x" }, desc = "Multicursor (word)" },
|
||||
{ "<C-Up>", mode = { "n", "x" }, desc = "Multicursor (next line)" },
|
||||
{ "<C-Down>", mode = { "n", "x" }, desc = "Multicursor (previous line)" },
|
||||
},
|
||||
init = function()
|
||||
vim.g.VM_maps = {
|
||||
["Find Under"] = "<C-d>",
|
||||
["Find Subword Under"] = "<C-d>",
|
||||
}
|
||||
end,
|
||||
}
|
|
@ -1,17 +0,0 @@
|
|||
return {
|
||||
"folke/noice.nvim",
|
||||
event = "VeryLazy",
|
||||
dependencies = {
|
||||
"MunifTanjim/nui.nvim",
|
||||
},
|
||||
opts = {
|
||||
lsp = {
|
||||
override = {
|
||||
["vim.lsp.util.convert_input_to_markdown_lines"] = true,
|
||||
["vim.lsp.util.stylize_markdown"] = true,
|
||||
["cmp.entry.get_documentation"] = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
return {
|
||||
"rcarriga/nvim-notify",
|
||||
event = "VeryLazy",
|
||||
opts = {
|
||||
background_colour = "#000000",
|
||||
fps = 60,
|
||||
render = "compact",
|
||||
timeout = 0,
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,7 +0,0 @@
|
|||
return {
|
||||
"NvChad/nvterm",
|
||||
keys = {
|
||||
{ "<A-i>", "<cmd>lua require('nvterm.terminal').toggle('float')<cr>", mode = { "n", "t" }, desc = "Toggle terminal" },
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,19 +0,0 @@
|
|||
return {
|
||||
"navarasu/onedark.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
opts = {
|
||||
style = "dark",
|
||||
transparent = true,
|
||||
term_colors = true,
|
||||
highlights = {
|
||||
["StatusLine"] = {fg = "$bg3", bg = "Normal"},
|
||||
["StatusLineNC"] = {fg = "$bg3", bg = "Normal"},
|
||||
},
|
||||
},
|
||||
config = function(_, opts)
|
||||
local theme = require("onedark")
|
||||
theme.setup(opts)
|
||||
theme.load()
|
||||
end,
|
||||
}
|
|
@ -1,10 +0,0 @@
|
|||
return {
|
||||
"folke/snacks.nvim",
|
||||
event = "BufReadPre",
|
||||
opts = {
|
||||
explorer = {
|
||||
replace_netrw = true,
|
||||
},
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,7 +0,0 @@
|
|||
return {
|
||||
"nvim-pack/nvim-spectre",
|
||||
keys = {
|
||||
{ "<leader>sr", function() require("spectre").open() end, desc = "Replace in files (Spectre)" },
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,73 +0,0 @@
|
|||
local function on_attach(bufnr)
|
||||
local api = require("nvim-tree.api")
|
||||
|
||||
-- default mappings
|
||||
api.config.mappings.default_on_attach(bufnr)
|
||||
|
||||
local function opts(desc)
|
||||
return { desc = "nvim-tree: " .. desc, buffer = bufnr, noremap = true, silent = true, nowait = true }
|
||||
end
|
||||
|
||||
-- navigation
|
||||
vim.keymap.set("n", "<C-Up>", api.tree.change_root_to_parent, opts("Up"))
|
||||
vim.keymap.set("n", "<C-Left>", api.tree.change_root_to_parent, opts("Up"))
|
||||
vim.keymap.set("n", "<C-Down>", api.tree.change_root_to_node, opts("Enter"))
|
||||
vim.keymap.set("n", "<C-Right>", api.tree.change_root_to_node, opts("Enter"))
|
||||
|
||||
-- open folders with a single click
|
||||
vim.keymap.set("n", "<LeftRelease>", function()
|
||||
vim.defer_fn(function ()
|
||||
local win = vim.api.nvim_get_current_win()
|
||||
local view = require("nvim-tree.view")
|
||||
if view.get_winnr() ~= win then return end
|
||||
|
||||
api.node.open.edit()
|
||||
api.tree.focus()
|
||||
end, 10)
|
||||
end, opts("Open folder/file"))
|
||||
end
|
||||
|
||||
return {
|
||||
"nvim-tree/nvim-tree.lua",
|
||||
event = "VeryLazy",
|
||||
dependencies = {
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
},
|
||||
keys = {
|
||||
{ "<leader>e", function() require("nvim-tree.api").tree.toggle() end, desc = "Toggle files" },
|
||||
},
|
||||
opts = {
|
||||
filesystem_watchers = {
|
||||
enable = true,
|
||||
},
|
||||
filters = {
|
||||
dotfiles = false,
|
||||
},
|
||||
on_attach = on_attach,
|
||||
renderer = {
|
||||
root_folder_label = false,
|
||||
highlight_git = true,
|
||||
icons = {
|
||||
show = {
|
||||
git = false,
|
||||
},
|
||||
glyphs = {
|
||||
git = {
|
||||
unstaged = "",
|
||||
untracked = "",
|
||||
deleted = "",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
sync_root_with_cwd = true,
|
||||
update_focused_file = {
|
||||
enable = true,
|
||||
update_root = false,
|
||||
},
|
||||
view = {
|
||||
width = 30,
|
||||
},
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,16 +0,0 @@
|
|||
return {
|
||||
"folke/trouble.nvim",
|
||||
event = "VeryLazy",
|
||||
keys = {
|
||||
{ "<leader>x", function() require("trouble").toggle() end, desc = "Show errors" },
|
||||
},
|
||||
dependencies = {
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
},
|
||||
opts = {
|
||||
position = "right",
|
||||
padding = false,
|
||||
use_diagnostic_signs = true,
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,35 +1,18 @@
|
|||
local on = vim.api.nvim_create_autocmd
|
||||
local group = vim.api.nvim_create_augroup("autocmds", {clear = true})
|
||||
|
||||
on({ "BufNewFile", "BufRead" }, {
|
||||
desc = "Enable word wrap in text files and markdown documents",
|
||||
group = group,
|
||||
pattern = { "*.txt", "*.md" },
|
||||
callback = function()
|
||||
vim.opt_local.wrap = true
|
||||
vim.opt_local.signcolumn = "no"
|
||||
end,
|
||||
})
|
||||
|
||||
on({ "LspAttach" }, {
|
||||
desc = "LSP completion",
|
||||
group = group,
|
||||
callback = function(ev)
|
||||
local client = vim.lsp.get_client_by_id(ev.data.client_id)
|
||||
|
||||
if client:supports_method("textDocument/completion") then
|
||||
vim.lsp.completion.enable(true, client.id, ev.buf, { autotrigger = true })
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
||||
on({ "TermOpen", "TermEnter" }, {
|
||||
desc = "Disable sign column in terminals",
|
||||
group = group,
|
||||
callback = function()
|
||||
vim.opt_local.signcolumn = "no"
|
||||
end,
|
||||
})
|
||||
|
||||
on({ "TextYankPost" }, {
|
||||
desc = "Highlight when copying text",
|
||||
group = group,
|
||||
|
@ -38,33 +21,20 @@ on({ "TextYankPost" }, {
|
|||
end,
|
||||
})
|
||||
|
||||
on({ "VimEnter" }, {
|
||||
desc = "Allow opening a directory and jumping to project root",
|
||||
on({ "BufNewFile", "BufRead" }, {
|
||||
desc = "Enable word wrap in text files and markdown documents",
|
||||
group = group,
|
||||
pattern = { "*.txt", "*.md" },
|
||||
callback = function()
|
||||
-- Change file to its directory if needed
|
||||
local name = vim.api.nvim_buf_get_name(0)
|
||||
local is_directory = vim.fn.isdirectory(name)
|
||||
|
||||
if is_directory == 0 then
|
||||
name = vim.fs.dirname(name)
|
||||
end
|
||||
|
||||
-- Switch to root directory of the project
|
||||
local root_patterns = { ".git", "go.mod", "init.lua" }
|
||||
local root_dir = vim.fs.dirname(vim.fs.find(root_patterns, {
|
||||
upward = true,
|
||||
path = name,
|
||||
})[1])
|
||||
|
||||
if root_dir then
|
||||
vim.api.nvim_set_current_dir(root_dir)
|
||||
else
|
||||
vim.api.nvim_set_current_dir(name)
|
||||
end
|
||||
|
||||
if is_directory ~= 0 then
|
||||
require("telescope.builtin").find_files()
|
||||
end
|
||||
vim.opt_local.wrap = true
|
||||
vim.opt_local.signcolumn = "no"
|
||||
end,
|
||||
})
|
||||
|
||||
on({ "TermOpen", "TermEnter" }, {
|
||||
desc = "Disable sign column in terminals",
|
||||
group = group,
|
||||
callback = function()
|
||||
vim.opt_local.signcolumn = "no"
|
||||
end,
|
||||
})
|
|
@ -1,43 +1,40 @@
|
|||
vim.g.mapleader = " "
|
||||
|
||||
local function map(mode, lhs, rhs, info)
|
||||
vim.keymap.set(mode, lhs, rhs, { desc = info })
|
||||
end
|
||||
|
||||
-- Enter command mode without pressing shift
|
||||
map("n", ";", ":", "Command mode")
|
||||
|
||||
-- Undo with u, Redo with U
|
||||
map("n", "U", "<cmd>redo<cr>", "Redo")
|
||||
map("n", "<Bslash>", "<cmd>ToggleWord<cr>", "Toggle word")
|
||||
map("n", "<C-q>", "<cmd>close<cr>", "Close window")
|
||||
map("n", "<leader>l", "<cmd>Lazy<cr>", "Lazy")
|
||||
|
||||
-- Quit with q like any other terminal app
|
||||
map({"n", "v"}, "q", "<cmd>qa<cr>", "Quit all")
|
||||
map({"n", "v"}, "<leader>q", "<cmd>qa!<cr>", "Quit all")
|
||||
map({"n", "v"}, "Q", "<cmd>qa!<cr>", "Force quit")
|
||||
|
||||
-- Clear search with Esc
|
||||
map({"n", "i"}, "<esc>", "<cmd>noh<cr><esc>", "Clear search")
|
||||
|
||||
-- Ctrl S to save the file from any mode
|
||||
map({"n", "i", "s", "v"}, "<C-s>", "<cmd>w<cr><esc>", "Save file")
|
||||
|
||||
-- Add or delete empty lines
|
||||
-- Grab the line and move it up/down
|
||||
map("n", "<C-j>", "<cmd>set paste<cr>m`O<esc>``<cmd>set nopaste<cr>", "Add empty line above")
|
||||
map("n", "<C-k>", "m`<cmd>-g/\\m^\\s*$/d<cr>``<cmd>noh<cr>", "Delete empty line above")
|
||||
|
||||
-- Grab the line below and move it up/down
|
||||
map("n", "<A-j>", "<cmd>set paste<cr>m`o<esc>``<cmd>set nopaste<cr>", "Add empty line below")
|
||||
map("n", "<A-k>", "m`<cmd>+g/\\m^\\s*$/d<cr>``<cmd>noh<cr>", "Delete empty line below")
|
||||
|
||||
-- Quick movement
|
||||
map("n", "J", "}", "Next paragraph")
|
||||
map("n", "K", "{", "Previous paragraph")
|
||||
-- Horizontal movement
|
||||
map({"n", "v"}, "H", "^", "Beginning of line")
|
||||
map({"n", "v"}, "L", "<end>", "End of line")
|
||||
|
||||
-- Editing multiple instances
|
||||
map("n", "<f2>", "*#:%s//<C-r><C-w>/g<left><left>", "Replace word under cursor")
|
||||
map("v", "<f2>", "y/<C-r>\"<cr>N:%s//<C-r>\"/g<left><left>", "Replace selection")
|
||||
map("n", "<f3>", "#*", "Search word under cursor")
|
||||
map("v", "<f3>", "y/<C-r>\"<cr>N", "Search selection")
|
||||
|
||||
-- Line movement
|
||||
map({"n", "v"}, "<C-b>", "^", "Beginning of line")
|
||||
map("i", "<C-b>", "<esc>^i", "Beginning of line")
|
||||
map({"i", "n", "v"}, "<C-e>", "<end>", "End of line")
|
||||
|
||||
-- Increasing and decreasing numbers
|
||||
map("n", "+", "<C-a>", "Increase number")
|
||||
map("n", "-", "<C-x>", "Decrease number")
|
||||
map("n", "<kPlus>", "<C-a>", "Increase number")
|
||||
map("n", "<kMinus>", "<C-x>", "Decrease number")
|
||||
-- Vertical movement
|
||||
map({"n", "v"}, "J", "}", "Next paragraph")
|
||||
map({"n", "v"}, "K", "{", "Previous paragraph")
|
||||
|
||||
-- Indenting
|
||||
map("n", "<Tab>", "V>gv<esc>")
|
||||
|
@ -45,24 +42,26 @@ map("n", "<S-Tab>", "V<gv<esc>")
|
|||
map("v", "<Tab>", ">gv")
|
||||
map("v", "<S-Tab>", "<gv")
|
||||
|
||||
-- Shift arrow selection
|
||||
map("n", "<S-Up>", "v<Up>")
|
||||
map("n", "<S-Down>", "v<Down>")
|
||||
map("n", "<S-Left>", "v<Left>")
|
||||
map("n", "<S-Right>", "v<Right>")
|
||||
-- Toggle word
|
||||
map("n", "<Bslash>", "<cmd>ToggleWord<cr>", "Toggle word")
|
||||
|
||||
map("v", "<S-Up>", "<Up>")
|
||||
map("v", "<S-Down>", "<Down>")
|
||||
map("v", "<S-Left>", "<Left>")
|
||||
map("v", "<S-Right>", "<Right>")
|
||||
-- Increasing and decreasing numbers
|
||||
map("n", "+", "<C-a>", "Increase number")
|
||||
map("n", "-", "<C-x>", "Decrease number")
|
||||
map("n", "<kPlus>", "<C-a>", "Increase number")
|
||||
map("n", "<kMinus>", "<C-x>", "Decrease number")
|
||||
|
||||
map("i", "<S-Up>", "<Esc>v<Up>")
|
||||
map("i", "<S-Down>", "<Esc>v<Down>")
|
||||
map("i", "<S-Left>", "<Esc>v<Left>")
|
||||
map("i", "<S-Right>", "<Esc>v<Right>")
|
||||
-- Replace all instances
|
||||
map("n", "<f2>", "*#:%s//<C-r><C-w>/g<left><left>", "Replace word under cursor")
|
||||
map("v", "<f2>", "y/<C-r>\"<cr>N:%s//<C-r>\"/g<left><left>", "Replace selection")
|
||||
|
||||
-- Window switching
|
||||
-- Search all instances
|
||||
map("n", "<f3>", "#*", "Search word under cursor")
|
||||
map("v", "<f3>", "y/<C-r>\"<cr>N", "Search selection")
|
||||
|
||||
-- Window management
|
||||
map("n", "<A-Up>", "<C-w>k", "Move to the window above")
|
||||
map("n", "<A-Down>", "<C-w>j", "Move to the window below")
|
||||
map("n", "<A-Left>", "<C-w>h", "Move to the window on the left")
|
||||
map("n", "<A-Right>", "<C-w>l", "Move to the window on the right")
|
||||
map("n", "<A-q>", "<cmd>close<cr>", "Close window")
|
|
@ -1,7 +1,9 @@
|
|||
-- Virtual text
|
||||
vim.diagnostic.config({
|
||||
virtual_lines = true,
|
||||
})
|
||||
|
||||
-- LSP
|
||||
vim.lsp.enable({
|
||||
"clangd",
|
||||
"gopls",
|
|
@ -1,69 +0,0 @@
|
|||
-- Install the package manager if needed
|
||||
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
||||
|
||||
if not vim.loop.fs_stat(lazypath) then
|
||||
vim.fn.system({
|
||||
"git",
|
||||
"clone",
|
||||
"--filter=blob:none",
|
||||
"https://github.com/folke/lazy.nvim.git",
|
||||
"--branch=stable",
|
||||
lazypath,
|
||||
})
|
||||
end
|
||||
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
-- Load plugins
|
||||
require("lazy").setup("plugins", {
|
||||
defaults = {
|
||||
lazy = true,
|
||||
},
|
||||
change_detection = {
|
||||
notify = false
|
||||
},
|
||||
rocks = {
|
||||
enabled = false
|
||||
},
|
||||
ui = {
|
||||
icons = {
|
||||
ft = "",
|
||||
lazy = " ",
|
||||
loaded = "",
|
||||
not_loaded = "",
|
||||
},
|
||||
},
|
||||
performance = {
|
||||
rtp = {
|
||||
disabled_plugins = {
|
||||
"2html_plugin",
|
||||
"tohtml",
|
||||
"getscript",
|
||||
"getscriptPlugin",
|
||||
"gzip",
|
||||
"logipat",
|
||||
"netrw",
|
||||
"netrwPlugin",
|
||||
"netrwSettings",
|
||||
"netrwFileHandlers",
|
||||
"matchit",
|
||||
"tar",
|
||||
"tarPlugin",
|
||||
"rrhelper",
|
||||
"spellfile_plugin",
|
||||
"vimball",
|
||||
"vimballPlugin",
|
||||
"zip",
|
||||
"zipPlugin",
|
||||
"tutor",
|
||||
"rplugin",
|
||||
"syntax",
|
||||
"synmenu",
|
||||
"optwin",
|
||||
"compiler",
|
||||
"bugreport",
|
||||
"ftplugin",
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
|
@ -1,5 +0,0 @@
|
|||
return {
|
||||
"windwp/nvim-autopairs",
|
||||
event = "InsertEnter",
|
||||
config = true,
|
||||
}
|
|
@ -1,23 +0,0 @@
|
|||
return {
|
||||
"numToStr/Comment.nvim",
|
||||
keys = {
|
||||
{
|
||||
"<C-/>",
|
||||
"<cmd>lua require('Comment.api').toggle.linewise.current()<cr>",
|
||||
desc = "Toggle comment",
|
||||
},
|
||||
{
|
||||
"<C-/>",
|
||||
"<esc><cmd>lua require('Comment.api').toggle.linewise(vim.fn.visualmode())<cr>",
|
||||
mode = "v",
|
||||
desc = "Toggle comment",
|
||||
},
|
||||
},
|
||||
config = true,
|
||||
opts = {
|
||||
mappings = {
|
||||
basic = false,
|
||||
extra = false,
|
||||
},
|
||||
},
|
||||
}
|
|
@ -1,9 +0,0 @@
|
|||
return {
|
||||
"folke/flash.nvim",
|
||||
event = { "BufReadPost", "BufNewFile" },
|
||||
keys = {
|
||||
{ "s", function() require("flash").jump() end, mode = { "n", "o", "x" }, desc = "Flash" },
|
||||
{ "S", function() require("flash").treesitter() end, mode = { "n", "o", "x" }, desc = "Flash Treesitter" },
|
||||
},
|
||||
config = true,
|
||||
}
|
|
@ -1,5 +0,0 @@
|
|||
return {
|
||||
"lewis6991/gitsigns.nvim",
|
||||
event = "BufReadPre",
|
||||
config = true,
|
||||
}
|
|
@ -1,7 +0,0 @@
|
|||
return {
|
||||
"tanvirtin/monokai.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
opts = {},
|
||||
config = true,
|
||||
}
|
|
@ -1,36 +0,0 @@
|
|||
return {
|
||||
"nvim-telescope/telescope.nvim",
|
||||
dependencies = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
"nvim-telescope/telescope-project.nvim",
|
||||
},
|
||||
keys = {
|
||||
{"<C-Tab>", "<cmd>Telescope buffers<cr>", desc = "Buffers"},
|
||||
{"<leader>f", "<cmd>Telescope find_files<cr>", desc = "Find files"},
|
||||
{"<leader>p", "<cmd>Telescope project<cr>", desc = "Projects"},
|
||||
{"<leader>r", "<cmd>Telescope oldfiles<cr>", desc = "Recent files"},
|
||||
},
|
||||
config = function()
|
||||
require("telescope").setup({
|
||||
defaults = {
|
||||
mappings = {
|
||||
i = {
|
||||
["<esc>"] = require("telescope.actions").close,
|
||||
},
|
||||
},
|
||||
prompt_prefix = " ",
|
||||
selection_caret = " ",
|
||||
},
|
||||
extensions = {
|
||||
project = {
|
||||
base_dirs = {
|
||||
{ path = "~/projects", max_depth = 3 },
|
||||
},
|
||||
order_by = "desc",
|
||||
sync_with_nvim_tree = true,
|
||||
theme = "dropdown",
|
||||
},
|
||||
},
|
||||
})
|
||||
end,
|
||||
}
|
|
@ -1,18 +0,0 @@
|
|||
return {
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
event = { "BufReadPost", "BufNewFile" },
|
||||
build = ":TSUpdate",
|
||||
opts = {
|
||||
ensure_installed = {
|
||||
"go",
|
||||
"gomod",
|
||||
"gowork",
|
||||
"gosum",
|
||||
},
|
||||
highlight = { enable = true },
|
||||
indent = { enable = true },
|
||||
},
|
||||
config = function(_, opts)
|
||||
require("nvim-treesitter.configs").setup(opts)
|
||||
end,
|
||||
}
|
|
@ -1,11 +1,3 @@
|
|||
-- Globals
|
||||
local g = vim.g
|
||||
g.mapleader = " "
|
||||
|
||||
for _, provider in ipairs { "node", "perl", "python3", "ruby" } do
|
||||
g["loaded_" .. provider .. "_provider"] = 0
|
||||
end
|
||||
|
||||
-- Options
|
||||
local opt = vim.opt
|
||||
opt.autowrite = false
|
||||
|
@ -52,7 +44,3 @@ opt.statusline = "%{repeat('─',winwidth('.'))}"
|
|||
-- Undo
|
||||
opt.undofile = true
|
||||
opt.undolevels = 10000
|
||||
|
||||
-- Virtual text
|
||||
vim.diagnostic.config({ virtual_lines = true })
|
||||
vim.lsp.enable({"clangd", "gopls", "rust-analyzer"})
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"layer": "top",
|
||||
"position": "top",
|
||||
"modules-left": ["cpu", "custom/gpu", "memory", "disk"],
|
||||
"modules-left": ["cpu", "memory", "disk"],
|
||||
"modules-center": ["hyprland/workspaces"],
|
||||
"modules-right": ["wireplumber", "clock"],
|
||||
"include": "~/.config/waybar/modules.jsonc",
|
||||
|
|
|
@ -1,9 +1,52 @@
|
|||
{
|
||||
"cpu": {
|
||||
"interval": 2,
|
||||
"format": "{icon} {usage}%",
|
||||
"format-icons": [" ", " ", " "],
|
||||
"on-click": "$TERMINAL -- btop",
|
||||
"format": " {usage}%",
|
||||
"on-click": "$TERMINAL -- btop --preset 1",
|
||||
},
|
||||
"memory": {
|
||||
"interval": 2,
|
||||
"format": " {used} G",
|
||||
"on-click": "$TERMINAL -- btop --preset 2",
|
||||
},
|
||||
"disk": {
|
||||
"interval": 30,
|
||||
"format": " {specific_used:0.0f} G",
|
||||
"path": "/",
|
||||
"unit": "GiB",
|
||||
"on-click": "$TERMINAL -- nnn -Td /",
|
||||
},
|
||||
"hyprland/workspaces": {
|
||||
"format": "{icon}",
|
||||
"persistent-workspaces": {
|
||||
"*": 9
|
||||
},
|
||||
"format-icons": {
|
||||
"default": " ",
|
||||
"empty": " ",
|
||||
"active": " ",
|
||||
"urgent": " ",
|
||||
},
|
||||
"sort-by-number": true,
|
||||
"on-click": "activate",
|
||||
},
|
||||
"wireplumber": {
|
||||
"format": "{icon} {volume}%",
|
||||
"format-muted": " ",
|
||||
"format-icons": [" ", " ", " "],
|
||||
"scroll-step": 2,
|
||||
"on-click": "easyeffects",
|
||||
},
|
||||
"clock": {
|
||||
"interval": 60,
|
||||
"format": " {:%H:%M}",
|
||||
"tooltip-format": "<tt>{calendar}</tt>",
|
||||
"calendar": {
|
||||
"format": {
|
||||
"today": "<span color='#fAfBfC'><b>{}</b></span>"
|
||||
}
|
||||
},
|
||||
"on-click": "date -u +'%Y-%m-%dT%H:%M:%SZ' | wl-copy",
|
||||
},
|
||||
"custom/gpu": {
|
||||
"interval": 2,
|
||||
|
@ -12,18 +55,6 @@
|
|||
"return-type": "",
|
||||
"on-click": "$TERMINAL -- nvtop",
|
||||
},
|
||||
"memory": {
|
||||
"interval": 2,
|
||||
"format": " {used} G",
|
||||
"on-click": "$TERMINAL -- btop",
|
||||
},
|
||||
"disk": {
|
||||
"interval": 30,
|
||||
"format": " {specific_used:0.0f} G",
|
||||
"path": "/",
|
||||
"unit": "GiB",
|
||||
"on-click": "$TERMINAL -- dua i /",
|
||||
},
|
||||
"custom/pacman": {
|
||||
"format": " {}",
|
||||
"interval": 30,
|
||||
|
@ -57,36 +88,4 @@
|
|||
"tooltip-format": "Number of processes with UDP connections",
|
||||
"on-click": "$TERMINAL -- bandwhich",
|
||||
},
|
||||
"hyprland/workspaces": {
|
||||
"format": "{icon}",
|
||||
"persistent-workspaces": {
|
||||
"*": 9
|
||||
},
|
||||
"format-icons": {
|
||||
"default": " ",
|
||||
"empty": " ",
|
||||
"active": " ",
|
||||
"urgent": " ",
|
||||
},
|
||||
"sort-by-number": true,
|
||||
"on-click": "activate",
|
||||
},
|
||||
"wireplumber": {
|
||||
"format": "{icon} {volume}%",
|
||||
"format-muted": " ",
|
||||
"format-icons": [" ", " ", " "],
|
||||
"scroll-step": 5,
|
||||
"on-click": "easyeffects",
|
||||
},
|
||||
"clock": {
|
||||
"interval": 60,
|
||||
"format": " {:%H:%M}",
|
||||
"tooltip-format": "<tt>{calendar}</tt>",
|
||||
"calendar": {
|
||||
"format": {
|
||||
"today": "<span color='#fAfBfC'><b>{}</b></span>"
|
||||
}
|
||||
},
|
||||
"on-click": "date -u +'%Y-%m-%dT%H:%M:%SZ' | wl-copy",
|
||||
},
|
||||
}
|
|
@ -6,13 +6,13 @@
|
|||
}
|
||||
{
|
||||
"label" : "shutdown",
|
||||
"action" : "systemctl poweroff",
|
||||
"action" : "doas poweroff",
|
||||
"text" : "Shutdown",
|
||||
"keybind" : "s"
|
||||
}
|
||||
{
|
||||
"label" : "reboot",
|
||||
"action" : "systemctl reboot",
|
||||
"action" : "doas reboot",
|
||||
"text" : "Reboot",
|
||||
"keybind" : "r"
|
||||
}
|
||||
|
|
|
@ -1,4 +0,0 @@
|
|||
[[manager.prepend_keymap]]
|
||||
on = [ "<C-s>" ]
|
||||
run = 'shell "$SHELL" --block --confirm'
|
||||
desc = "Open shell here"
|
|
@ -1,2 +0,0 @@
|
|||
[manager]
|
||||
show_hidden = true
|
32
.env
Normal file
32
.env
Normal file
|
@ -0,0 +1,32 @@
|
|||
XDG_CACHE_HOME=$HOME/.cache
|
||||
XDG_CONFIG_HOME=$HOME/.config
|
||||
XDG_DATA_HOME=$HOME/.local/share
|
||||
XDG_BIN_HOME=$HOME/.local/bin
|
||||
XDG_LIB_HOME=$HOME/.local/lib
|
||||
XDG_STATE_HOME=$HOME/.local/state
|
||||
CARGO_HOME=$XDG_DATA_HOME/cargo
|
||||
CUDA_CACHE_PATH=$XDG_CACHE_HOME/nv
|
||||
DOTNET_CLI_HOME=$XDG_DATA_HOME/dotnet
|
||||
GOPATH=$XDG_DATA_HOME/go
|
||||
GTK2_RC_FILES=$XDG_CONFIG_HOME/gtk-2.0/gtkrc
|
||||
HISTFILE=$XDG_STATE_HOME/bash/history
|
||||
NIMBLE_DIR=$XDG_DATA_HOME/nimble
|
||||
NUGET_PACKAGES=$XDG_CACHE_HOME/nuget
|
||||
RUSTUP_HOME=$XDG_DATA_HOME/rustup
|
||||
W3M_DIR=$XDG_DATA_HOME/w3m
|
||||
WINEPREFIX=$XDG_DATA_HOME/wine
|
||||
GOAMD64=v3
|
||||
GOARM64=v8.2
|
||||
BROWSER=firefox
|
||||
EDITOR=nvim
|
||||
VISUAL=$EDITOR
|
||||
LANG=en_US.UTF-8
|
||||
PAGER=less
|
||||
SSH_AUTH_SOCK=$XDG_RUNTIME_DIR/ssh-agent.socket
|
||||
TERMINAL=foot
|
||||
PATH="/usr/sbin:/usr/bin:/sbin:/bin"
|
||||
PATH="/usr/lib/ccache/bin:$PATH"
|
||||
PATH="$GOPATH/bin:$PATH"
|
||||
PATH="$CARGO_HOME/bin:$PATH"
|
||||
PATH="$XDG_BIN_HOME:$PATH"
|
||||
PATH="$XDG_CONFIG_HOME/fish/scripts:$PATH"
|
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -6,13 +6,13 @@ lazy-lock.json
|
|||
!.editorconfig
|
||||
!.gitignore
|
||||
!.init
|
||||
!.env
|
||||
!/.config
|
||||
/.config/*
|
||||
!/.config/alacritty
|
||||
!/.config/btop
|
||||
!/.config/cava
|
||||
!/.config/easyeffects
|
||||
!/.config/environment.d
|
||||
!/.config/fastfetch
|
||||
!/.config/foot
|
||||
!/.config/fish
|
||||
|
|
4
.init
4
.init
|
@ -1,2 +1,2 @@
|
|||
#!/bin/fish
|
||||
uwsm start hyprland.desktop
|
||||
#!/usr/bin/fish
|
||||
dbus-run-session Hyprland
|
Loading…
Add table
Add a link
Reference in a new issue