add nvim
This commit is contained in:
parent
adbad8ce2b
commit
1b1b70daed
10
PKGBUILD
10
PKGBUILD
@ -2,9 +2,9 @@ pkgname=tarch-configs
|
|||||||
pkgver=1.0
|
pkgver=1.0
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
pkgdesc="Configs some App for Tarch OS"
|
pkgdesc="Configs some App for Tarch OS"
|
||||||
arch=('any')
|
arch=("any")
|
||||||
url="https://gitcast.ru/tarch_os/tarch-configs.git"
|
url="https://gitcast.ru/tarch_os/tarch-bin"
|
||||||
license=('GPL3')
|
license=("GPL3")
|
||||||
install=${pkgname}.install
|
install=${pkgname}.install
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
@ -16,5 +16,9 @@ package() {
|
|||||||
mkdir -p ${CONFIG_DIR}
|
mkdir -p ${CONFIG_DIR}
|
||||||
cp -r ${srcdir}/* ${CONFIG_DIR}
|
cp -r ${srcdir}/* ${CONFIG_DIR}
|
||||||
|
|
||||||
|
chmod +x "${CONFIG_DIR}/bspwm"/bin/*
|
||||||
|
chmod +x "${CONFIG_DIR}/bspwm"/rofi/bin/*
|
||||||
|
|
||||||
|
install -Dm 755 ${srcdir}/bspwm/bspwmrc "${CONFIG_DIR}/bspwm"/bspwmrc
|
||||||
install -Dm 644 ${srcdir}/mimeapps.list ${CONFIG_DIR}/mimeapps.list
|
install -Dm 644 ${srcdir}/mimeapps.list ${CONFIG_DIR}/mimeapps.list
|
||||||
}
|
}
|
||||||
|
7
configs/bspwm/bin/apps_as_root
Executable file
7
configs/bspwm/bin/apps_as_root
Executable file
@ -0,0 +1,7 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# запуск программ от рута. например в thunar run as root
|
||||||
|
# SUDO_ASKPASS сообщает sudo, какую программу использовать, когда ей необходимо запросить пароль без взаимодействия с пользователем.
|
||||||
|
|
||||||
|
export SUDO_ASKPASS=~/.config/bspwm/bin/askpass
|
||||||
|
sudo -A $1
|
10
configs/bspwm/bin/askpass
Executable file
10
configs/bspwm/bin/askpass
Executable file
@ -0,0 +1,10 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# запуск меню вопроса о пароде
|
||||||
|
|
||||||
|
rofi -dmenu\
|
||||||
|
-password\
|
||||||
|
-i\
|
||||||
|
-no-fixed-num-lines\
|
||||||
|
-p "[] Enter sudo Password, Mr.${USER}: "\
|
||||||
|
-theme ~/.config/bspwm/rofi/themes/askpass.rasi
|
4
configs/bspwm/bin/bspbar
Executable file
4
configs/bspwm/bin/bspbar
Executable file
@ -0,0 +1,4 @@
|
|||||||
|
#!/usr/bin/zsh
|
||||||
|
|
||||||
|
# запуск полибара с иконками
|
||||||
|
bash $HOME/.config/bspwm/polybar/launch.sh
|
13
configs/bspwm/bin/bspcomp
Executable file
13
configs/bspwm/bin/bspcomp
Executable file
@ -0,0 +1,13 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# композитор. всякая анимация окон.
|
||||||
|
# можно посмотрет и поиграть в .config/bspwm/picom/tmp
|
||||||
|
|
||||||
|
# убиваем запущенные
|
||||||
|
killall -q picom
|
||||||
|
|
||||||
|
# ждем пока не выключиться все
|
||||||
|
while pgrep -u $UID -x picom >/dev/null; do sleep 1; done
|
||||||
|
|
||||||
|
# запускаем
|
||||||
|
picom -b --experimental-backends --config $HOME/.config/bspwm/picom/default.conf &
|
49
configs/bspwm/bin/bspconfig
Executable file
49
configs/bspwm/bin/bspconfig
Executable file
@ -0,0 +1,49 @@
|
|||||||
|
#!/usr/bin/zsh
|
||||||
|
|
||||||
|
# цвета из .Xresources
|
||||||
|
xrdb ~/.Xresources
|
||||||
|
|
||||||
|
getcolors() {
|
||||||
|
FOREGROUND=$(xrdb -query | grep 'foreground:'| awk '{print $NF}')
|
||||||
|
BACKGROUND=$(xrdb -query | grep 'background:'| awk '{print $NF}')
|
||||||
|
BLACK=$(xrdb -query | grep 'color0:'| awk '{print $NF}')
|
||||||
|
RED=$(xrdb -query | grep 'color1:'| awk '{print $NF}')
|
||||||
|
GREEN=$(xrdb -query | grep 'color2:'| awk '{print $NF}')
|
||||||
|
YELLOW=$(xrdb -query | grep 'color3:'| awk '{print $NF}')
|
||||||
|
BLUE=$(xrdb -query | grep 'color4:'| awk '{print $NF}')
|
||||||
|
MAGENTA=$(xrdb -query | grep 'color5:'| awk '{print $NF}')
|
||||||
|
CYAN=$(xrdb -query | grep 'color6:'| awk '{print $NF}')
|
||||||
|
WHITE=$(xrdb -query | grep 'color7:'| awk '{print $NF}')
|
||||||
|
}
|
||||||
|
|
||||||
|
getcolors
|
||||||
|
|
||||||
|
bspc config focused_border_color "${BLUE}"
|
||||||
|
bspc config normal_border_color "${BACKGROUND}"
|
||||||
|
bspc config active_border_color "${MAGENTA}"
|
||||||
|
bspc config presel_feedback_color "${GREEN}"
|
||||||
|
|
||||||
|
bspc config border_width 2
|
||||||
|
bspc config window_gap 10
|
||||||
|
bspc config bottom_padding 0
|
||||||
|
bspc config top_padding 0
|
||||||
|
|
||||||
|
# кофициент разделения, сколько процентов останется от родительского окна при открытии нового
|
||||||
|
bspc config split_ratio 0.50
|
||||||
|
|
||||||
|
# отключение гапсов рамок и отступов когда открыто одно окно
|
||||||
|
bspc config borderless_monocle true
|
||||||
|
bspc config gapless_monocle true
|
||||||
|
bspc config paddingless_monocle true
|
||||||
|
|
||||||
|
# режим монокля когда открыто одно окно
|
||||||
|
bspc config single_monocle false
|
||||||
|
|
||||||
|
# фокус окна наведением курсора
|
||||||
|
bspc config focus_follows_pointer true
|
||||||
|
|
||||||
|
bspc config presel_feedback true
|
||||||
|
bspc config pointer_modifier super
|
||||||
|
|
||||||
|
# схемы согласно которым будут открыватся окна
|
||||||
|
#bspc config automatic_scheme spiral
|
11
configs/bspwm/bin/bspdunst
Executable file
11
configs/bspwm/bin/bspdunst
Executable file
@ -0,0 +1,11 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# уведомления
|
||||||
|
|
||||||
|
# убиваем ранее запущенные
|
||||||
|
if [[ `pidof dunst` ]]; then
|
||||||
|
pkill dunst
|
||||||
|
fi
|
||||||
|
|
||||||
|
# запускаем
|
||||||
|
dunst -config $HOME/.config/bspwm/dunst/dunstrc &
|
45
configs/bspwm/bin/bsprules
Executable file
45
configs/bspwm/bin/bsprules
Executable file
@ -0,0 +1,45 @@
|
|||||||
|
#!/usr/bin/zsh
|
||||||
|
|
||||||
|
# настройка отображения программ на workspaces
|
||||||
|
|
||||||
|
# remove all rules first
|
||||||
|
bspc rule -r *:*
|
||||||
|
|
||||||
|
bspc rule -a Google-chrome desktop='^1' follow=on focus=on
|
||||||
|
bspc rule -a Google-chrome-beta desktop='^1'
|
||||||
|
bspc rule -a chromium desktop='^1' follow=on focus=on
|
||||||
|
# bspc rule -a firefox desktop='^1' follow=on focus=on
|
||||||
|
|
||||||
|
bspc rule -a TelegramDesktop desktop='^2'
|
||||||
|
bspc rule -a zoom desktop='^2'
|
||||||
|
bspc rule -a discord desktop='^2'
|
||||||
|
|
||||||
|
bspc rule -a DBeaver desktop='^3'
|
||||||
|
bspc rule -a java desktop='^3'
|
||||||
|
bspc rule -a Java desktop='^3'
|
||||||
|
|
||||||
|
bspc rule -a kitty:project_home desktop='^5'
|
||||||
|
|
||||||
|
bspc rule -a "ONLYOFFICE Desktop Editors" desktop='^11'
|
||||||
|
|
||||||
|
bspc rule -a Signal desktop='^12'
|
||||||
|
bspc rule -a anki desktop='^12'
|
||||||
|
bspc rule -a Anki desktop='^12'
|
||||||
|
|
||||||
|
# на 13 (f) столе все окна плавающие #
|
||||||
|
FLOATING_DESKTOP_ID=$(bspc query -D -d '^13')
|
||||||
|
bspc subscribe node_add | while read -a msg; do
|
||||||
|
desk_id=${msg[2]}
|
||||||
|
wid=${msg[4]}
|
||||||
|
[ "$FLOATING_DESKTOP_ID" = "$desk_id" ] && bspc node "$wid" -t floating
|
||||||
|
done
|
||||||
|
|
||||||
|
# # если перечислять #
|
||||||
|
# declare -a files=(Pcmanfm Thunar Caja dolphin)
|
||||||
|
# for i in ${files[@]}; do
|
||||||
|
# bspc rule -a $i desktop='^3' follow=on focus=on;
|
||||||
|
# done
|
||||||
|
|
||||||
|
# терминалы в которых запускаются разные приложения с нужными размерами
|
||||||
|
bspc rule -a kitty:uparch_run state=floating rectangle=800x450+1516+700 follow=off
|
||||||
|
bspc rule -a kitty:raid_run state=floating rectangle=1280x800+1416+700 follow=off
|
91
configs/bspwm/bspwmrc
Executable file
91
configs/bspwm/bspwmrc
Executable file
@ -0,0 +1,91 @@
|
|||||||
|
#!/usr/bin/zsh
|
||||||
|
|
||||||
|
export PATH="${PATH}:$HOME/.config/bspwm/bin:$HOME/.config/bspwm/rofi/bin:$HOME/.local/bin:$HOME/.local/share/virtualenv/pip/bin"
|
||||||
|
BSPWM_DIR="$HOME/.config/bspwm"
|
||||||
|
|
||||||
|
# настройки клавиш
|
||||||
|
KEYBOARD_LAYOUTS=us,ru
|
||||||
|
setxkbmap -layout ${KEYBOARD_LAYOUTS}
|
||||||
|
setxkbmap -option 'grp:alt_shift_toggle'
|
||||||
|
setxkbmap -option caps:hyper
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# цветовая схема
|
||||||
|
XRES="$HOME/.Xresources.d"
|
||||||
|
COLOR_SCHEME="Chad WM"
|
||||||
|
cat "${BSPWM_DIR}/themes/${COLOR_SCHEME}/colorScheme" > "${XRES}"/colors
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# Решение для java apps (e.g. JetBrains IDEs like PyCharm, CLion, etc). #
|
||||||
|
export _JAVA_AWT_WM_NONREPARENTING=1
|
||||||
|
# Поддержка других приложений не работающих на WMs #
|
||||||
|
wmname LG3D
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# установка ролей #
|
||||||
|
bsprules
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# запуск workspaces
|
||||||
|
bspc monitor -d f
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# Управляйте всеми неуправляемыми окнами, оставшимися с предыдущего сеанса. #
|
||||||
|
bspc wm --adopt-orphans
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# load bspwm Configurations #
|
||||||
|
bspconfig
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
## HERE
|
||||||
|
# РАЗОБРАТЬ
|
||||||
|
## ------------------------- Autostart Apps ------------------------- ##
|
||||||
|
|
||||||
|
# Kill if already running #
|
||||||
|
killall -9 xsettingsd sxhkd dunst ksuperkey xfce4-power-manager bspc picom
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# Lauch xsettingsd daemon #
|
||||||
|
xsettingsd --config="${BSPWM_DIR}"/xsettingsd &
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# polkit agent #
|
||||||
|
if [[ ! `pidof xfce-polkit` ]]; then
|
||||||
|
/usr/lib/xfce-polkit/xfce-polkit &
|
||||||
|
fi
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# Lauch keybindings daemon #
|
||||||
|
KEYBINDING=sxhkdrc
|
||||||
|
sxhkd -c "${BSPWM_DIR}"/keybinding/${KEYBINDING} &
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# Enable Super Keys For Menu #
|
||||||
|
ksuperkey -e 'Super_L=Alt_L|F1' &
|
||||||
|
ksuperkey -e 'Super_R=Alt_L|F1' &
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# Enable power manager #
|
||||||
|
xfce4-power-manager &
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# Fix cursor #
|
||||||
|
xsetroot -cursor_name left_ptr
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# restore wallpaper #
|
||||||
|
BACKGROUND=/usr/share/backgrounds/chad.png
|
||||||
|
feh --no-fehbg --bg-fill ${BACKGROUND}
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# enable num lock #
|
||||||
|
numlockx &
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
|
||||||
|
# start bspwm scripts #
|
||||||
|
bspcomp
|
||||||
|
bspbar
|
||||||
|
bspdunst &
|
||||||
|
# ------------------------------------------------------------------------------ #
|
||||||
|
## ------------------------------------- END -------------------------------------------------- ##
|
56
configs/bspwm/dunst/dunstrc
Executable file
56
configs/bspwm/dunst/dunstrc
Executable file
@ -0,0 +1,56 @@
|
|||||||
|
[global]
|
||||||
|
monitor = 0
|
||||||
|
follow = mouse
|
||||||
|
geometry = "280x50-10+48"
|
||||||
|
indicate_hidden = yes
|
||||||
|
shrink = no
|
||||||
|
separator_height = 4
|
||||||
|
separator_color = auto
|
||||||
|
padding = 15
|
||||||
|
horizontal_padding = 15
|
||||||
|
frame_width = 6
|
||||||
|
sort = no
|
||||||
|
idle_threshold = 120
|
||||||
|
font = JetBrains Mono 10
|
||||||
|
line_height = 4
|
||||||
|
markup = full
|
||||||
|
format = %s\n%b
|
||||||
|
alignment = left
|
||||||
|
show_age_threshold = 60
|
||||||
|
word_wrap = yes
|
||||||
|
ignore_newline = no
|
||||||
|
stack_duplicates = false
|
||||||
|
hide_duplicate_count = yes
|
||||||
|
show_indicators = no
|
||||||
|
icon_position = left
|
||||||
|
max_icon_size = 48
|
||||||
|
sticky_history = yes
|
||||||
|
history_length = 20
|
||||||
|
browser = x-www-browser -new-tab
|
||||||
|
always_run_script = true
|
||||||
|
title = Dunst
|
||||||
|
class = Dunst
|
||||||
|
|
||||||
|
[shortcuts]
|
||||||
|
close = ctrl+shift+space
|
||||||
|
close_all = ctrl+shift+space
|
||||||
|
history = ctrl+grave
|
||||||
|
context = ctrl+shift+period
|
||||||
|
|
||||||
|
[urgency_low]
|
||||||
|
timeout = 2
|
||||||
|
background = "#1E222A"
|
||||||
|
foreground = "#ABB2BF"
|
||||||
|
frame_color = "#61AFEF"
|
||||||
|
|
||||||
|
[urgency_normal]
|
||||||
|
timeout = 5
|
||||||
|
background = "#1E222A"
|
||||||
|
foreground = "#ABB2BF"
|
||||||
|
frame_color = "#61AFEF"
|
||||||
|
|
||||||
|
[urgency_critical]
|
||||||
|
timeout = 0
|
||||||
|
background = "#1E222A"
|
||||||
|
foreground = "#ABB2BF"
|
||||||
|
frame_color = "#61AFEF"
|
71
configs/bspwm/keybinding/sxhkdrc
Executable file
71
configs/bspwm/keybinding/sxhkdrc
Executable file
@ -0,0 +1,71 @@
|
|||||||
|
# переход по воркспейсам
|
||||||
|
super + {q,e}
|
||||||
|
bspc desktop -f {prev,next}.local
|
||||||
|
|
||||||
|
# переключение по открытым приложениям в пределах одного воркспейса
|
||||||
|
super + shift + {s,w}
|
||||||
|
bspc node -f {next,prev}.local.!hidden.window
|
||||||
|
|
||||||
|
# терминал
|
||||||
|
super + shift + Return
|
||||||
|
kitty
|
||||||
|
|
||||||
|
# thunar
|
||||||
|
super + shift + f
|
||||||
|
thunar
|
||||||
|
|
||||||
|
# colorpicker
|
||||||
|
super + shift + c
|
||||||
|
colorPicker
|
||||||
|
|
||||||
|
# закрытие приложения
|
||||||
|
super + shift + z
|
||||||
|
bspc node -{c,k}
|
||||||
|
|
||||||
|
# перезагрузка припязки клавишь
|
||||||
|
super + shift + k
|
||||||
|
pkill -USR1 -x sxhkd
|
||||||
|
|
||||||
|
# restart bspwm
|
||||||
|
ctrl + shift + r
|
||||||
|
bspc wm -r
|
||||||
|
|
||||||
|
# перемещение по панелям
|
||||||
|
super + ctrl + {1-9}
|
||||||
|
bspc node -o 0.{1-9}
|
||||||
|
|
||||||
|
# поменять местами текущее и самое большое окно
|
||||||
|
super + gk
|
||||||
|
bspc node -s biggest.window
|
||||||
|
|
||||||
|
# переключится на воркспейс или перетащить на него активное окно
|
||||||
|
# super 1 - перейти на 1
|
||||||
|
# super + shift + 3 - перемещает активное окно на 3
|
||||||
|
super + {_,shift + }{1-9,0}
|
||||||
|
bspc {desktop -f,node -d} '^{1-9,10}'
|
||||||
|
|
||||||
|
# вернутся на предыдущий активный воркспейс
|
||||||
|
super + {grave,Tab}
|
||||||
|
bspc {node,desktop} -f last
|
||||||
|
|
||||||
|
# меню запущенных программ
|
||||||
|
super + shift + m
|
||||||
|
sh ~/.config/bspwm/rofi/bin/windows
|
||||||
|
|
||||||
|
# меню выхода из сиситемы
|
||||||
|
super + shift + q
|
||||||
|
sh ~/.config/bspwm/rofi/bin/powermenu
|
||||||
|
|
||||||
|
# скриншот
|
||||||
|
ctrl + shift + s
|
||||||
|
sh ~/.config/bspwm/rofi/bin/screenshot
|
||||||
|
|
||||||
|
# гловное меню с программами
|
||||||
|
super + m
|
||||||
|
sh ~/.config/bspwm/rofi/bin/launcher
|
||||||
|
|
||||||
|
|
||||||
|
# РАЗОБРАТЬСЯ !!!
|
||||||
|
# Toggle right click context menu. #
|
||||||
|
~button3
|
||||||
|
xqp 0 $(xdo id -N Bspwm -n root) && jgmenu_run
|
414
configs/bspwm/picom/default.conf
Executable file
414
configs/bspwm/picom/default.conf
Executable file
@ -0,0 +1,414 @@
|
|||||||
|
#========================= Corners =========================#
|
||||||
|
|
||||||
|
corner-radius = 0;
|
||||||
|
rounded-corners-exclude = [
|
||||||
|
"window_type = 'normal'",
|
||||||
|
"class_g ?= 'rofi'",
|
||||||
|
"class_g ?= 'polybar'",
|
||||||
|
"class_g ?= 'tint2'"
|
||||||
|
];
|
||||||
|
|
||||||
|
round-borders = 0;
|
||||||
|
round-borders-exclude = [
|
||||||
|
"class_g = 'TelegramDesktop'"
|
||||||
|
];
|
||||||
|
|
||||||
|
# Specify a list of border width rules, in the format `PIXELS:PATTERN`,
|
||||||
|
# Note we don't make any guarantee about possible conflicts with the
|
||||||
|
# border_width set by the window manager.
|
||||||
|
#
|
||||||
|
# example:
|
||||||
|
# round-borders-rule = [ "2:class_g = 'URxvt'" ];
|
||||||
|
#
|
||||||
|
round-borders-rule = [
|
||||||
|
"2:class_g ?= 'URxvt'",
|
||||||
|
"2:class_g ?= 'Alacritty'",
|
||||||
|
"0:class_g ?= 'firefox'"
|
||||||
|
];
|
||||||
|
|
||||||
|
#========================= Shadows =========================#
|
||||||
|
|
||||||
|
# Enabled client-side shadows on windows. Note desktop windows
|
||||||
|
# (windows with '_NET_WM_WINDOW_TYPE_DESKTOP') never get shadow,
|
||||||
|
# unless explicitly requested using the wintypes option.
|
||||||
|
#
|
||||||
|
shadow = true;
|
||||||
|
|
||||||
|
# The blur radius for shadows, in pixels. (defaults to 12)
|
||||||
|
shadow-radius = 14;
|
||||||
|
|
||||||
|
# The opacity of shadows. (0.0 - 1.0, defaults to 0.75)
|
||||||
|
shadow-opacity = 0.30;
|
||||||
|
|
||||||
|
# The left offset for shadows, in pixels. (defaults to -15)
|
||||||
|
shadow-offset-x = -12;
|
||||||
|
|
||||||
|
# The top offset for shadows, in pixels. (defaults to -15)
|
||||||
|
shadow-offset-y = -12;
|
||||||
|
|
||||||
|
# Red color value of shadow (0.0 - 1.0, defaults to 0).
|
||||||
|
# shadow-red = 0
|
||||||
|
|
||||||
|
# Green color value of shadow (0.0 - 1.0, defaults to 0).
|
||||||
|
# shadow-green = 0
|
||||||
|
|
||||||
|
# Blue color value of shadow (0.0 - 1.0, defaults to 0).
|
||||||
|
# shadow-blue = 0
|
||||||
|
|
||||||
|
# Hex string color value of shadow (#000000 - #FFFFFF, defaults to #000000). This option will override options set shadow-(red/green/blue)
|
||||||
|
# shadow-color = "#000000"
|
||||||
|
|
||||||
|
# Specify a list of conditions of windows that should have no shadow.
|
||||||
|
#
|
||||||
|
# examples:
|
||||||
|
# shadow-exclude = "n:e:Notification";
|
||||||
|
#
|
||||||
|
# shadow-exclude = []
|
||||||
|
shadow-exclude = [
|
||||||
|
"class_g = 'Cairo-clock'",
|
||||||
|
"class_g = 'CoverGloobus'",
|
||||||
|
"class_g = 'Tilda'",
|
||||||
|
"name ?= 'gnome-pie'",
|
||||||
|
"class_g ?= 'Plank'",
|
||||||
|
"name *= 'recordmydesktop'",
|
||||||
|
"name = 'Notification'",
|
||||||
|
"name = 'Docky'",
|
||||||
|
"name = 'Kupfer'",
|
||||||
|
"name = 'xfce4-notifyd'",
|
||||||
|
"name *= 'VLC'",
|
||||||
|
"name *= 'Chromium'",
|
||||||
|
"name *= 'Chrome'",
|
||||||
|
"class_g = 'Conky'",
|
||||||
|
"class_g = 'Kupfer'",
|
||||||
|
"class_g = 'Synapse'",
|
||||||
|
"class_g ?= 'Notify-osd'",
|
||||||
|
"class_g ?= 'Cairo-dock'",
|
||||||
|
"class_g ?= 'Xfce4-notifyd'",
|
||||||
|
"class_g ?= 'Xfce4-power-manager'",
|
||||||
|
"_GTK_FRAME_EXTENTS@:c",
|
||||||
|
"_NET_WM_STATE@:32a *= '_NET_WM_STATE_HIDDEN'"
|
||||||
|
];
|
||||||
|
|
||||||
|
# Specify a X geometry that describes the region in which shadow should not
|
||||||
|
# be painted in, such as a dock window region. Use
|
||||||
|
# shadow-exclude-reg = "x10+0+0"
|
||||||
|
# for example, if the 10 pixels on the bottom of the screen should not have shadows painted on.
|
||||||
|
#
|
||||||
|
# shadow-exclude-reg = ""
|
||||||
|
|
||||||
|
# Crop shadow of a window fully on a particular Xinerama screen to the screen.
|
||||||
|
# xinerama-shadow-crop = false
|
||||||
|
|
||||||
|
#========================= Fading =========================#
|
||||||
|
|
||||||
|
# Fade windows in/out when opening/closing and when opacity changes,
|
||||||
|
# unless no-fading-openclose is used.
|
||||||
|
fading = true;
|
||||||
|
|
||||||
|
# Opacity change between steps while fading in. (0.01 - 1.0, defaults to 0.028)
|
||||||
|
fade-in-step = 0.03;
|
||||||
|
|
||||||
|
# Opacity change between steps while fading out. (0.01 - 1.0, defaults to 0.03)
|
||||||
|
fade-out-step = 0.03;
|
||||||
|
|
||||||
|
# The time between steps in fade step, in milliseconds. (> 0, defaults to 10)
|
||||||
|
fade-delta = 5;
|
||||||
|
|
||||||
|
# Specify a list of conditions of windows that should not be faded.
|
||||||
|
# don't need this, we disable fading for all normal windows with wintypes: {}
|
||||||
|
fade-exclude = [
|
||||||
|
"class_g = 'slop'" # maim
|
||||||
|
]
|
||||||
|
|
||||||
|
# Do not fade on window open/close.
|
||||||
|
no-fading-openclose = false
|
||||||
|
|
||||||
|
# Do not fade destroyed ARGB windows with WM frame. Workaround of bugs in Openbox, Fluxbox, etc.
|
||||||
|
no-fading-destroyed-argb = true
|
||||||
|
|
||||||
|
#========================= Opacity =========================#
|
||||||
|
|
||||||
|
# Opacity of inactive windows. (0.1 - 1.0, defaults to 1.0)
|
||||||
|
# inactive-opacity = 1
|
||||||
|
inactive-opacity = 1;
|
||||||
|
|
||||||
|
# Opacity of window titlebars and borders. (0.1 - 1.0, disabled by default)
|
||||||
|
# frame-opacity = 1.0
|
||||||
|
frame-opacity = 1.0;
|
||||||
|
|
||||||
|
# Let inactive opacity set by -i override the '_NET_WM_OPACITY' values of windows.
|
||||||
|
# inactive-opacity-override = true
|
||||||
|
inactive-opacity-override = false;
|
||||||
|
|
||||||
|
# Default opacity for active windows. (0.0 - 1.0, defaults to 1.0)
|
||||||
|
active-opacity = 1.0;
|
||||||
|
|
||||||
|
# Dim inactive windows. (0.0 - 1.0, defaults to 0.0)
|
||||||
|
#inactive-dim = 0.5
|
||||||
|
|
||||||
|
# Specify a list of conditions of windows that should always be considered focused.
|
||||||
|
# focus-exclude = []
|
||||||
|
focus-exclude = [
|
||||||
|
"class_g = 'Cairo-clock'",
|
||||||
|
"class_g = 'Bar'", # lemonbar
|
||||||
|
"class_g = 'slop'" # maim
|
||||||
|
];
|
||||||
|
|
||||||
|
# Use fixed inactive dim value, instead of adjusting according to window opacity.
|
||||||
|
# inactive-dim-fixed = 1.0
|
||||||
|
|
||||||
|
# Specify a list of opacity rules, in the format `PERCENT:PATTERN`,
|
||||||
|
# like `50:name *= "Firefox"`. picom-trans is recommended over this.
|
||||||
|
# Note we don't make any guarantee about possible conflicts with other
|
||||||
|
# programs that set '_NET_WM_WINDOW_OPACITY' on frame or client windows.
|
||||||
|
# example:
|
||||||
|
# opacity-rule = [ "80:class_g = 'URxvt'" ];
|
||||||
|
#
|
||||||
|
# opacity-rule = []
|
||||||
|
opacity-rule = [
|
||||||
|
"100:class_g = 'Bar'", # lemonbar
|
||||||
|
"100:class_g = 'slop'", # maim
|
||||||
|
"100:class_g = 'XTerm'",
|
||||||
|
"100:class_g = 'URxvt'",
|
||||||
|
"100:class_g = 'kitty'",
|
||||||
|
"100:class_g = 'Alacritty'",
|
||||||
|
"100:class_g = 'Polybar'",
|
||||||
|
"100:class_g = 'code-oss'",
|
||||||
|
"100:class_g = 'Meld'",
|
||||||
|
"100:class_g = 'TelegramDesktop'",
|
||||||
|
"100:class_g = 'Joplin'",
|
||||||
|
"100:class_g = 'firefox'",
|
||||||
|
"100:class_g = 'Thunderbird'"
|
||||||
|
];
|
||||||
|
|
||||||
|
#========================= Blurring =========================#
|
||||||
|
|
||||||
|
blur: {
|
||||||
|
method = "none";
|
||||||
|
strength = 0;
|
||||||
|
background = false;
|
||||||
|
background-frame = false;
|
||||||
|
background-fixed = false;
|
||||||
|
kern = "3x3box";
|
||||||
|
}
|
||||||
|
|
||||||
|
# Exclude conditions for background blur.
|
||||||
|
blur-background-exclude = [
|
||||||
|
"window_type = 'dock'",
|
||||||
|
"window_type = 'desktop'",
|
||||||
|
"class_g = 'Plank'",
|
||||||
|
"class_g = 'slop'",
|
||||||
|
"_GTK_FRAME_EXTENTS@:c"
|
||||||
|
];
|
||||||
|
|
||||||
|
#========================= General Settings =========================#
|
||||||
|
|
||||||
|
# Daemonize process. Fork to background after initialization. Causes issues with certain (badly-written) drivers.
|
||||||
|
# daemon = false
|
||||||
|
|
||||||
|
# Specify the backend to use: `xrender`, `glx`, or `xr_glx_hybrid`.
|
||||||
|
# `xrender` is the default one.
|
||||||
|
#
|
||||||
|
experimental-backends = true;
|
||||||
|
backend = "xrender";
|
||||||
|
|
||||||
|
# Enable/disable VSync.
|
||||||
|
# vsync = false
|
||||||
|
vsync = true;
|
||||||
|
|
||||||
|
# Enable remote control via D-Bus. See the *D-BUS API* section below for more details.
|
||||||
|
# dbus = false
|
||||||
|
|
||||||
|
# Try to detect WM windows (a non-override-redirect window with no
|
||||||
|
# child that has 'WM_STATE') and mark them as active.
|
||||||
|
#
|
||||||
|
# mark-wmwin-focused = false
|
||||||
|
mark-wmwin-focused = true;
|
||||||
|
|
||||||
|
# Mark override-redirect windows that doesn't have a child window with 'WM_STATE' focused.
|
||||||
|
# mark-ovredir-focused = false
|
||||||
|
mark-ovredir-focused = true;
|
||||||
|
|
||||||
|
# Try to detect windows with rounded corners and don't consider them
|
||||||
|
# shaped windows. The accuracy is not very high, unfortunately.
|
||||||
|
#
|
||||||
|
# detect-rounded-corners = false
|
||||||
|
detect-rounded-corners = true;
|
||||||
|
|
||||||
|
# Detect '_NET_WM_OPACITY' on client windows, useful for window managers
|
||||||
|
# not passing '_NET_WM_OPACITY' of client windows to frame windows.
|
||||||
|
#
|
||||||
|
# detect-client-opacity = false
|
||||||
|
detect-client-opacity = true;
|
||||||
|
|
||||||
|
# Specify refresh rate of the screen. If not specified or 0, picom will
|
||||||
|
# try detecting this with X RandR extension.
|
||||||
|
#
|
||||||
|
# refresh-rate = 60
|
||||||
|
refresh-rate = 0;
|
||||||
|
|
||||||
|
# Use EWMH '_NET_ACTIVE_WINDOW' to determine currently focused window,
|
||||||
|
# rather than listening to 'FocusIn'/'FocusOut' event. Might have more accuracy,
|
||||||
|
# provided that the WM supports it.
|
||||||
|
#
|
||||||
|
# use-ewmh-active-win = false
|
||||||
|
|
||||||
|
# Unredirect all windows if a full-screen opaque window is detected,
|
||||||
|
# to maximize performance for full-screen windows. Known to cause flickering
|
||||||
|
# when redirecting/unredirecting windows.
|
||||||
|
#
|
||||||
|
# unredir-if-possible = false
|
||||||
|
|
||||||
|
# Delay before unredirecting the window, in milliseconds. Defaults to 0.
|
||||||
|
# unredir-if-possible-delay = 0
|
||||||
|
|
||||||
|
# Conditions of windows that shouldn't be considered full-screen for unredirecting screen.
|
||||||
|
# unredir-if-possible-exclude = []
|
||||||
|
|
||||||
|
# Use 'WM_TRANSIENT_FOR' to group windows, and consider windows
|
||||||
|
# in the same group focused at the same time.
|
||||||
|
#
|
||||||
|
# detect-transient = false
|
||||||
|
detect-transient = true;
|
||||||
|
|
||||||
|
# Use 'WM_CLIENT_LEADER' to group windows, and consider windows in the same
|
||||||
|
# group focused at the same time. 'WM_TRANSIENT_FOR' has higher priority if
|
||||||
|
# detect-transient is enabled, too.
|
||||||
|
#
|
||||||
|
# detect-client-leader = false
|
||||||
|
detect-client-leader = true;
|
||||||
|
|
||||||
|
# Resize damaged region by a specific number of pixels.
|
||||||
|
# A positive value enlarges it while a negative one shrinks it.
|
||||||
|
# If the value is positive, those additional pixels will not be actually painted
|
||||||
|
# to screen, only used in blur calculation, and such. (Due to technical limitations,
|
||||||
|
# with use-damage, those pixels will still be incorrectly painted to screen.)
|
||||||
|
# Primarily used to fix the line corruption issues of blur,
|
||||||
|
# in which case you should use the blur radius value here
|
||||||
|
# (e.g. with a 3x3 kernel, you should use `--resize-damage 1`,
|
||||||
|
# with a 5x5 one you use `--resize-damage 2`, and so on).
|
||||||
|
# May or may not work with *--glx-no-stencil*. Shrinking doesn't function correctly.
|
||||||
|
#
|
||||||
|
# resize-damage = 1
|
||||||
|
|
||||||
|
# Specify a list of conditions of windows that should be painted with inverted color.
|
||||||
|
# Resource-hogging, and is not well tested.
|
||||||
|
#
|
||||||
|
# invert-color-include = []
|
||||||
|
|
||||||
|
# GLX backend: Avoid using stencil buffer, useful if you don't have a stencil buffer.
|
||||||
|
# Might cause incorrect opacity when rendering transparent content (but never
|
||||||
|
# practically happened) and may not work with blur-background.
|
||||||
|
# My tests show a 15% performance boost. Recommended.
|
||||||
|
#
|
||||||
|
glx-no-stencil = true;
|
||||||
|
|
||||||
|
# GLX backend: Avoid rebinding pixmap on window damage.
|
||||||
|
# Probably could improve performance on rapid window content changes,
|
||||||
|
# but is known to break things on some drivers (LLVMpipe, xf86-video-intel, etc.).
|
||||||
|
# Recommended if it works.
|
||||||
|
#
|
||||||
|
# glx-no-rebind-pixmap = false
|
||||||
|
|
||||||
|
# Disable the use of damage information.
|
||||||
|
# This cause the whole screen to be redrawn everytime, instead of the part of the screen
|
||||||
|
# has actually changed. Potentially degrades the performance, but might fix some artifacts.
|
||||||
|
# The opposing option is use-damage
|
||||||
|
#
|
||||||
|
# no-use-damage = false
|
||||||
|
use-damage = true;
|
||||||
|
|
||||||
|
# Use X Sync fence to sync clients' draw calls, to make sure all draw
|
||||||
|
# calls are finished before picom starts drawing. Needed on nvidia-drivers
|
||||||
|
# with GLX backend for some users.
|
||||||
|
#
|
||||||
|
# xrender-sync-fence = false
|
||||||
|
|
||||||
|
# GLX backend: Use specified GLSL fragment shader for rendering window contents.
|
||||||
|
# See `compton-default-fshader-win.glsl` and `compton-fake-transparency-fshader-win.glsl`
|
||||||
|
# in the source tree for examples.
|
||||||
|
#
|
||||||
|
# glx-fshader-win = ""
|
||||||
|
|
||||||
|
# Force all windows to be painted with blending. Useful if you
|
||||||
|
# have a glx-fshader-win that could turn opaque pixels transparent.
|
||||||
|
#
|
||||||
|
# force-win-blend = false
|
||||||
|
|
||||||
|
# Do not use EWMH to detect fullscreen windows.
|
||||||
|
# Reverts to checking if a window is fullscreen based only on its size and coordinates.
|
||||||
|
#
|
||||||
|
# no-ewmh-fullscreen = false
|
||||||
|
|
||||||
|
# Dimming bright windows so their brightness doesn't exceed this set value.
|
||||||
|
# Brightness of a window is estimated by averaging all pixels in the window,
|
||||||
|
# so this could comes with a performance hit.
|
||||||
|
# Setting this to 1.0 disables this behaviour. Requires --use-damage to be disabled. (default: 1.0)
|
||||||
|
#
|
||||||
|
# max-brightness = 1.0
|
||||||
|
|
||||||
|
# Make transparent windows clip other windows like non-transparent windows do,
|
||||||
|
# instead of blending on top of them.
|
||||||
|
#
|
||||||
|
# transparent-clipping = false
|
||||||
|
|
||||||
|
# Set the log level. Possible values are:
|
||||||
|
# "trace", "debug", "info", "warn", "error"
|
||||||
|
# in increasing level of importance. Case doesn't matter.
|
||||||
|
# If using the "TRACE" log level, it's better to log into a file
|
||||||
|
# using *--log-file*, since it can generate a huge stream of logs.
|
||||||
|
#
|
||||||
|
# log-level = "debug"
|
||||||
|
log-level = "info";
|
||||||
|
|
||||||
|
# Set the log file.
|
||||||
|
# If *--log-file* is never specified, logs will be written to stderr.
|
||||||
|
# Otherwise, logs will to written to the given file, though some of the early
|
||||||
|
# logs might still be written to the stderr.
|
||||||
|
# When setting this option from the config file, it is recommended to use an absolute path.
|
||||||
|
#
|
||||||
|
# log-file = "/path/to/your/log/file"
|
||||||
|
|
||||||
|
# Show all X errors (for debugging)
|
||||||
|
# show-all-xerrors = false
|
||||||
|
|
||||||
|
# Write process ID to a file.
|
||||||
|
# write-pid-path = "/path/to/your/log/file"
|
||||||
|
|
||||||
|
# Window type settings
|
||||||
|
#
|
||||||
|
# 'WINDOW_TYPE' is one of the 15 window types defined in EWMH standard:
|
||||||
|
# "unknown", "desktop", "dock", "toolbar", "menu", "utility",
|
||||||
|
# "splash", "dialog", "normal", "dropdown_menu", "popup_menu",
|
||||||
|
# "tooltip", "notification", "combo", and "dnd".
|
||||||
|
#
|
||||||
|
# Following per window-type options are available: ::
|
||||||
|
#
|
||||||
|
# fade, shadow:::
|
||||||
|
# Controls window-type-specific shadow and fade settings.
|
||||||
|
#
|
||||||
|
# opacity:::
|
||||||
|
# Controls default opacity of the window type.
|
||||||
|
#
|
||||||
|
# focus:::
|
||||||
|
# Controls whether the window of this type is to be always considered focused.
|
||||||
|
# (By default, all window types except "normal" and "dialog" has this on.)
|
||||||
|
#
|
||||||
|
# full-shadow:::
|
||||||
|
# Controls whether shadow is drawn under the parts of the window that you
|
||||||
|
# normally won't be able to see. Useful when the window has parts of it
|
||||||
|
# transparent, and you want shadows in those areas.
|
||||||
|
#
|
||||||
|
# redir-ignore:::
|
||||||
|
# Controls whether this type of windows should cause screen to become
|
||||||
|
# redirected again after been unredirected. If you have unredir-if-possible
|
||||||
|
# set, and doesn't want certain window to cause unnecessary screen redirection,
|
||||||
|
# you can set this to `true`.
|
||||||
|
#
|
||||||
|
wintypes:
|
||||||
|
{
|
||||||
|
tooltip = { fade=true; shadow=true; opacity=0.95; focus=true; full-shadow=false; };
|
||||||
|
popup_menu = { opacity=1.0; }
|
||||||
|
dropdown_menu = { opacity=1.0; }
|
||||||
|
utility = { shadow=false; opacity=1.0; }
|
||||||
|
};
|
118
configs/bspwm/polybar/config
Executable file
118
configs/bspwm/polybar/config
Executable file
@ -0,0 +1,118 @@
|
|||||||
|
# Global WM Settings
|
||||||
|
[global/wm]
|
||||||
|
margin-bottom = 0
|
||||||
|
margin-top = 0
|
||||||
|
|
||||||
|
# разности
|
||||||
|
include-file = ./utils/system
|
||||||
|
include-file = ./utils/colors
|
||||||
|
|
||||||
|
# сеть
|
||||||
|
include-file = ./modules/net
|
||||||
|
|
||||||
|
# громкость, микрофон
|
||||||
|
include-file = ./modules/media
|
||||||
|
|
||||||
|
# календарь и дата
|
||||||
|
include-file = ./modules/date
|
||||||
|
|
||||||
|
# клавиатура
|
||||||
|
include-file = ./modules/keyboard
|
||||||
|
|
||||||
|
# меню нга знаке арча
|
||||||
|
include-file = ./modules/main_menu
|
||||||
|
|
||||||
|
# workspaces
|
||||||
|
include-file = ./modules/workspaces
|
||||||
|
|
||||||
|
# monitoring
|
||||||
|
include-file = ./modules/cpu
|
||||||
|
include-file = ./modules/filesystem
|
||||||
|
include-file = ./modules/uparch
|
||||||
|
|
||||||
|
# separators (e.g , | , <| , ,etc..) #
|
||||||
|
include-file = ./modules/separators
|
||||||
|
|
||||||
|
# # # # #
|
||||||
|
# VIEW #
|
||||||
|
# # # # #
|
||||||
|
|
||||||
|
[bar/main]
|
||||||
|
monitor = ${env:MONITOR:}
|
||||||
|
monitor-strict = false
|
||||||
|
override-redirect = false
|
||||||
|
|
||||||
|
bottom = false
|
||||||
|
fixed-center = true
|
||||||
|
|
||||||
|
width = 99%
|
||||||
|
height = 30
|
||||||
|
offset-x = 0.5%
|
||||||
|
offset-y = 0.5%
|
||||||
|
|
||||||
|
background = ${color.BACKGROUND}
|
||||||
|
foreground = ${color.FOREGROUND}
|
||||||
|
|
||||||
|
radius-top = 0.0
|
||||||
|
radius-bottom = 0.0
|
||||||
|
|
||||||
|
line-size = 2
|
||||||
|
line-color = ${color.BLUE}
|
||||||
|
|
||||||
|
border-size = 5
|
||||||
|
border-color = ${color.BACKGROUND}
|
||||||
|
|
||||||
|
padding = 0
|
||||||
|
module-margin-left = 0
|
||||||
|
module-margin-right = 0
|
||||||
|
|
||||||
|
font-0 = "Iosevka Nerd Font:size=10;3"
|
||||||
|
font-1 = "Iosevka Nerd Font:size=12;3"
|
||||||
|
font-2 = "google\\-mdi:size=12;3"
|
||||||
|
font-3 = "Iosevka:style=bold:size=12;3"
|
||||||
|
font-4 = "Iosevka Nerd Font:size=18;4"
|
||||||
|
font-5 = "JetBrainsMono Nerd Font:style=Bold:pixelsize=9;3"
|
||||||
|
font-6 = "JetBrainsMono Nerd Font:size=13;4"
|
||||||
|
|
||||||
|
modules-left = xdomenu space LDD bspwm LDD space
|
||||||
|
modules-center = xwindow
|
||||||
|
modules-right = uparch space LDD xkeyboard LDD space LDD volume spaceD pulse-mic spaceD space cpu space cpu-temp space network space ethernet space PLDD date PLD
|
||||||
|
|
||||||
|
separator =
|
||||||
|
spacing = 0
|
||||||
|
|
||||||
|
dim-value = 1.0
|
||||||
|
|
||||||
|
wm-name = bspwm
|
||||||
|
locale = ru_RU.UTF-8
|
||||||
|
|
||||||
|
tray-position = right
|
||||||
|
tray-detached = false
|
||||||
|
tray-maxsize = 16
|
||||||
|
tray-transparent = false
|
||||||
|
tray-background = ${color.tray-background}
|
||||||
|
tray-offset-x = 0
|
||||||
|
tray-offset-y = 0
|
||||||
|
tray-padding = 0
|
||||||
|
tray-scale = 1.0
|
||||||
|
|
||||||
|
wm-restack = bspwm
|
||||||
|
|
||||||
|
enable-ipc = true
|
||||||
|
|
||||||
|
; bspwm
|
||||||
|
scroll-up = bspc desktop -f prev.local
|
||||||
|
scroll-down = bspc desktop -f next.local
|
||||||
|
|
||||||
|
[settings]
|
||||||
|
throttle-output = 5
|
||||||
|
throttle-output-for = 10
|
||||||
|
throttle-input-for = 30
|
||||||
|
|
||||||
|
screenchange-reload = false
|
||||||
|
|
||||||
|
compositing-background = source
|
||||||
|
compositing-foreground = over
|
||||||
|
compositing-overline = over
|
||||||
|
compositing-underline = over
|
||||||
|
compositing-border = over
|
64
configs/bspwm/polybar/launch.sh
Executable file
64
configs/bspwm/polybar/launch.sh
Executable file
@ -0,0 +1,64 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Files and Directories #
|
||||||
|
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
|
||||||
|
BAR="Chad WM"
|
||||||
|
POLYBAR_DIR="$HOME/.config/bspwm/polybar"
|
||||||
|
SFILE="${POLYBAR_DIR}/utils/system"
|
||||||
|
|
||||||
|
# Get system variable values for various modules #
|
||||||
|
GET_VALUES() {
|
||||||
|
CARD=$(light -L | grep 'backlight' | head -n1 | cut -d'/' -f3)
|
||||||
|
BATTERY=$(upower -i `upower -e | grep 'BAT'` | grep 'native-path' | cut -d':' -f2 | tr -d '[:blank:]')
|
||||||
|
ADAPTER=$(upower -i `upower -e | grep 'AC'` | grep 'native-path' | cut -d':' -f2 | tr -d '[:blank:]')
|
||||||
|
INTERFACE=$(ip link | awk '/state UP/ {print $2}' | tr -d :)
|
||||||
|
}
|
||||||
|
|
||||||
|
# Write values to `system` file #
|
||||||
|
SET_VALUES() {
|
||||||
|
if [[ "$ADAPTER" ]]; then
|
||||||
|
sed -i -e "s/adapter = .*/adapter = $ADAPTER/g" "${SFILE}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "$BATTERY" ]]; then
|
||||||
|
sed -i -e "s/battery = .*/battery = $BATTERY/g" "${SFILE}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "$CARD" ]]; then
|
||||||
|
sed -i -e "s/graphics_card = .*/graphics_card = $CARD/g" "${SFILE}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "$INTERFACE" ]]; then
|
||||||
|
sed -i -e "s/network_interface = .*/network_interface = $INTERFACE/g" "${SFILE}"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# Launch Polybar with the selected style ONLY in the primary display #
|
||||||
|
LAUNCH_SINGLE_BAR() {
|
||||||
|
CARD=$(light -L | grep 'backlight' | head -n1 | cut -d'/' -f3)
|
||||||
|
INTERFACE=$(ip link | awk '/state UP/ {print $2}' | tr -d :)
|
||||||
|
|
||||||
|
if [[ -z "$CARD" ]]; then
|
||||||
|
sed -i -e 's/backlight/bna/g' "$DIR"/config
|
||||||
|
|
||||||
|
elif [[ "$CARD" != *"intel_"* ]]; then
|
||||||
|
sed -i -e 's/backlight/brightness/g' "$DIR"/config
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Close polybar #
|
||||||
|
killall -q polybar
|
||||||
|
|
||||||
|
# Wait until closing polybar #
|
||||||
|
while pgrep -u $UID -x polybar >/dev/null; do
|
||||||
|
sleep 1
|
||||||
|
done
|
||||||
|
|
||||||
|
# Launch polybar #
|
||||||
|
polybar -q main -c "$DIR"/config &
|
||||||
|
}
|
||||||
|
|
||||||
|
# Execute functions #
|
||||||
|
GET_VALUES
|
||||||
|
SET_VALUES
|
||||||
|
|
||||||
|
LAUNCH_SINGLE_BAR
|
26
configs/bspwm/polybar/modules/cpu
Executable file
26
configs/bspwm/polybar/modules/cpu
Executable file
@ -0,0 +1,26 @@
|
|||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/cpu]
|
||||||
|
type = internal/cpu
|
||||||
|
interval = 0.5
|
||||||
|
|
||||||
|
format = <label>
|
||||||
|
format-prefix = " CPU "
|
||||||
|
format-prefix-font = 3
|
||||||
|
format-prefix-foreground = #353B45
|
||||||
|
format-prefix-background = #7EC7A2
|
||||||
|
|
||||||
|
; label = "%{A1:alacritty -e stacer &:} %percentage%%%{A}"
|
||||||
|
label = "%{A1:stacer &:} %percentage%% %{A}"
|
||||||
|
label-background = #353B45
|
||||||
|
label-font = 2
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/cpu-temp]
|
||||||
|
type = custom/script
|
||||||
|
exec = ~/.config/bspwm/polybar/scripts/health
|
||||||
|
interval = 1
|
||||||
|
click-left = xsensors
|
||||||
|
format-foreground = ${color.BLUE}
|
||||||
|
|
19
configs/bspwm/polybar/modules/date
Normal file
19
configs/bspwm/polybar/modules/date
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
[module/date]
|
||||||
|
type = internal/date
|
||||||
|
|
||||||
|
interval = 1.0
|
||||||
|
|
||||||
|
time = %d %b, %H:%M
|
||||||
|
time-alt = ""
|
||||||
|
|
||||||
|
format =%{A1:/home/chatlanin/.config/bspwm/rofi/bin/calendar:}<label>%{A}
|
||||||
|
|
||||||
|
format-prefix = " "
|
||||||
|
format-prefix-font = 3
|
||||||
|
format-prefix-foreground = ${color.BACKGROUND}
|
||||||
|
format-prefix-background = #4b70bd
|
||||||
|
|
||||||
|
label = " %time%"
|
||||||
|
label-font = 4
|
||||||
|
label-foreground = ${color.BACKGROUND}
|
||||||
|
label-background = #7AA2F7
|
22
configs/bspwm/polybar/modules/filesystem
Normal file
22
configs/bspwm/polybar/modules/filesystem
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
[module/filesystem]
|
||||||
|
type = internal/fs
|
||||||
|
mount-0 = /
|
||||||
|
interval = 30
|
||||||
|
fixed-values = true
|
||||||
|
|
||||||
|
format-mounted = <label-mounted>
|
||||||
|
format-mounted-prefix = " "
|
||||||
|
format-mounted-prefix-foreground = ${color.BACKGROUND}
|
||||||
|
format-mounted-prefix-background = ${color.cyan}
|
||||||
|
format-unmounted = <label-unmounted>
|
||||||
|
format-unmounted-prefix = " "
|
||||||
|
format-unmounted-prefix-foreground = ${color.BACKGROUND}
|
||||||
|
format-unmounted-prefix-background = ${color.cyan}
|
||||||
|
|
||||||
|
label-mounted = "%{A1:alacritty --config-file ~/.config/bspwm/alacritty/alacritty.toml -e duf &:} %free%%{A}"
|
||||||
|
label-unmounted = " %mountpoint%: NA"
|
||||||
|
label-mounted-foreground = ${color.BACKGROUND}
|
||||||
|
|
||||||
|
label-mounted-background = ${color.cyan}
|
||||||
|
label-unmounted-background = ${color.cyan}
|
||||||
|
|
11
configs/bspwm/polybar/modules/keyboard
Normal file
11
configs/bspwm/polybar/modules/keyboard
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
[module/xkeyboard]
|
||||||
|
type = internal/xkeyboard
|
||||||
|
blacklist-0 = num lock
|
||||||
|
|
||||||
|
label-layout = " %layout%"
|
||||||
|
label-layout-foreground = #61AFEF
|
||||||
|
label-layout-background = #353B45
|
||||||
|
label-layout-font = 4
|
||||||
|
label-indicator-font = 4
|
||||||
|
label-indicator-foreground = #61AFEF
|
||||||
|
label-indicator-background = #353B45
|
9
configs/bspwm/polybar/modules/main_menu
Normal file
9
configs/bspwm/polybar/modules/main_menu
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
[module/xdomenu]
|
||||||
|
type = custom/text
|
||||||
|
interval = 1
|
||||||
|
content = ""
|
||||||
|
content-font = 5
|
||||||
|
content-foreground = #353B45
|
||||||
|
content-background = #7DC5A0
|
||||||
|
content-padding = 1
|
||||||
|
click-left = jgmenu_run
|
46
configs/bspwm/polybar/modules/media
Executable file
46
configs/bspwm/polybar/modules/media
Executable file
@ -0,0 +1,46 @@
|
|||||||
|
[module/volume]
|
||||||
|
type = internal/pulseaudio
|
||||||
|
sink = alsa_output.pci-0000_12_00.3.analog-stereo
|
||||||
|
use-ui-max = false
|
||||||
|
interval = 5
|
||||||
|
|
||||||
|
format-volume = <ramp-volume><label-volume>
|
||||||
|
format-muted = <label-muted>
|
||||||
|
format-muted-prefix = 婢
|
||||||
|
format-muted-prefix-font = 2
|
||||||
|
format-muted-prefix-foreground = ${color.RED}
|
||||||
|
format-muted-prefix-background = #353B45
|
||||||
|
|
||||||
|
label-volume = %percentage%%
|
||||||
|
label-volume-foreground = ${color.BLUE}
|
||||||
|
label-volume-background = #353B45
|
||||||
|
label-muted = " Mute"
|
||||||
|
label-muted-foreground = ${color.RED}
|
||||||
|
label-muted-background = #353B45
|
||||||
|
|
||||||
|
ramp-volume-0 = "奄 "
|
||||||
|
ramp-volume-1 = "奄 "
|
||||||
|
ramp-volume-2 = "奄 "
|
||||||
|
ramp-volume-3 = "奔 "
|
||||||
|
ramp-volume-4 = "奔 "
|
||||||
|
ramp-volume-5 = "奔 "
|
||||||
|
ramp-volume-6 = "墳 "
|
||||||
|
ramp-volume-7 = "墳 "
|
||||||
|
ramp-volume-8 = "墳 "
|
||||||
|
ramp-volume-9 = "墳 "
|
||||||
|
ramp-volume-font = 2
|
||||||
|
ramp-volume-foreground = ${color.BLUE}
|
||||||
|
ramp-volume-background = #353B45
|
||||||
|
ramp-headphones-0 =
|
||||||
|
ramp-headphones-1 =
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/pulse-mic]
|
||||||
|
|
||||||
|
type = custom/script
|
||||||
|
exec = ~/.config/bspwm/polybar/scripts/pulse-mic
|
||||||
|
tail = true
|
||||||
|
click-left = ~/.config/bspwm/polybar/scripts/pulse-mic --toggle &
|
||||||
|
scroll-up = ~/.config/bspwm/polybar/scripts/pulse-mic --increase &
|
||||||
|
scroll-down = ~/.config/bspwm/polybar/scripts/pulse-mic --decrease &
|
61
configs/bspwm/polybar/modules/net
Executable file
61
configs/bspwm/polybar/modules/net
Executable file
@ -0,0 +1,61 @@
|
|||||||
|
; If you use both a wired and a wireless network, add both modules in config.
|
||||||
|
[module/ethernet]
|
||||||
|
type = internal/network
|
||||||
|
interface = ${system.network_interface}
|
||||||
|
|
||||||
|
interval = 1.0
|
||||||
|
accumulate-stats = true
|
||||||
|
unknown-as-up = true
|
||||||
|
|
||||||
|
format-connected = <label-connected>
|
||||||
|
format-connected-prefix = " "
|
||||||
|
format-connected-prefix-font = 3
|
||||||
|
format-connected-prefix-foreground = #3B414D
|
||||||
|
format-connected-prefix-background = #7AA2F7
|
||||||
|
|
||||||
|
format-disconnected = <label-disconnected>
|
||||||
|
format-disconnected-prefix = " ﲁ "
|
||||||
|
format-disconnected-prefix-font = 3
|
||||||
|
format-disconnected-prefix-foreground = #3B414D
|
||||||
|
format-disconnected-prefix-background = #7AA2F7
|
||||||
|
|
||||||
|
label-connected = "%{A1:sh ~/.config/bspwm/rofi/bin/network &:} %downspeed% %upspeed% %{A}"
|
||||||
|
label-connected-background = #353B45
|
||||||
|
label-connected-foreground = #7EC7A2
|
||||||
|
|
||||||
|
label-disconnected = "%{A1:sh ~/.config/bspwm/rofi/bin/network &:} Offline %{A}"
|
||||||
|
label-disconnected-background = #353B45
|
||||||
|
label-disconnected-foreground = #7EC7A2
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/network]
|
||||||
|
type = internal/network
|
||||||
|
interface = ${system.network_interface}
|
||||||
|
interval = 1.0
|
||||||
|
;;ping-interval = 3
|
||||||
|
;;udspeed-minwidth = 5
|
||||||
|
accumulate-stats = true
|
||||||
|
unknown-as-up = true
|
||||||
|
|
||||||
|
format-connected = <ramp-signal><label-connected>
|
||||||
|
format-disconnected = <label-disconnected>
|
||||||
|
format-disconnected-prefix = " 睊 "
|
||||||
|
format-disconnected-prefix-font = 3
|
||||||
|
format-disconnected-prefix-foreground = #3B414D
|
||||||
|
format-disconnected-prefix-background = #7AA2F7
|
||||||
|
|
||||||
|
label-connected = "%{A1:nmd &:} %essid% %{A}"
|
||||||
|
label-connected-foreground = #7AA2F7
|
||||||
|
label-connected-background = #353B45
|
||||||
|
label-disconnected = "%{A1:nmd &:} Disconnected %{A}"
|
||||||
|
label-disconnected-foreground = #7AA2F7
|
||||||
|
label-disconnected-background = #353B45
|
||||||
|
|
||||||
|
ramp-signal-0 = " "
|
||||||
|
ramp-signal-1 = " "
|
||||||
|
ramp-signal-2 = " "
|
||||||
|
ramp-signal-3 = " "
|
||||||
|
ramp-signal-4 = " "
|
||||||
|
ramp-signal-font = 3
|
||||||
|
ramp-signal-foreground = #3B414D
|
||||||
|
ramp-signal-background = #7AA2F7
|
197
configs/bspwm/polybar/modules/separators
Executable file
197
configs/bspwm/polybar/modules/separators
Executable file
@ -0,0 +1,197 @@
|
|||||||
|
; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/dots]
|
||||||
|
type = custom/text
|
||||||
|
content = " "
|
||||||
|
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.RED}
|
||||||
|
content-padding = 0
|
||||||
|
content-font = 5
|
||||||
|
|
||||||
|
; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/pip]
|
||||||
|
type = custom/text
|
||||||
|
content = |
|
||||||
|
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.RED}
|
||||||
|
content-padding = 1
|
||||||
|
content-font = 5
|
||||||
|
|
||||||
|
; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/Lpip]
|
||||||
|
type = custom/text
|
||||||
|
content = "<|"
|
||||||
|
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.RED}
|
||||||
|
content-padding = 1
|
||||||
|
content-font = 5
|
||||||
|
|
||||||
|
; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/Rpip]
|
||||||
|
type = custom/text
|
||||||
|
content = "|>"
|
||||||
|
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.RED}
|
||||||
|
content-padding = 1
|
||||||
|
content-font = 5
|
||||||
|
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/space]
|
||||||
|
type = custom/text
|
||||||
|
content = " "
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/spaceD]
|
||||||
|
type = custom/text
|
||||||
|
content = " "
|
||||||
|
content-background = #353B45
|
||||||
|
content-foreground = #353B45
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/sep]
|
||||||
|
type = custom/text
|
||||||
|
;content = ◆
|
||||||
|
content =
|
||||||
|
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.GREEN}
|
||||||
|
content-padding = 2
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
|
||||||
|
##########################
|
||||||
|
# LD modules #
|
||||||
|
##########################
|
||||||
|
|
||||||
|
[module/LDB]
|
||||||
|
type = custom/text
|
||||||
|
content = "%{T5}%{T-}"
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.MAGENTA}
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
|
||||||
|
[module/LDD]
|
||||||
|
type = custom/text
|
||||||
|
content = "%{T5}█%{T-}"
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = #353B45
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/LDmpd]
|
||||||
|
type = custom/text
|
||||||
|
|
||||||
|
;content = "%{T5}(|%{T-}"
|
||||||
|
content = "%{T5}(%{T-}"
|
||||||
|
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.YELLOW}
|
||||||
|
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/LDcava]
|
||||||
|
type = custom/text
|
||||||
|
|
||||||
|
content = "%{T5}█%{T-}"
|
||||||
|
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.MAGENTA}
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
|
||||||
|
##########################
|
||||||
|
# RD modules #
|
||||||
|
##########################
|
||||||
|
|
||||||
|
[module/RD]
|
||||||
|
type = custom/text
|
||||||
|
content = "%{T5}%{T-}"
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.MAGENTA}
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
|
||||||
|
[module/RDB]
|
||||||
|
type = custom/text
|
||||||
|
content = "%{T5}%{T-}"
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.ALTGREEN}
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/RDD]
|
||||||
|
type = custom/text
|
||||||
|
|
||||||
|
content = "%{T5}█%{T-}"
|
||||||
|
; content = "%{T5}%{T-}"
|
||||||
|
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = #56B6C2
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/RDmpd]
|
||||||
|
type = custom/text
|
||||||
|
|
||||||
|
content = "%{T5})%{T-}"
|
||||||
|
;content = "%{T5}|)%{T-}"
|
||||||
|
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.YELLOW}
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/RDmod]
|
||||||
|
type = custom/text
|
||||||
|
content = "%{T5}%{T-}"
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = ${color.YELLOW}
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
|
||||||
|
##########################
|
||||||
|
# PL modules #
|
||||||
|
##########################
|
||||||
|
|
||||||
|
[module/PLD]
|
||||||
|
type = custom/text
|
||||||
|
|
||||||
|
content = "%{T5}█%{T-}"
|
||||||
|
;content = "%{T5}%{T-}"
|
||||||
|
|
||||||
|
content-font = 3
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = #7AA2F7
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/PLDD]
|
||||||
|
type = custom/text
|
||||||
|
|
||||||
|
content = "%{T5}█%{T-}"
|
||||||
|
;content = "%{T5}%{T-}"
|
||||||
|
|
||||||
|
content-font = 3
|
||||||
|
content-background = ${color.BACKGROUND}
|
||||||
|
content-foreground = #4b70bd
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
11
configs/bspwm/polybar/modules/uparch
Normal file
11
configs/bspwm/polybar/modules/uparch
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
[module/uparch]
|
||||||
|
type = custom/script
|
||||||
|
exec = ~/.config/bspwm/polybar/scripts/uparch.sh
|
||||||
|
interval = 1800
|
||||||
|
format = <label>
|
||||||
|
|
||||||
|
label = "%{A1:kitty --name "uparch_run" --hold -e bash -c "sudo pacman -Syyu" &:} %output%%{A}"
|
||||||
|
|
||||||
|
format-font = 4
|
||||||
|
label-foreground = #7DC5A0
|
||||||
|
|
44
configs/bspwm/polybar/modules/workspaces
Executable file
44
configs/bspwm/polybar/modules/workspaces
Executable file
@ -0,0 +1,44 @@
|
|||||||
|
[module/bspwm]
|
||||||
|
type = internal/bspwm
|
||||||
|
pin-workspaces = true
|
||||||
|
inline-mode = false
|
||||||
|
enable-click = true
|
||||||
|
enable-scroll = false
|
||||||
|
reverse-scroll = false
|
||||||
|
fuzzy-match = true
|
||||||
|
format-font = 2
|
||||||
|
|
||||||
|
label-focused = %name%
|
||||||
|
label-focused-foreground = #7DC5A0
|
||||||
|
label-focused-background = #353B45
|
||||||
|
label-focused-underline = #7DC5A0
|
||||||
|
label-focused-padding = 0
|
||||||
|
|
||||||
|
label-occupied = %name%
|
||||||
|
label-occupied-foreground = #E06C75
|
||||||
|
label-occupied-background = #353B45
|
||||||
|
label-occupied-padding = 0
|
||||||
|
|
||||||
|
label-urgent = %name%
|
||||||
|
label-urgent-foreground = #E5C07B
|
||||||
|
label-urgent-background = #353B45
|
||||||
|
label-urgent-underline = #E5C07B
|
||||||
|
label-urgent-padding = 0
|
||||||
|
|
||||||
|
label-empty = %name%
|
||||||
|
label-empty-foreground = #60ADED
|
||||||
|
label-empty-background = #353B45
|
||||||
|
label-empty-padding = 0
|
||||||
|
|
||||||
|
; Separator in between workspaces
|
||||||
|
label-separator = " "
|
||||||
|
label-separator-padding = 0
|
||||||
|
label-separator-foreground = ${color.ALTBLACK}
|
||||||
|
label-separator-background = #353B45
|
||||||
|
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[module/xwindow]
|
||||||
|
type = internal/xwindow
|
||||||
|
label = %title%
|
||||||
|
label-maxlen = 120
|
47
configs/bspwm/polybar/scripts/health
Executable file
47
configs/bspwm/polybar/scripts/health
Executable file
@ -0,0 +1,47 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
# Select the right temperature file. #
|
||||||
|
for temp_dir in /sys/class/hwmon/*; do
|
||||||
|
[[ "$(< "${temp_dir}/name")" =~ (coretemp|fam15h_power|k10temp) ]] && {
|
||||||
|
temp_dirs=("$temp_dir"/temp*_input)
|
||||||
|
temp_dir=${temp_dirs[0]}
|
||||||
|
break
|
||||||
|
}
|
||||||
|
done
|
||||||
|
|
||||||
|
|
||||||
|
# Get CPU temp. #
|
||||||
|
[[ -f "$temp_dir" ]] && deg="$(($(< "$temp_dir") * 100 / 10000))"
|
||||||
|
|
||||||
|
# Add CPU temp to the output. #
|
||||||
|
if [[ "$cpu_temp" != "off" && "$deg" ]]; then
|
||||||
|
deg="${deg//.}"
|
||||||
|
|
||||||
|
# Convert to Fahrenheit if enabled
|
||||||
|
[[ "$cpu_temp" == "F" ]] && deg="$((deg * 90 / 50 + 320))"
|
||||||
|
|
||||||
|
deg_no_format="${deg/${deg: -1}}"
|
||||||
|
|
||||||
|
# Format the output
|
||||||
|
deg="${deg/${deg: -1}}°${cpu_temp:-C}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# from 0°C to 40°C print ->
|
||||||
|
if [[ "$deg_no_format" -le 40 ]] then
|
||||||
|
# the ' %{T3} ' -> pass font type to polybar config file
|
||||||
|
# the selected font type is number 3, which is (font-3 = "Iosevka:style=bold:"size=12;3" )
|
||||||
|
echo "%{F#7DC5A0}%{T3} %{T2}$deg"
|
||||||
|
|
||||||
|
# from 40°C to 60°C print ->
|
||||||
|
elif [[ "$deg_no_format" -le 60 ]] then
|
||||||
|
echo "%{F#7DC5A0}%{T3} %{T2}$deg"
|
||||||
|
|
||||||
|
# from 60°C to 85°C print ->
|
||||||
|
elif [[ "$deg_no_format" -le 85 ]] then
|
||||||
|
echo "%{F#7DC5A0}%{T3} %{T2}$deg"
|
||||||
|
|
||||||
|
# from 85°C to +... print ->
|
||||||
|
elif [[ "$deg_no_format" -gt 85 ]] then
|
||||||
|
# the ' -n "%{F#FF0008}" ' -> red font as 85°C to +... is the default warn temperature
|
||||||
|
echo -n "%{T3}%{F#FF0008} %{F#FF0008}%{T2}$deg"
|
||||||
|
fi
|
58
configs/bspwm/polybar/scripts/pulse-mic
Executable file
58
configs/bspwm/polybar/scripts/pulse-mic
Executable file
@ -0,0 +1,58 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
status() {
|
||||||
|
MUTED=$(pacmd list-sources | awk '/\*/,EOF {print}' | awk '/muted/ {print $2; exit}')
|
||||||
|
|
||||||
|
if [ "$MUTED" = "yes" ]; then
|
||||||
|
echo -e "%{T4}%{F#FF0008}%{B#353B45} %{T2}muted"
|
||||||
|
else
|
||||||
|
echo -e "%{T4}%{F#80E6FE}%{B#353B45} %{T2}$(pacmd list-sources | grep "\* index:" -A 7 | grep volume | awk -F/ '{print $2}' | tr -d ' ')"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
listen() {
|
||||||
|
status
|
||||||
|
LANG=EN; pactl subscribe | while read -r event;
|
||||||
|
do
|
||||||
|
if echo -e "$event" | grep -q "source" || echo "$event" | grep -q "server"; then
|
||||||
|
status
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
toggle() {
|
||||||
|
MUTED=$(pacmd list-sources | awk '/\*/,EOF {print}' | awk '/muted/ {print $2; exit}')
|
||||||
|
DEFAULT_SOURCE=$(pacmd list-sources | awk '/\*/,EOF {print $3; exit}')
|
||||||
|
|
||||||
|
if [ "$MUTED" = "yes" ]; then
|
||||||
|
pactl set-source-mute "$DEFAULT_SOURCE" 0
|
||||||
|
else
|
||||||
|
pactl set-source-mute "$DEFAULT_SOURCE" 1
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
increase() {
|
||||||
|
DEFAULT_SOURCE=$(pacmd list-sources | awk '/\*/,EOF {print $3; exit}')
|
||||||
|
pactl set-source-volume "$DEFAULT_SOURCE" +5%
|
||||||
|
}
|
||||||
|
|
||||||
|
decrease() {
|
||||||
|
DEFAULT_SOURCE=$(pacmd list-sources | awk '/\*/,EOF {print $3; exit}')
|
||||||
|
pactl set-source-volume "$DEFAULT_SOURCE" -5%
|
||||||
|
}
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
--toggle)
|
||||||
|
toggle
|
||||||
|
;;
|
||||||
|
--increase)
|
||||||
|
increase
|
||||||
|
;;
|
||||||
|
--decrease)
|
||||||
|
decrease
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
listen
|
||||||
|
;;
|
||||||
|
esac
|
12
configs/bspwm/polybar/scripts/uparch.sh
Executable file
12
configs/bspwm/polybar/scripts/uparch.sh
Executable file
@ -0,0 +1,12 @@
|
|||||||
|
#!/bin/zsh
|
||||||
|
|
||||||
|
if ! all_packages_for_update=$(checkupdates 2> /dev/null | wc -l ); then
|
||||||
|
all_packages_for_update=0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$all_packages_for_update" -gt 0 ]; then
|
||||||
|
echo "$all_packages_for_update"
|
||||||
|
else
|
||||||
|
echo "0"
|
||||||
|
fi
|
||||||
|
|
22
configs/bspwm/polybar/utils/colors
Executable file
22
configs/bspwm/polybar/utils/colors
Executable file
@ -0,0 +1,22 @@
|
|||||||
|
[color]
|
||||||
|
|
||||||
|
FOREGROUND = #ABB2BF
|
||||||
|
BACKGROUND = #1E222A
|
||||||
|
BLACK = #4d5361
|
||||||
|
RED = #E06C75
|
||||||
|
GREEN = #98C379
|
||||||
|
YELLOW = #E5C07B
|
||||||
|
BLUE = #61AFEF
|
||||||
|
MAGENTA = #C678DD
|
||||||
|
CYAN = #56B6C2
|
||||||
|
WHITE = #ABB2BF
|
||||||
|
ALTBLACK = #4d5361
|
||||||
|
ALTRED = #E06C75
|
||||||
|
ALTGREEN = #98C379
|
||||||
|
ALTYELLOW = #E5C07B
|
||||||
|
ALTBLUE = #61AFEF
|
||||||
|
ALTMAGENTA = #C678DD
|
||||||
|
ALTCYAN = #56B6C2
|
||||||
|
ALTWHITE = #ABB2BF
|
||||||
|
|
||||||
|
tray-background = #353B45
|
24
configs/bspwm/polybar/utils/system
Executable file
24
configs/bspwm/polybar/utils/system
Executable file
@ -0,0 +1,24 @@
|
|||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
;;
|
||||||
|
;; System Variables (Edit according to your system)
|
||||||
|
;;
|
||||||
|
;; Warning : Не удалять это файл
|
||||||
|
;; Warning : Переменные для него записываются в launch.sh
|
||||||
|
;;
|
||||||
|
;; Run `ls -1 /sys/class/power_supply/` to list list batteries and adapters.
|
||||||
|
;; Run `ls -1 /sys/class/backlight/` to list available graphics cards.
|
||||||
|
;; Run `ip link | awk '/state UP/ {print $2}' | tr -d :` to get active network interface.
|
||||||
|
;;
|
||||||
|
;; Polybar Variables For Modules :
|
||||||
|
;; card = ${system.graphics_card}
|
||||||
|
;; battery = BAT0
|
||||||
|
;; adapter = AC
|
||||||
|
;; interface = ${system.network_interface}
|
||||||
|
;;
|
||||||
|
;; _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
|
||||||
|
|
||||||
|
[system]
|
||||||
|
adapter = AC
|
||||||
|
battery = BAT0
|
||||||
|
graphics_card = intel_backlight
|
||||||
|
network_interface = enp42s0
|
97
configs/bspwm/rofi/bin/calendar
Executable file
97
configs/bspwm/rofi/bin/calendar
Executable file
@ -0,0 +1,97 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
DIR=$(dirname $PWD)
|
||||||
|
|
||||||
|
current_day=$(date +"%e")
|
||||||
|
current_month=$(date +"%m")
|
||||||
|
current_year=$(date +"%Y")
|
||||||
|
|
||||||
|
month=$(date +"%-m")
|
||||||
|
year=$(date +"%Y")
|
||||||
|
previous_month="◀"
|
||||||
|
next_month="▶"
|
||||||
|
last_selected_option=""
|
||||||
|
|
||||||
|
format_calendar () {
|
||||||
|
echo "$1" \
|
||||||
|
| sed -E 's/([[:alpha:]])__/\1\n/g' \
|
||||||
|
| sed -E 's/___([[:digit:]])/.\n\1/g' \
|
||||||
|
| sed -e 's/___/\n./g' \
|
||||||
|
| sed -e 's/__/\n/g' \
|
||||||
|
| sed -e 's/_/\n/g'
|
||||||
|
}
|
||||||
|
|
||||||
|
print_month() {
|
||||||
|
calendar="$(cal --monday -v -- $1 $2 | tail -n +2 | sed -e 's/ /_/g')"
|
||||||
|
echo "$(format_calendar "$calendar")"
|
||||||
|
}
|
||||||
|
|
||||||
|
find_day_index() {
|
||||||
|
index=0
|
||||||
|
while IFS=' ' read -ra arr; do
|
||||||
|
for i in "${arr[@]}"; do
|
||||||
|
if [[ "$i" == "$2" ]]; then
|
||||||
|
echo "$index"
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
((index++))
|
||||||
|
done
|
||||||
|
done <<< "$1"
|
||||||
|
}
|
||||||
|
|
||||||
|
calendar_menu() {
|
||||||
|
calendar_header=$(cal -v -- $month $year | head -n 1)
|
||||||
|
|
||||||
|
month_page="$(print_month $month $year)"
|
||||||
|
calendar_body="\n\n\n$previous_month\n\n\n\n$month_page\n\n\n\n$next_month\n\n\n"
|
||||||
|
|
||||||
|
previous_month_index="3"
|
||||||
|
next_month_index="59"
|
||||||
|
calendar_body_column="7"
|
||||||
|
urgent="-u $previous_month_index,$next_month_index"
|
||||||
|
active=""
|
||||||
|
selected_row=""
|
||||||
|
|
||||||
|
if [[ "$(echo $current_month | bc) $current_year" == "$(echo $month | bc) $year" ]]; then
|
||||||
|
current_day_index=$(($(find_day_index "$month_page" $current_day) + $calendar_body_column))
|
||||||
|
active="-a $current_day_index"
|
||||||
|
selected_row="-selected-row $current_day_index"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ $last_selected_option == $previous_month ]]; then
|
||||||
|
selected_row="-selected-row $previous_month_index"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ $last_selected_option == $next_month ]]; then
|
||||||
|
selected_row="-selected-row $next_month_index"
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo -e "$calendar_body" | rofi -dmenu \
|
||||||
|
-theme /home/chatlanin/.config/bspwm/rofi/themes/calendar.rasi\
|
||||||
|
-p "$calendar_header" $urgent $active $selected_row
|
||||||
|
}
|
||||||
|
|
||||||
|
while [[ true ]]; do
|
||||||
|
selected=$(calendar_menu)
|
||||||
|
last_selected_option="$selected"
|
||||||
|
case $selected in
|
||||||
|
$previous_month)
|
||||||
|
((month--))
|
||||||
|
if [[ $month -lt 1 ]]; then
|
||||||
|
month=12
|
||||||
|
((year--))
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
$next_month)
|
||||||
|
((month++))
|
||||||
|
if [[ $month -gt 12 ]]; then
|
||||||
|
month=1
|
||||||
|
((year++))
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
break
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
7
configs/bspwm/rofi/bin/confirm
Executable file
7
configs/bspwm/rofi/bin/confirm
Executable file
@ -0,0 +1,7 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
rofi -dmenu\
|
||||||
|
-i\
|
||||||
|
-no-fixed-num-lines\
|
||||||
|
-p "Are You Sure? : "\
|
||||||
|
-theme ~/.config/bspwm/rofi/themes/confirm.rasi
|
42
configs/bspwm/rofi/bin/launcher
Executable file
42
configs/bspwm/rofi/bin/launcher
Executable file
@ -0,0 +1,42 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
DIR="$HOME/.config/bspwm"
|
||||||
|
|
||||||
|
rofi \
|
||||||
|
-show drun \
|
||||||
|
-modi run,drun,ssh,filebrowser,window \
|
||||||
|
-no-lazy-grab \
|
||||||
|
-scroll-method 0 \
|
||||||
|
-drun-match-fields all \
|
||||||
|
-no-drun-show-actions \
|
||||||
|
-terminal kitty \
|
||||||
|
-kb-cancel Escape \
|
||||||
|
-theme "$DIR"/rofi/themes/launcher.rasi
|
||||||
|
|
||||||
|
# rofi \
|
||||||
|
# -show drun \
|
||||||
|
# -modi run,drun,ssh,filebrowser,window \
|
||||||
|
# -no-lazy-grab \
|
||||||
|
# -scroll-method 0 \
|
||||||
|
# -drun-match-fields all \
|
||||||
|
# -drun-display-format "{name}" \
|
||||||
|
# -no-drun-show-actions \
|
||||||
|
# -terminal alacritty \
|
||||||
|
# -kb-cancel Alt-F1 \
|
||||||
|
# -theme "$DIR"/rofi/themes/launcher.rasi
|
||||||
|
# -show drun: Этот флаг указывает на то, что rofi должен отображать список запускаемых приложений.
|
||||||
|
# -modi run,drun,ssh,filebrowser,window: Здесь задан список модов, которые необходимо использовать в rofi.
|
||||||
|
# Моды определяют способы взаимодействия с различными типами данных.
|
||||||
|
# В данном случае используются моды запуска приложений (run и drun), подключения
|
||||||
|
# к SSH (ssh), работы с файловой системой (filebrowser) и работы с открытыми окнами (window).
|
||||||
|
# -no-lazy-grab: Этот флаг отключает "ленивый захват". Когда этот флаг активен, rofi будет активироваться сразу при вызове, а не
|
||||||
|
# ожидать, пока пользователь не начнет вводить текст.
|
||||||
|
# -scroll-method 0: Здесь задан метод прокрутки для rofi. Значение 0 указывает на "линейную" прокрутку, в которой каждый
|
||||||
|
# элемент списка прокручивается по одному за раз.
|
||||||
|
# -drun-match-fields all: Этот флаг указывает rofi, что необходимо учитывать все поля при сопоставлении приложений с вводимым пользователем текстом.
|
||||||
|
# -drun-display-format "{name}": Здесь устанавливается формат отображения приложений в результатах поиска. В данном случае используется только имя приложения.
|
||||||
|
# -no-drun-show-actions: Этот флаг отключает отображение действий для приложений в результатах поиска.
|
||||||
|
# -terminal kitty: Этот флаг указывает rofi использовать терминал с именем "kitty" для запуска приложений, по умолчанию оно использует терминал по умолчанию.
|
||||||
|
# -kb-cancel Escape: Этот флаг назначает клавишу "Escape" для отмены rofi.
|
||||||
|
# -theme "$DIR"/rofi/themes/launcher.rasi: Здесь задается путь к теме оформления для rofi. Знак доллара и фигурные скобки используются для
|
||||||
|
# разрешения переменной окружения $DIR, которая, вероятно, содержит путь к каталогу со скриптом.
|
66
configs/bspwm/rofi/bin/network
Executable file
66
configs/bspwm/rofi/bin/network
Executable file
@ -0,0 +1,66 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
DIR="$HOME/.config/bspwm"
|
||||||
|
|
||||||
|
rofi_command="rofi -theme $DIR/rofi/themes/network.rasi"
|
||||||
|
|
||||||
|
# Get info #
|
||||||
|
IFACE="$(nmcli | grep -i interface | awk '/interface/ {print $2}')"
|
||||||
|
SSID="$(iwgetid -r)"
|
||||||
|
LIP="$(nmcli | grep -i server | awk '/server/ {print $2}')"
|
||||||
|
PIP="$(dig +short myip.opendns.com @resolver1.opendns.com )"
|
||||||
|
STATUS="$(nmcli radio wifi)"
|
||||||
|
|
||||||
|
active=""
|
||||||
|
urgent=""
|
||||||
|
|
||||||
|
if (ping -c 1 archlinux.org || ping -c 1 google.com || ping -c 1 bitbucket.org || ping -c 1 github.com || ping -c 1 sourceforge.net) &>/dev/null; then
|
||||||
|
if [[ $STATUS == *"enable"* ]]; then
|
||||||
|
if [[ $IFACE == e* ]]; then
|
||||||
|
connected=""
|
||||||
|
else
|
||||||
|
connected=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
active="-a 0"
|
||||||
|
SSID="$(iwgetid -r)"
|
||||||
|
PIP="$(wget --timeout=30 http://ipinfo.io/ip -qO -)"
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
urgent="-u 0"
|
||||||
|
SSID="Disconnected"
|
||||||
|
PIP="NA"
|
||||||
|
connected=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Icons #
|
||||||
|
bmon=""
|
||||||
|
launch_cli=""
|
||||||
|
launch=""
|
||||||
|
|
||||||
|
options="$connected\n$bmon\n$launch_cli\n$launch"
|
||||||
|
|
||||||
|
# Main #
|
||||||
|
chosen="$(echo -e "$options" | $rofi_command -p "$SSID : $PIP" -dmenu $active $urgent -selected-row 1)"
|
||||||
|
case $chosen in
|
||||||
|
$connected)
|
||||||
|
if [[ $STATUS == *"enable"* ]]; then
|
||||||
|
nmcli radio wifi off
|
||||||
|
else
|
||||||
|
nmcli radio wifi on
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
|
||||||
|
$bmon)
|
||||||
|
alacritty --class 'alacritty-float,alacritty-float' --config-file ~/.config/bspwm/alacritty/alacritty.toml -e bmon
|
||||||
|
;;
|
||||||
|
|
||||||
|
$launch_cli)
|
||||||
|
alacritty --class 'alacritty-float,alacritty-float' --config-file ~/.config/bspwm/alacritty/alacritty.toml -e nmtui
|
||||||
|
;;
|
||||||
|
|
||||||
|
$launch)
|
||||||
|
nm-connection-editor
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
116
configs/bspwm/rofi/bin/powermenu
Executable file
116
configs/bspwm/rofi/bin/powermenu
Executable file
@ -0,0 +1,116 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Current Theme #
|
||||||
|
dir="$HOME/.config/bspwm/rofi/themes"
|
||||||
|
theme="${dir}/powermenu"
|
||||||
|
|
||||||
|
# Theme Elements #
|
||||||
|
prompt="`hostname`"
|
||||||
|
mesg="Uptime : `uptime -p | sed -e 's/up //g'`"
|
||||||
|
|
||||||
|
list_col='1'
|
||||||
|
# list_row='7'
|
||||||
|
list_row='3'
|
||||||
|
|
||||||
|
# Options #
|
||||||
|
# option_1=" Lock"
|
||||||
|
# option_2=" Logout"
|
||||||
|
# option_3=" Suspend"
|
||||||
|
# option_4=" Hibernate"
|
||||||
|
option_5=" Reboot"
|
||||||
|
option_6=" Shutdown"
|
||||||
|
yes='✔ Yes'
|
||||||
|
no='✘ No'
|
||||||
|
|
||||||
|
# Rofi CMD #
|
||||||
|
rofi_cmd() {
|
||||||
|
#echo -e "${option_1}\n${option_2}\n${option_3}\n${option_4}\n${option_5}\n${option_6}\n${mesg}" |
|
||||||
|
echo -e "${option_5}\n${option_6}\n${mesg}" |
|
||||||
|
rofi -theme-str "listview {columns: $list_col; lines: $list_row;}" \
|
||||||
|
-dmenu \
|
||||||
|
-p "$prompt" \
|
||||||
|
-markup-rows \
|
||||||
|
-theme ${theme}
|
||||||
|
}
|
||||||
|
|
||||||
|
# Pass variables to rofi dmenu #
|
||||||
|
run_rofi() {
|
||||||
|
#echo -e "$option_1\n$option_2\n$option_3\n$option_4\n$option_5\n$option_6" | rofi_cmd
|
||||||
|
echo -e "$option_5\n$option_6" | rofi_cmd
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# Confirmation CMD #
|
||||||
|
confirm_cmd() {
|
||||||
|
rofi -theme-str 'window {location: center; anchor: center; fullscreen: false; width: 250px; height: 170;}' \
|
||||||
|
-theme-str 'mainbox {orientation: vertical; children: [ "message", "listview" ];}' \
|
||||||
|
-theme-str 'listview {columns: 2; lines: 1;}' \
|
||||||
|
-theme-str 'element-text {horizontal-align: 0.5;}' \
|
||||||
|
-theme-str 'textbox {horizontal-align: 0.5;}' \
|
||||||
|
-dmenu \
|
||||||
|
-p 'Confirmation' \
|
||||||
|
-mesg 'Are you Sure?' \
|
||||||
|
-theme ${theme}
|
||||||
|
}
|
||||||
|
|
||||||
|
# Ask for confirmation #
|
||||||
|
confirm_exit() {
|
||||||
|
echo -e "$yes\n$no" | confirm_cmd
|
||||||
|
}
|
||||||
|
|
||||||
|
# Confirm and execute #
|
||||||
|
confirm_run () {
|
||||||
|
selected="$(confirm_exit)"
|
||||||
|
if [[ "$selected" == "$yes" ]]; then
|
||||||
|
${1} && ${2} && ${3}
|
||||||
|
else
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# Execute Command #
|
||||||
|
run_cmd() {
|
||||||
|
# if [[ "$1" == '--opt1' ]]; then
|
||||||
|
# betterlockscreen -l
|
||||||
|
# elif [[ "$1" == '--opt2' ]]; then
|
||||||
|
# confirm_run 'kill -9 -1'
|
||||||
|
# elif [[ "$1" == '--opt3' ]]; then
|
||||||
|
# confirm_run 'mpc -q pause' 'amixer set Master mute' 'systemctl suspend'
|
||||||
|
# elif [[ "$1" == '--opt4' ]]; then
|
||||||
|
# confirm_run 'systemctl hibernate'
|
||||||
|
# elif [[ "$1" == '--opt5' ]]; then
|
||||||
|
# confirm_run 'systemctl reboot'
|
||||||
|
# elif [[ "$1" == '--opt6' ]]; then
|
||||||
|
# confirm_run 'systemctl poweroff'
|
||||||
|
# fi
|
||||||
|
if [[ "$1" == '--opt5' ]]; then
|
||||||
|
confirm_run 'systemctl reboot'
|
||||||
|
elif [[ "$1" == '--opt6' ]]; then
|
||||||
|
confirm_run 'systemctl poweroff'
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# Actions #
|
||||||
|
chosen="$(run_rofi)"
|
||||||
|
case ${chosen} in
|
||||||
|
# $option_1)
|
||||||
|
# run_cmd --opt1
|
||||||
|
# ;;
|
||||||
|
# $option_2)
|
||||||
|
# run_cmd --opt2
|
||||||
|
# ;;
|
||||||
|
# $option_3)
|
||||||
|
# run_cmd --opt3
|
||||||
|
# ;;
|
||||||
|
# $option_4)
|
||||||
|
# run_cmd --opt4
|
||||||
|
# ;;
|
||||||
|
$option_5)
|
||||||
|
run_cmd --opt5
|
||||||
|
;;
|
||||||
|
$option_6)
|
||||||
|
run_cmd --opt6
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
207
configs/bspwm/rofi/bin/screenshot
Executable file
207
configs/bspwm/rofi/bin/screenshot
Executable file
@ -0,0 +1,207 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Import Current Theme #
|
||||||
|
DIR="$HOME/.config/bspwm"
|
||||||
|
ROFI_THEME="$DIR/rofi/themes/screenshot.rasi"
|
||||||
|
|
||||||
|
# Theme Elements #
|
||||||
|
prompt='Screenshot Tool'
|
||||||
|
mesg="Screenshots are saved in the :
|
||||||
|
\``xdg-user-dir PICTURES`/Screenshots\` Directory"
|
||||||
|
|
||||||
|
# Options #
|
||||||
|
layout=$(cat "${ROFI_THEME}" | grep 'USE_ICON' | cut -d'=' -f2)
|
||||||
|
|
||||||
|
if [[ "$layout" == 'NO' ]]; then
|
||||||
|
option_1=" Capture an Area"
|
||||||
|
option_2=" Capture a Window"
|
||||||
|
option_3=" Capture a Desktop"
|
||||||
|
option_4=" Capture a Monitor"
|
||||||
|
option_5=" Capture in 5s"
|
||||||
|
option_6=" Capture a Monitor in 5s"
|
||||||
|
else
|
||||||
|
option_1=""
|
||||||
|
option_2=""
|
||||||
|
option_3=""
|
||||||
|
option_4=""
|
||||||
|
option_5=""
|
||||||
|
option_6=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Rofi CMD #
|
||||||
|
rofi_cmd() {
|
||||||
|
rofi -dmenu \
|
||||||
|
-p "$prompt" \
|
||||||
|
-mesg "$mesg" \
|
||||||
|
-markup-rows \
|
||||||
|
-theme "${ROFI_THEME}"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Pass variables to rofi dmenu #
|
||||||
|
run_rofi() {
|
||||||
|
echo -e "$option_1\n$option_3\n$option_5\n$option_2\n$option_4\n$option_6" | rofi_cmd
|
||||||
|
}
|
||||||
|
|
||||||
|
# Screenshot #
|
||||||
|
time=$(date +%Y-%m-%d-%H-%M-%S)
|
||||||
|
geometry=$(xrandr | grep 'connected' | awk '{print $3}' | tr 'x' '\n' | sort -nr | awk 'NR==1')
|
||||||
|
dir="`xdg-user-dir PICTURES`/Screenshots"
|
||||||
|
file="Screenshot_${time}_${geometry}.png"
|
||||||
|
|
||||||
|
# Directory #
|
||||||
|
if [[ ! -d "$dir" ]]; then
|
||||||
|
mkdir -p "$dir"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# notify and view screenshot #
|
||||||
|
notify_view() {
|
||||||
|
notify_cmd_shot="dunstify -u low -h string:x-dunst-stack-tag:obscreenshot -i ${dir}/${file}"
|
||||||
|
${notify_cmd_shot} "Copied to clipboard."
|
||||||
|
paplay /usr/share/sounds/freedesktop/stereo/screen-capture.oga &>/dev/null &
|
||||||
|
viewnior "${dir}/$file"
|
||||||
|
|
||||||
|
if [[ -e "$dir/$file" ]]; then
|
||||||
|
${notify_cmd_shot} "Screenshot Saved."
|
||||||
|
else
|
||||||
|
${notify_cmd_shot} "Screenshot Deleted."
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# Copy screenshot to clipboard #
|
||||||
|
copy_shot () {
|
||||||
|
tee "$file" | xclip -selection clipboard -t image/png
|
||||||
|
}
|
||||||
|
|
||||||
|
# countdown #
|
||||||
|
countdown () {
|
||||||
|
for sec in $(seq "$1" -1 1); do
|
||||||
|
dunstify -t 1000 -h string:x-dunst-stack-tag:screenshottimer -i /usr/share/icons/dunst/timer.png "Taking shot in : $sec"
|
||||||
|
sleep 1
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
# take shots #
|
||||||
|
shotnow () {
|
||||||
|
cd "${dir}" && sleep 0.5 && maim -u -f png | copy_shot
|
||||||
|
notify_view
|
||||||
|
}
|
||||||
|
|
||||||
|
shot5 () {
|
||||||
|
countdown '5'
|
||||||
|
sleep 1 && cd "${dir}" && maim -u -f png | copy_shot
|
||||||
|
notify_view
|
||||||
|
}
|
||||||
|
|
||||||
|
shotMon5 () {
|
||||||
|
MONITORS=$(xrandr | grep -o '[0-9]*x[0-9]*[+-][0-9]*[+-][0-9]*')
|
||||||
|
# Get the location of the mouse #
|
||||||
|
XMOUSE=$(xdotool getmouselocation | awk -F "[: ]" '{print $2}')
|
||||||
|
YMOUSE=$(xdotool getmouselocation | awk -F "[: ]" '{print $4}')
|
||||||
|
|
||||||
|
for mon in ${MONITORS}; do
|
||||||
|
# Parse the geometry of the monitor #
|
||||||
|
MONW=$(echo ${mon} | awk -F "[x+]" '{print $1}')
|
||||||
|
MONH=$(echo ${mon} | awk -F "[x+]" '{print $2}')
|
||||||
|
MONX=$(echo ${mon} | awk -F "[x+]" '{print $3}')
|
||||||
|
MONY=$(echo ${mon} | awk -F "[x+]" '{print $4}')
|
||||||
|
|
||||||
|
# Use a simple collision check #
|
||||||
|
if (( ${XMOUSE} >= ${MONX} )); then
|
||||||
|
if (( ${XMOUSE} <= ${MONX}+${MONW} )); then
|
||||||
|
if (( ${YMOUSE} >= ${MONY} )); then
|
||||||
|
if (( ${YMOUSE} <= ${MONY}+${MONH} )); then
|
||||||
|
# We have found our monitor! #
|
||||||
|
GEOMETRY=${MONW}x${MONH}+${MONX}+${MONY}
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
countdown '5'
|
||||||
|
sleep 1
|
||||||
|
cd ${dir} && maim -u -f png -g ${GEOMETRY} | copy_shot
|
||||||
|
notify_view
|
||||||
|
}
|
||||||
|
|
||||||
|
shotwin () {
|
||||||
|
cd "${dir}" && maim -u -f png -i "$(xdotool getactivewindow)" | copy_shot
|
||||||
|
notify_view
|
||||||
|
}
|
||||||
|
|
||||||
|
shotarea () {
|
||||||
|
cd "${dir}" && maim -u -f png -s -b 2 -c 0.35,0.55,0.85,0.25 -l | copy_shot
|
||||||
|
notify_view
|
||||||
|
}
|
||||||
|
|
||||||
|
shotmonitor () {
|
||||||
|
MONITORS=$(xrandr | grep -o '[0-9]*x[0-9]*[+-][0-9]*[+-][0-9]*')
|
||||||
|
# Get the location of the mouse #
|
||||||
|
XMOUSE=$(xdotool getmouselocation | awk -F "[: ]" '{print $2}')
|
||||||
|
YMOUSE=$(xdotool getmouselocation | awk -F "[: ]" '{print $4}')
|
||||||
|
|
||||||
|
for mon in ${MONITORS}; do
|
||||||
|
# Parse the geometry of the monitor #
|
||||||
|
MONW=$(echo ${mon} | awk -F "[x+]" '{print $1}')
|
||||||
|
MONH=$(echo ${mon} | awk -F "[x+]" '{print $2}')
|
||||||
|
MONX=$(echo ${mon} | awk -F "[x+]" '{print $3}')
|
||||||
|
MONY=$(echo ${mon} | awk -F "[x+]" '{print $4}')
|
||||||
|
|
||||||
|
# Use a simple collision check #
|
||||||
|
if (( ${XMOUSE} >= ${MONX} )); then
|
||||||
|
if (( ${XMOUSE} <= ${MONX}+${MONW} )); then
|
||||||
|
if (( ${YMOUSE} >= ${MONY} )); then
|
||||||
|
if (( ${YMOUSE} <= ${MONY}+${MONH} )); then
|
||||||
|
# We have found our monitor! #
|
||||||
|
GEOMETRY=${MONW}x${MONH}+${MONX}+${MONY}
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
sleep 1
|
||||||
|
cd ${dir} && maim -u -f png -g ${GEOMETRY} | copy_shot
|
||||||
|
notify_view
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# Execute Command #
|
||||||
|
run_cmd() {
|
||||||
|
if [[ "$1" == '--opt1' ]]; then
|
||||||
|
shotarea
|
||||||
|
elif [[ "$1" == '--opt2' ]]; then
|
||||||
|
shotwin
|
||||||
|
elif [[ "$1" == '--opt3' ]]; then
|
||||||
|
shotnow
|
||||||
|
elif [[ "$1" == '--opt4' ]]; then
|
||||||
|
shotmonitor
|
||||||
|
elif [[ "$1" == '--opt5' ]]; then
|
||||||
|
shot5
|
||||||
|
elif [[ "$1" == '--opt6' ]]; then
|
||||||
|
shotMon5
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# Actions #
|
||||||
|
chosen="$(run_rofi)"
|
||||||
|
case ${chosen} in
|
||||||
|
$option_1)
|
||||||
|
run_cmd --opt1
|
||||||
|
;;
|
||||||
|
$option_2)
|
||||||
|
run_cmd --opt2
|
||||||
|
;;
|
||||||
|
$option_3)
|
||||||
|
run_cmd --opt3
|
||||||
|
;;
|
||||||
|
$option_4)
|
||||||
|
run_cmd --opt4
|
||||||
|
;;
|
||||||
|
$option_5)
|
||||||
|
run_cmd --opt5
|
||||||
|
;;
|
||||||
|
$option_6)
|
||||||
|
run_cmd --opt6
|
||||||
|
;;
|
||||||
|
esac
|
6
configs/bspwm/rofi/bin/windows
Executable file
6
configs/bspwm/rofi/bin/windows
Executable file
@ -0,0 +1,6 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# показывает менюшку с быстрым переходам к запущеным программам
|
||||||
|
|
||||||
|
DIR="$HOME/.config/bspwm"
|
||||||
|
rofi -no-lazy-grab -show window -theme $DIR/rofi/themes/window.rasi
|
24
configs/bspwm/rofi/themes/askpass.rasi
Executable file
24
configs/bspwm/rofi/themes/askpass.rasi
Executable file
@ -0,0 +1,24 @@
|
|||||||
|
@import "colors.rasi"
|
||||||
|
|
||||||
|
*{
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
font: "Iosevka 10";
|
||||||
|
}
|
||||||
|
|
||||||
|
window {
|
||||||
|
width: 350px;
|
||||||
|
padding: 20px;
|
||||||
|
border: 2px;
|
||||||
|
border-radius: 0px;
|
||||||
|
border-color: @selected;
|
||||||
|
location: center;
|
||||||
|
x-offset: 0;
|
||||||
|
y-offset: -4%;
|
||||||
|
}
|
||||||
|
|
||||||
|
entry {
|
||||||
|
expand: true;
|
||||||
|
width: 200px;
|
||||||
|
text-color: @selected;
|
||||||
|
}
|
158
configs/bspwm/rofi/themes/calendar.rasi
Executable file
158
configs/bspwm/rofi/themes/calendar.rasi
Executable file
@ -0,0 +1,158 @@
|
|||||||
|
*{
|
||||||
|
background: #1E1E2F;
|
||||||
|
foreground: #BA969B;
|
||||||
|
selected: #4b70bd;
|
||||||
|
urgent: #D4BC6C;
|
||||||
|
on: #7AA2F7;
|
||||||
|
off: #7AA2F7;
|
||||||
|
}
|
||||||
|
|
||||||
|
configuration {
|
||||||
|
font: "Iosevka 12";
|
||||||
|
show-icons: false;
|
||||||
|
icon-theme: "Papirus";
|
||||||
|
display-drun: ":";
|
||||||
|
drun-display-format: "{name}";
|
||||||
|
threads: 0;
|
||||||
|
scroll-method: 0;
|
||||||
|
disable-history: false;
|
||||||
|
fullscreen: false;
|
||||||
|
hide-scrollbar: true;
|
||||||
|
sidebar-mode: false;
|
||||||
|
}
|
||||||
|
|
||||||
|
window {
|
||||||
|
transparency: "real";
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
border: 1px;
|
||||||
|
border-radius: 0px;
|
||||||
|
border-color: @selected;
|
||||||
|
width: 384px;
|
||||||
|
location: northwest;
|
||||||
|
y-offset: 50;
|
||||||
|
x-offset: 3433;
|
||||||
|
}
|
||||||
|
|
||||||
|
prompt {
|
||||||
|
enabled: true;
|
||||||
|
padding: 4px 4px 6px 6px;
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox-prompt-colon {
|
||||||
|
expand: false;
|
||||||
|
str: "";
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @urgent;
|
||||||
|
padding: 5px 0px 0px 4px;
|
||||||
|
font: "feather 10";
|
||||||
|
}
|
||||||
|
|
||||||
|
inputbar {
|
||||||
|
children: [ textbox-prompt-colon, prompt ];
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
expand: false;
|
||||||
|
border: 0px 0px 1px 0px;
|
||||||
|
border-radius: 0px;
|
||||||
|
border-color: @selected;
|
||||||
|
margin: 0px 0px 0px 0px;
|
||||||
|
padding: 0px 0px 0px 0px;
|
||||||
|
position: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
entry {
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
placeholder-color: @foreground;
|
||||||
|
expand: true;
|
||||||
|
horizontal-align: 0;
|
||||||
|
placeholder: "Search";
|
||||||
|
blink: true;
|
||||||
|
padding: 4px 0px 0px 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
case-indicator {
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
spacing: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
listview {
|
||||||
|
background-color: @background;
|
||||||
|
columns: 9;
|
||||||
|
lines: 7;
|
||||||
|
spacing: 5px;
|
||||||
|
cycle: true;
|
||||||
|
dynamic: true;
|
||||||
|
layout: vertical;
|
||||||
|
}
|
||||||
|
|
||||||
|
mainbox {
|
||||||
|
background-color: @background;
|
||||||
|
children: [ inputbar, listview ];
|
||||||
|
spacing: 5px;
|
||||||
|
padding: 5px 5px 5px 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element {
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
orientation: horizontal;
|
||||||
|
border: 0px;
|
||||||
|
border-radius: 0px;
|
||||||
|
border-color: @selected;
|
||||||
|
padding: 5px 5px 5px 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-icon {
|
||||||
|
size: 24px;
|
||||||
|
border: 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-text {
|
||||||
|
font: "Iosevka 12";
|
||||||
|
expand: true;
|
||||||
|
horizontal-align: 0;
|
||||||
|
vertical-align: 0;
|
||||||
|
margin: 2px 0px 2px 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element selected {
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
border: 0px;
|
||||||
|
border-radius: 0px;
|
||||||
|
border-color: @selected;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.active,
|
||||||
|
element.selected.urgent {
|
||||||
|
background-color: @on;
|
||||||
|
text-color: @background;
|
||||||
|
border-color: @on;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.selected.urgent {
|
||||||
|
border-color: @urgent;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.urgent,
|
||||||
|
element.selected.active {
|
||||||
|
background-color: @off;
|
||||||
|
text-color: @background;
|
||||||
|
border-color: @off;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.selected.active {
|
||||||
|
border-color: @selected;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-text, element-icon {
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
}
|
10
configs/bspwm/rofi/themes/colors.rasi
Executable file
10
configs/bspwm/rofi/themes/colors.rasi
Executable file
@ -0,0 +1,10 @@
|
|||||||
|
*{
|
||||||
|
background: #1E222A;
|
||||||
|
background-alt: #4d5361;
|
||||||
|
foreground: #ABB2BF;
|
||||||
|
selected: #61AFEF;
|
||||||
|
highlight: #56B6C2;
|
||||||
|
urgent: #E06C75;
|
||||||
|
on: #98C379;
|
||||||
|
off: #E06C75;
|
||||||
|
}
|
24
configs/bspwm/rofi/themes/confirm.rasi
Executable file
24
configs/bspwm/rofi/themes/confirm.rasi
Executable file
@ -0,0 +1,24 @@
|
|||||||
|
@import "colors.rasi"
|
||||||
|
|
||||||
|
*{
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
font: "Iosevka 10";
|
||||||
|
}
|
||||||
|
|
||||||
|
window {
|
||||||
|
width: 200px;
|
||||||
|
padding: 20px;
|
||||||
|
border: 2px;
|
||||||
|
border-radius: 10px;
|
||||||
|
border-color: @selected;
|
||||||
|
location: center;
|
||||||
|
x-offset: 0;
|
||||||
|
y-offset: -4%;
|
||||||
|
}
|
||||||
|
|
||||||
|
entry {
|
||||||
|
expand: true;
|
||||||
|
width: 150px;
|
||||||
|
text-color: @selected;
|
||||||
|
}
|
100
configs/bspwm/rofi/themes/launcher.rasi
Executable file
100
configs/bspwm/rofi/themes/launcher.rasi
Executable file
@ -0,0 +1,100 @@
|
|||||||
|
*{
|
||||||
|
background: #181826;
|
||||||
|
background-alt: #181826;
|
||||||
|
border: #181826;
|
||||||
|
foreground: #d2daf4;
|
||||||
|
accent: #78DBA9;
|
||||||
|
}
|
||||||
|
|
||||||
|
configuration {
|
||||||
|
show-icons: true;
|
||||||
|
display-drun: "Applications";
|
||||||
|
drun-display-format: "{name}";
|
||||||
|
disable-history: false;
|
||||||
|
hide-scrollbar: true;
|
||||||
|
sidebar-mode: false;
|
||||||
|
}
|
||||||
|
|
||||||
|
window {
|
||||||
|
transparency: "real";
|
||||||
|
font: "Iosevka Nerd Font 11";
|
||||||
|
width: 36%;
|
||||||
|
}
|
||||||
|
|
||||||
|
entry {
|
||||||
|
background-color: @background-alt;
|
||||||
|
text-color: @foreground;
|
||||||
|
placeholder-color: @foreground;
|
||||||
|
expand: true;
|
||||||
|
horizontal-align: 0;
|
||||||
|
placeholder: " Type here to search...";
|
||||||
|
padding: 7px;
|
||||||
|
margin: 0 1%;
|
||||||
|
blink: true;
|
||||||
|
border: 0px 0px 2px 0px;
|
||||||
|
border-radius: 0px;
|
||||||
|
border-color: @accent;
|
||||||
|
}
|
||||||
|
|
||||||
|
inputbar {
|
||||||
|
children: [ entry ];
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @background;
|
||||||
|
expand: false;
|
||||||
|
margin: 0px 0px 0px 0px;
|
||||||
|
padding: 1%;
|
||||||
|
}
|
||||||
|
|
||||||
|
listview {
|
||||||
|
background-color: @background;
|
||||||
|
padding: 10px;
|
||||||
|
columns: 4;
|
||||||
|
lines: 3;
|
||||||
|
spacing: 0%;
|
||||||
|
cycle: false;
|
||||||
|
dynamic: true;
|
||||||
|
layout: vertical;
|
||||||
|
}
|
||||||
|
|
||||||
|
mainbox {
|
||||||
|
background-color: @background;
|
||||||
|
children: [ inputbar, listview ];
|
||||||
|
spacing: 0%;
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element {
|
||||||
|
orientation: vertical;
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
border-radius: 0%;
|
||||||
|
padding: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-icon, element-text {
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-icon {
|
||||||
|
horizontal-align: 0.5;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
size: 32px;
|
||||||
|
border: 16px;
|
||||||
|
border-color: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-text {
|
||||||
|
expand: true;
|
||||||
|
horizontal-align: 0.5;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
margin: -12px 0px 12px 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element selected {
|
||||||
|
background-color: @background-alt;
|
||||||
|
text-color: @foreground;
|
||||||
|
border: 0px 0px 2px 0px;
|
||||||
|
border-color: @border;
|
||||||
|
border-radius: 0px;
|
||||||
|
}
|
153
configs/bspwm/rofi/themes/network.rasi
Executable file
153
configs/bspwm/rofi/themes/network.rasi
Executable file
@ -0,0 +1,153 @@
|
|||||||
|
configuration {
|
||||||
|
font: "Iosevka 10";
|
||||||
|
show-icons: true;
|
||||||
|
display-drun: "";
|
||||||
|
drun-display-format: "{icon} {name}";
|
||||||
|
disable-history: false;
|
||||||
|
click-to-exit: true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@import "colors.rasi"
|
||||||
|
|
||||||
|
window {
|
||||||
|
transparency: "real";
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
border: 2px;
|
||||||
|
border-color: @selected;
|
||||||
|
border-radius: 10px;
|
||||||
|
width: 355px;
|
||||||
|
location: center;
|
||||||
|
anchor: center;
|
||||||
|
x-offset: 0;
|
||||||
|
y-offset: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
prompt {
|
||||||
|
enabled: true;
|
||||||
|
margin: 0px 0px 0px 10px;
|
||||||
|
padding: 6px 6px 6px 6px;
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
border: 2px;
|
||||||
|
border-color: @selected;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox-prompt-colon {
|
||||||
|
expand: false;
|
||||||
|
str: "";
|
||||||
|
border-radius: 5px;
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
padding: 6px 10px 6px 10px;
|
||||||
|
font: "Iosevka Nerd Font 10";
|
||||||
|
}
|
||||||
|
|
||||||
|
entry {
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @background;
|
||||||
|
placeholder-color: @background;
|
||||||
|
placeholder: "";
|
||||||
|
expand: true;
|
||||||
|
horizontal-align: 0;
|
||||||
|
blink: false;
|
||||||
|
padding: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
inputbar {
|
||||||
|
children: [ textbox-prompt-colon, prompt ];
|
||||||
|
spacing: 0;
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
border: 0px 0px 0px 0px;
|
||||||
|
border-radius: 5px;
|
||||||
|
border-color: @selected;
|
||||||
|
expand: false;
|
||||||
|
margin: 0px 0px 0px 0px;
|
||||||
|
padding: 0px;
|
||||||
|
position: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
case-indicator {
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
spacing: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
listview {
|
||||||
|
background-color: @background;
|
||||||
|
columns: 1;
|
||||||
|
lines: 5;
|
||||||
|
spacing: 10px;
|
||||||
|
cycle: true;
|
||||||
|
dynamic: true;
|
||||||
|
layout: horizontal;
|
||||||
|
}
|
||||||
|
|
||||||
|
mainbox {
|
||||||
|
background-color: @background;
|
||||||
|
children: [ inputbar, listview ];
|
||||||
|
spacing: 10px;
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element {
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
orientation: horizontal;
|
||||||
|
border: 2px;
|
||||||
|
border-radius: 5px;
|
||||||
|
border-color: @selected;
|
||||||
|
padding: 23.5px 25px 23.5px 25px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-icon {
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
horizontal-align: 0.5;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
size: 0px;
|
||||||
|
border: 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-text {
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
font: "feather 14";
|
||||||
|
expand: true;
|
||||||
|
horizontal-align: 0.5;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
margin: 0px 0px 0px 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element selected {
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
border: 2px;
|
||||||
|
border-radius: 5px;
|
||||||
|
border-color: @selected;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.active,
|
||||||
|
element.selected.urgent {
|
||||||
|
background-color: @on;
|
||||||
|
text-color: @background;
|
||||||
|
border-color: @on;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.selected.urgent {
|
||||||
|
border-color: @selected;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.urgent,
|
||||||
|
element.selected.active {
|
||||||
|
background-color: @off;
|
||||||
|
text-color: @background;
|
||||||
|
border-color: @off;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.selected.active {
|
||||||
|
border-color: @selected;
|
||||||
|
}
|
304
configs/bspwm/rofi/themes/networkmenu.rasi
Executable file
304
configs/bspwm/rofi/themes/networkmenu.rasi
Executable file
@ -0,0 +1,304 @@
|
|||||||
|
configuration {
|
||||||
|
font: "Iosevka 10";
|
||||||
|
show-icons: false;
|
||||||
|
}
|
||||||
|
|
||||||
|
@import "colors.rasi"
|
||||||
|
|
||||||
|
*{
|
||||||
|
border-colour: var(selected);
|
||||||
|
handle-colour: var(selected);
|
||||||
|
background-colour: var(background);
|
||||||
|
foreground-colour: var(foreground);
|
||||||
|
alternate-background: var(background-alt);
|
||||||
|
normal-background: var(background);
|
||||||
|
normal-foreground: var(foreground);
|
||||||
|
urgent-background: var(urgent);
|
||||||
|
urgent-foreground: var(background);
|
||||||
|
active-background: var(on);
|
||||||
|
active-foreground: var(background);
|
||||||
|
selected-normal-background: var(selected);
|
||||||
|
selected-normal-foreground: var(background);
|
||||||
|
selected-urgent-background: var(on);
|
||||||
|
selected-urgent-foreground: var(background);
|
||||||
|
selected-active-background: var(urgent);
|
||||||
|
selected-active-foreground: var(background);
|
||||||
|
alternate-normal-background: var(background);
|
||||||
|
alternate-normal-foreground: var(foreground);
|
||||||
|
alternate-urgent-background: var(urgent);
|
||||||
|
alternate-urgent-foreground: var(background);
|
||||||
|
alternate-active-background: var(on);
|
||||||
|
alternate-active-foreground: var(background);
|
||||||
|
}
|
||||||
|
|
||||||
|
window {
|
||||||
|
/* properties for window widget */
|
||||||
|
transparency: "real";
|
||||||
|
location: center;
|
||||||
|
anchor: center;
|
||||||
|
fullscreen: false;
|
||||||
|
width: 500px;
|
||||||
|
height: 600px;
|
||||||
|
x-offset: 0px;
|
||||||
|
y-offset: 0px;
|
||||||
|
|
||||||
|
/* properties for all widgets */
|
||||||
|
enabled: true;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 0px;
|
||||||
|
border: 0px;
|
||||||
|
border-radius: 0px;
|
||||||
|
border-color: @border-colour;
|
||||||
|
cursor: "default";
|
||||||
|
|
||||||
|
/* Backgroud Colors */
|
||||||
|
background-color: @background-colour;
|
||||||
|
}
|
||||||
|
|
||||||
|
mainbox {
|
||||||
|
enabled: true;
|
||||||
|
spacing: 10px;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 20px;
|
||||||
|
border: 2px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @border-colour;
|
||||||
|
background-color: transparent;
|
||||||
|
children: [ "inputbar", "message", "listview" ];
|
||||||
|
}
|
||||||
|
|
||||||
|
inputbar {
|
||||||
|
enabled: true;
|
||||||
|
spacing: 10px;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 4px;
|
||||||
|
border: 0px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @border-colour;
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: @foreground-colour;
|
||||||
|
children: [ "textbox-prompt-colon", "prompt", "entry" ];
|
||||||
|
}
|
||||||
|
|
||||||
|
prompt {
|
||||||
|
enabled: true;
|
||||||
|
padding: 10px 12px;
|
||||||
|
border-radius: 4px;
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox-prompt-colon {
|
||||||
|
enabled: true;
|
||||||
|
padding: 11px 15px;
|
||||||
|
border-radius: 4px;
|
||||||
|
expand: false;
|
||||||
|
str: "直";
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
}
|
||||||
|
|
||||||
|
entry {
|
||||||
|
enabled: true;
|
||||||
|
padding: 8px 12px;
|
||||||
|
border: 4px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @selected;
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
cursor: text;
|
||||||
|
placeholder: " Search... ";
|
||||||
|
placeholder-color: @background;
|
||||||
|
}
|
||||||
|
|
||||||
|
num-filtered-rows {
|
||||||
|
enabled: true;
|
||||||
|
expand: false;
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox-num-sep {
|
||||||
|
enabled: true;
|
||||||
|
expand: false;
|
||||||
|
str: "/";
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
|
num-rows {
|
||||||
|
enabled: true;
|
||||||
|
expand: false;
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
|
case-indicator {
|
||||||
|
enabled: true;
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
|
listview {
|
||||||
|
enabled: true;
|
||||||
|
columns: 1;
|
||||||
|
lines: 6;
|
||||||
|
cycle: true;
|
||||||
|
dynamic: true;
|
||||||
|
scrollbar: true;
|
||||||
|
layout: vertical;
|
||||||
|
reverse: false;
|
||||||
|
fixed-height: true;
|
||||||
|
fixed-columns: true;
|
||||||
|
|
||||||
|
spacing: 5px;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 10px;
|
||||||
|
border: 2px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @border-colour;
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: @foreground-colour;
|
||||||
|
cursor: "default";
|
||||||
|
}
|
||||||
|
|
||||||
|
scrollbar {
|
||||||
|
handle-width: 5px ;
|
||||||
|
handle-color: @handle-colour;
|
||||||
|
border-radius: 0px;
|
||||||
|
background-color: @alternate-background;
|
||||||
|
}
|
||||||
|
|
||||||
|
element {
|
||||||
|
enabled: true;
|
||||||
|
spacing: 0px;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 8px;
|
||||||
|
border: 0px;
|
||||||
|
border-radius: 0px;
|
||||||
|
border-color: @border-colour;
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: @foreground-colour;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
element normal.normal {
|
||||||
|
background-color: var(normal-background);
|
||||||
|
text-color: var(normal-foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element normal.urgent {
|
||||||
|
background-color: var(urgent-background);
|
||||||
|
text-color: var(urgent-foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element normal.active {
|
||||||
|
background-color: var(active-background);
|
||||||
|
text-color: var(active-foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element selected.normal {
|
||||||
|
background-color: var(selected-normal-background);
|
||||||
|
text-color: var(selected-normal-foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element selected.urgent {
|
||||||
|
background-color: var(selected-urgent-background);
|
||||||
|
text-color: var(selected-urgent-foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element selected.active {
|
||||||
|
background-color: var(selected-active-background);
|
||||||
|
text-color: var(selected-active-foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element alternate.normal {
|
||||||
|
background-color: var(alternate-normal-background);
|
||||||
|
text-color: var(alternate-normal-foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element alternate.urgent {
|
||||||
|
background-color: var(alternate-urgent-background);
|
||||||
|
text-color: var(alternate-urgent-foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element alternate.active {
|
||||||
|
background-color: var(alternate-active-background);
|
||||||
|
text-color: var(alternate-active-foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element-icon {
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: inherit;
|
||||||
|
size: 24px;
|
||||||
|
cursor: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-text {
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: inherit;
|
||||||
|
highlight: inherit;
|
||||||
|
cursor: inherit;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
horizontal-align: 0.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
mode-switcher{
|
||||||
|
enabled: true;
|
||||||
|
spacing: 10px;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 0px;
|
||||||
|
border: 4px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @border-colour;
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: @foreground-colour;
|
||||||
|
}
|
||||||
|
|
||||||
|
button {
|
||||||
|
padding: 5px 10px;
|
||||||
|
border: 4px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @border-colour;
|
||||||
|
background-color: @alternate-background;
|
||||||
|
text-color: inherit;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
button selected {
|
||||||
|
background-color: var(selected-normal-background);
|
||||||
|
text-color: var(selected-normal-foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
message {
|
||||||
|
enabled: true;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 8px 10px;
|
||||||
|
border: 4px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @border-colour;
|
||||||
|
background-color: @alternate-background;
|
||||||
|
text-color: @foreground-colour;
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox {
|
||||||
|
border: 4px;
|
||||||
|
border-color: @border-colour;
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: @foreground-colour;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
horizontal-align: 0.0;
|
||||||
|
highlight: none;
|
||||||
|
placeholder-color: @foreground-colour;
|
||||||
|
blink: true;
|
||||||
|
markup: true;
|
||||||
|
}
|
||||||
|
|
||||||
|
error-message {
|
||||||
|
padding: 15px;
|
||||||
|
border: 4px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @border-colour;
|
||||||
|
background-color: @background-colour;
|
||||||
|
text-color: @foreground-colour;
|
||||||
|
}
|
148
configs/bspwm/rofi/themes/powermenu.rasi
Executable file
148
configs/bspwm/rofi/themes/powermenu.rasi
Executable file
@ -0,0 +1,148 @@
|
|||||||
|
configuration {
|
||||||
|
show-icons: false;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@import "colors.rasi"
|
||||||
|
|
||||||
|
*{
|
||||||
|
font: "JetBrains Mono Nerd Font 10";
|
||||||
|
}
|
||||||
|
|
||||||
|
window {
|
||||||
|
transparency: "real";
|
||||||
|
location: center;
|
||||||
|
anchor: center;
|
||||||
|
fullscreen: false;
|
||||||
|
width: 600px;
|
||||||
|
height: 200px;
|
||||||
|
x-offset: 0px;
|
||||||
|
y-offset: 0px;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 0px;
|
||||||
|
border: 0px solid;
|
||||||
|
border-radius: 0px;
|
||||||
|
cursor: "default";
|
||||||
|
background-color: @background;
|
||||||
|
}
|
||||||
|
|
||||||
|
mainbox {
|
||||||
|
enabled: true;
|
||||||
|
spacing: 15px;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 30px;
|
||||||
|
background-color: transparent;
|
||||||
|
orientation: horizontal;
|
||||||
|
children: [ "imagebox", "listview" ];
|
||||||
|
}
|
||||||
|
|
||||||
|
imagebox {
|
||||||
|
border: 7px solid;
|
||||||
|
border-radius: 100%;
|
||||||
|
border-color: @selected;
|
||||||
|
background-color: transparent;
|
||||||
|
expand: false;
|
||||||
|
width: 7.77em;
|
||||||
|
background-image: url("/mnt/raid/projects/cpp/trycaster/trycaster.web/public/favicon/safari-pinned-tab.svg", height);
|
||||||
|
}
|
||||||
|
|
||||||
|
dummy{
|
||||||
|
background-color: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox-prompt-colon {
|
||||||
|
enabled: true;
|
||||||
|
expand: false;
|
||||||
|
str: "";
|
||||||
|
padding: 10px 13px;
|
||||||
|
border: 5px solid;
|
||||||
|
border-radius: 100%;
|
||||||
|
border-color: @selected;
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: @foreground;
|
||||||
|
}
|
||||||
|
|
||||||
|
prompt {
|
||||||
|
enabled: true;
|
||||||
|
padding: 10px;
|
||||||
|
border: 5px solid;
|
||||||
|
border-radius: 100%;
|
||||||
|
border-color: @foreground;
|
||||||
|
background-color: @foreground;
|
||||||
|
text-color: @background;
|
||||||
|
}
|
||||||
|
|
||||||
|
message {
|
||||||
|
enabled: true;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 10px;
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox {
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
horizontal-align: 0.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
listview {
|
||||||
|
enabled: true;
|
||||||
|
columns: 16;
|
||||||
|
lines: 1;
|
||||||
|
cycle: true;
|
||||||
|
scrollbar: false;
|
||||||
|
layout: vertical;
|
||||||
|
|
||||||
|
spacing: 5px;
|
||||||
|
background-color: transparent;
|
||||||
|
cursor: "default";
|
||||||
|
}
|
||||||
|
|
||||||
|
element {
|
||||||
|
enabled: true;
|
||||||
|
padding: 11px;
|
||||||
|
border: 0px solid;
|
||||||
|
border-radius: 100%;
|
||||||
|
border-color: @selected;
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: @foreground;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-text {
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: inherit;
|
||||||
|
cursor: inherit;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
horizontal-align: 0.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
element normal.normal,
|
||||||
|
element alternate.normal {
|
||||||
|
background-color: var(background);
|
||||||
|
text-color: var(foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element normal.urgent,
|
||||||
|
element alternate.urgent,
|
||||||
|
element selected.active {
|
||||||
|
background-color: var(urgent);
|
||||||
|
text-color: var(background);
|
||||||
|
}
|
||||||
|
|
||||||
|
element normal.active,
|
||||||
|
element alternate.active,
|
||||||
|
element selected.urgent {
|
||||||
|
background-color: var(on);
|
||||||
|
text-color: var(background);
|
||||||
|
}
|
||||||
|
|
||||||
|
element selected.normal {
|
||||||
|
border: 5px solid;
|
||||||
|
border-radius: 100%;
|
||||||
|
border-color: @selected;
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: var(foreground);
|
||||||
|
}
|
142
configs/bspwm/rofi/themes/screenshot.rasi
Executable file
142
configs/bspwm/rofi/themes/screenshot.rasi
Executable file
@ -0,0 +1,142 @@
|
|||||||
|
|
||||||
|
configuration {
|
||||||
|
show-icons: false;
|
||||||
|
font: "Iosevka 10";
|
||||||
|
}
|
||||||
|
|
||||||
|
@import "colors.rasi"
|
||||||
|
|
||||||
|
window {
|
||||||
|
transparency: "real";
|
||||||
|
location: center;
|
||||||
|
anchor: center;
|
||||||
|
fullscreen: false;
|
||||||
|
width: 600px;
|
||||||
|
x-offset: 0px;
|
||||||
|
y-offset: 0px;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 0px;
|
||||||
|
border: 4px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @selected;
|
||||||
|
cursor: "default";
|
||||||
|
background-color: @background;
|
||||||
|
}
|
||||||
|
|
||||||
|
mainbox {
|
||||||
|
enabled: true;
|
||||||
|
spacing: 10px;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 20px;
|
||||||
|
background-color: transparent;
|
||||||
|
children: [ "inputbar", "message", "listview" ];
|
||||||
|
}
|
||||||
|
|
||||||
|
inputbar {
|
||||||
|
enabled: true;
|
||||||
|
spacing: 10px;
|
||||||
|
padding: 0px;
|
||||||
|
border: 0px;
|
||||||
|
border-radius: 0px;
|
||||||
|
border-color: @selected;
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: @foreground;
|
||||||
|
children: [ "textbox-prompt-colon", "prompt"];
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox-prompt-colon {
|
||||||
|
enabled: true;
|
||||||
|
expand: false;
|
||||||
|
str: "";
|
||||||
|
padding: 10px 12px;
|
||||||
|
border-radius: 4px;
|
||||||
|
background-color: @on;
|
||||||
|
text-color: @background;
|
||||||
|
}
|
||||||
|
|
||||||
|
prompt {
|
||||||
|
enabled: true;
|
||||||
|
padding: 10px;
|
||||||
|
border-radius: 4px;
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
}
|
||||||
|
|
||||||
|
message {
|
||||||
|
enabled: true;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 10px;
|
||||||
|
border: 4px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @selected;
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox {
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
horizontal-align: 0.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
listview {
|
||||||
|
enabled: true;
|
||||||
|
columns: 5;
|
||||||
|
lines: 3;
|
||||||
|
cycle: true;
|
||||||
|
scrollbar: false;
|
||||||
|
layout: vertical;
|
||||||
|
|
||||||
|
spacing: 10px;
|
||||||
|
background-color: transparent;
|
||||||
|
cursor: "default";
|
||||||
|
}
|
||||||
|
|
||||||
|
element {
|
||||||
|
enabled: true;
|
||||||
|
padding: 22px 10px;
|
||||||
|
border: 4px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @selected;
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: @foreground;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-text {
|
||||||
|
font: "feather 12";
|
||||||
|
background-color: transparent;
|
||||||
|
text-color: inherit;
|
||||||
|
cursor: inherit;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
horizontal-align: 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
element normal.normal,
|
||||||
|
element alternate.normal {
|
||||||
|
border: 4px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border-color: @selected;
|
||||||
|
background-color: var(background);
|
||||||
|
text-color: var(foreground);
|
||||||
|
}
|
||||||
|
|
||||||
|
element normal.urgent,
|
||||||
|
element alternate.urgent,
|
||||||
|
element selected.active {
|
||||||
|
background-color: var(urgent);
|
||||||
|
text-color: var(background);
|
||||||
|
}
|
||||||
|
|
||||||
|
element normal.active,
|
||||||
|
element alternate.active,
|
||||||
|
element selected.urgent {
|
||||||
|
background-color: var(on);
|
||||||
|
text-color: var(background);
|
||||||
|
}
|
||||||
|
|
||||||
|
element selected.normal {
|
||||||
|
background-color: var(selected);
|
||||||
|
text-color: var(background);
|
||||||
|
}
|
151
configs/bspwm/rofi/themes/window.rasi
Executable file
151
configs/bspwm/rofi/themes/window.rasi
Executable file
@ -0,0 +1,151 @@
|
|||||||
|
configuration {
|
||||||
|
font: "Iosevka 10";
|
||||||
|
show-icons: false;
|
||||||
|
display-window: "Windows :";
|
||||||
|
window-format: "{w} · {c} · {t}";
|
||||||
|
disable-history: false;
|
||||||
|
click-to-exit: true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@import "colors.rasi"
|
||||||
|
|
||||||
|
window {
|
||||||
|
transparency: "real";
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
border: 2px;
|
||||||
|
border-color: @selected;
|
||||||
|
border-radius: 10px;
|
||||||
|
width: 500px;
|
||||||
|
location: center;
|
||||||
|
anchor: center;
|
||||||
|
x-offset: 0;
|
||||||
|
y-offset: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
prompt {
|
||||||
|
enabled: true;
|
||||||
|
margin: 0px 0px 0px 8px;
|
||||||
|
padding: 6px 6px 6px 6px;
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
border: 2px;
|
||||||
|
border-color: @selected;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox-prompt-colon {
|
||||||
|
expand: false;
|
||||||
|
str: "";
|
||||||
|
border-radius: 5px;
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
padding: 6px 10px 6px 10px;
|
||||||
|
font: "Iosevka Nerd Font 10";
|
||||||
|
}
|
||||||
|
|
||||||
|
entry {
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
margin: 0px 0px 0px 8px;
|
||||||
|
border: 2px;
|
||||||
|
border-radius: 5px;
|
||||||
|
border-color: @selected;
|
||||||
|
placeholder-color: @background;
|
||||||
|
placeholder: " Find... ";
|
||||||
|
expand: true;
|
||||||
|
horizontal-align: 0;
|
||||||
|
blink: true;
|
||||||
|
padding: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
inputbar {
|
||||||
|
children: [ textbox-prompt-colon, prompt, entry ];
|
||||||
|
spacing: 0;
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
expand: false;
|
||||||
|
margin: 0px 0px 0px 0px;
|
||||||
|
padding: 0px;
|
||||||
|
position: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
case-indicator {
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
spacing: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
listview {
|
||||||
|
background-color: @background;
|
||||||
|
columns: 1;
|
||||||
|
lines: 7;
|
||||||
|
spacing: 5px;
|
||||||
|
cycle: true;
|
||||||
|
dynamic: true;
|
||||||
|
layout: vertical;
|
||||||
|
}
|
||||||
|
|
||||||
|
mainbox {
|
||||||
|
background-color: @background;
|
||||||
|
children: [ inputbar, listview ];
|
||||||
|
spacing: 10px;
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element {
|
||||||
|
background-color: @background;
|
||||||
|
text-color: @foreground;
|
||||||
|
orientation: horizontal;
|
||||||
|
border-radius: 5px;
|
||||||
|
padding: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-icon {
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
horizontal-align: 0.5;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
size: 0px;
|
||||||
|
border: 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-text {
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
expand: true;
|
||||||
|
horizontal-align: 0;
|
||||||
|
vertical-align: 0;
|
||||||
|
margin: 2px 0px 2px 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element selected {
|
||||||
|
background-color: @selected;
|
||||||
|
text-color: @background;
|
||||||
|
border: 0px;
|
||||||
|
border-radius: 5px;
|
||||||
|
border-color: @selected;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.active,
|
||||||
|
element.selected.urgent {
|
||||||
|
background-color: @on;
|
||||||
|
text-color: @background;
|
||||||
|
border-color: @on;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.selected.urgent {
|
||||||
|
border-color: @selected;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.urgent,
|
||||||
|
element.selected.active {
|
||||||
|
background-color: @off;
|
||||||
|
text-color: @background;
|
||||||
|
border-color: @off;
|
||||||
|
}
|
||||||
|
|
||||||
|
element.selected.active {
|
||||||
|
border-color: @selected;
|
||||||
|
}
|
93
configs/bspwm/themes/Chad WM/colorScheme
Executable file
93
configs/bspwm/themes/Chad WM/colorScheme
Executable file
@ -0,0 +1,93 @@
|
|||||||
|
|
||||||
|
*background: #1E222A
|
||||||
|
*foreground: #ABB2BF
|
||||||
|
|
||||||
|
*color0: #4d5361
|
||||||
|
*color8: #4d5361
|
||||||
|
|
||||||
|
*color1: #E06C75
|
||||||
|
*color9: #E06C75
|
||||||
|
|
||||||
|
*color2: #98C379
|
||||||
|
*color10: #98C379
|
||||||
|
|
||||||
|
*color3: #E5C07B
|
||||||
|
*color11: #E5C07B
|
||||||
|
|
||||||
|
*color4: #61AFEF
|
||||||
|
*color12: #61AFEF
|
||||||
|
|
||||||
|
*color5: #C678DD
|
||||||
|
*color13: #C678DD
|
||||||
|
|
||||||
|
*color6: #56B6C2
|
||||||
|
*color14: #56B6C2
|
||||||
|
|
||||||
|
*color7: #ABB2BF
|
||||||
|
*color15: #ABB2BF
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
|
||||||
|
*background: #101419
|
||||||
|
*foreground: #b6beca
|
||||||
|
|
||||||
|
*color0: #384148
|
||||||
|
*color8: #1c252c
|
||||||
|
|
||||||
|
*color1: #fc7b81
|
||||||
|
*color9: #e05f65
|
||||||
|
|
||||||
|
*color2: #94f7c5
|
||||||
|
*color10: #78dba9
|
||||||
|
|
||||||
|
*color3: #ffeba6
|
||||||
|
*color11: #f1cf8a
|
||||||
|
|
||||||
|
*color4: #8cc1ff
|
||||||
|
*color12: #70a5eb
|
||||||
|
|
||||||
|
*color5: #e2a6ff
|
||||||
|
*color13: #c68aee
|
||||||
|
|
||||||
|
*color6: #90daff
|
||||||
|
*color14: #74bee9
|
||||||
|
|
||||||
|
*color7: #fafdff
|
||||||
|
*color15: #dee1e6
|
||||||
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
/* EFO */
|
||||||
|
|
||||||
|
/*
|
||||||
|
|
||||||
|
*background: #1E222A
|
||||||
|
*foreground: #ABB2BF
|
||||||
|
|
||||||
|
*color0: #282C34
|
||||||
|
*color8: #16181c
|
||||||
|
|
||||||
|
*color1: #E06C75
|
||||||
|
*color9: #853a40
|
||||||
|
|
||||||
|
*color2: #98C379
|
||||||
|
*color10: #3f592d
|
||||||
|
|
||||||
|
*color3: #E5C07B
|
||||||
|
*color11: #78643e
|
||||||
|
|
||||||
|
*color4: #61AFEF
|
||||||
|
*color12: #3b6c94
|
||||||
|
|
||||||
|
*color5: #C678DD
|
||||||
|
*color13: #5f376b
|
||||||
|
|
||||||
|
*color6: #56B6C2
|
||||||
|
*color14: #2d646b
|
||||||
|
|
||||||
|
*color7: #ABB2BF
|
||||||
|
*color15: #70757d
|
||||||
|
|
||||||
|
*/
|
BIN
configs/bspwm/themes/Chad WM/preview.png
Normal file
BIN
configs/bspwm/themes/Chad WM/preview.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 138 KiB |
17
configs/bspwm/themes/Chad WM/theme.conf
Executable file
17
configs/bspwm/themes/Chad WM/theme.conf
Executable file
@ -0,0 +1,17 @@
|
|||||||
|
background = /usr/share/backgrounds/chad.png
|
||||||
|
theme = Qogir-dark
|
||||||
|
icons = Qogir-dark
|
||||||
|
cursor = ManjaTrix
|
||||||
|
RGB-keyboard = ChadWM
|
||||||
|
picom = default.conf
|
||||||
|
keybinding = sxhkdrc
|
||||||
|
|
||||||
|
bsp-border-width = 2
|
||||||
|
bsp-window-gap = 10
|
||||||
|
bsp-split-ratio = 0.50
|
||||||
|
bsp-borderless-monocle = true
|
||||||
|
bsp-gapless-monocle = true
|
||||||
|
bsp-paddingless-monocle = true
|
||||||
|
bsp-single-monocle = false
|
||||||
|
bsp-focus-follows-pointer = true
|
||||||
|
bsp-presel-feedback = true
|
10
configs/bspwm/xsettingsd
Executable file
10
configs/bspwm/xsettingsd
Executable file
@ -0,0 +1,10 @@
|
|||||||
|
Net/ThemeName "Qogir-dark"
|
||||||
|
Net/IconThemeName "Qogir-dark"
|
||||||
|
Gtk/CursorThemeName "ManjaTrix"
|
||||||
|
Net/EnableEventSounds 0
|
||||||
|
Net/EnableInputFeedbackSounds 0
|
||||||
|
Xft/DPI -1
|
||||||
|
Xft/Hinting 1
|
||||||
|
Xft/HintStyle "hintslight"
|
||||||
|
Xft/Antialias 1
|
||||||
|
Xft/RGBA "none"
|
@ -1,30 +1,31 @@
|
|||||||
[files]
|
[files]
|
||||||
current_page=-1
|
recent_files=/home/chatlanin/vamp/result.json;/home/chatlanin/vamp/build_libs/libs/nnls-chroma-1.1/.hgtags;/mnt/raid/projects/tarch_os/TMP/exodia/exodia-packages/exodia-pixmaps/pixmaps/pixmaps/exodia.txt;/mnt/raid/projects/tarch_os/TMP/exodia/exodia-packages/exodia-grub-theme/files/exodia/theme.txt;/mnt/raid/projects/cpp/hs/README.md;/home/ozil/GitHub/Exodia-Repos/exodia-DWM/exodia-st/st-boxdraw.patch;/home/ozil/GitHub/Exodia-Repos/exodia-DWM/exodia-st/st-mouse-scroll_1.patch;/home/ozil/GitHub/Exodia-Repos/exodia-DWM/exodia-st/st-mouse-scroll_2.patch;/home/ozil/GitHub/Exodia-Repos/exodia-DWM/exodia-st/st-mouse-scroll_3.patch;/home/ozil/GitHub/Exodia-Repos/exodia-packages/exodia-templates/Templates/programming/perl.pl;
|
||||||
recent_files=/mnt/raid/__tmp__/home_3/bin/projects/home;/mnt/raid/projects/tarch_os/repos/tarck-configs/configs/mimeapps.list;/home/chatlanin/.trash/ex-bspwm.2024-02-20.07:36:56/src/PKGBUILD;/run/media/chatlanin/4044-5149/file.txt;/home/chatlanin/.config/rofi/config.rasi;/home/chatlanin/.ssh/known_hosts;/run/media/chatlanin/e67e4e19-43d4-4812-bc37-1b9775193e50/home/bin/scripts/system/srv;
|
|
||||||
recent_projects=
|
recent_projects=
|
||||||
|
current_page=0
|
||||||
[VTE]
|
FILE_NAME_0=0;JSON;0;EUTF-8;1;1;0;%2Fhome%2Fchatlanin%2Fvamp%2Fresult.json;0;4
|
||||||
last_dir=/mnt/raid/__tmp__/home_3/bin/projects
|
|
||||||
|
|
||||||
[project]
|
[project]
|
||||||
session_file=
|
session_file=
|
||||||
project_file_path=/home/chatlanin/projects
|
project_file_path=
|
||||||
|
|
||||||
[geany]
|
[geany]
|
||||||
treeview_position=267
|
treeview_position=156
|
||||||
msgwindow_position=368
|
msgwindow_position=522
|
||||||
geometry=1925;1110;1901;1036;0;
|
geometry=2882;60;944;1036;1;
|
||||||
sidebar_page=0
|
sidebar_page=0
|
||||||
|
|
||||||
|
[VTE]
|
||||||
|
last_dir=/home/chatlanin
|
||||||
|
|
||||||
[search]
|
[search]
|
||||||
find_all_expanded=false
|
find_all_expanded=false
|
||||||
replace_all_expanded=false
|
replace_all_expanded=true
|
||||||
position_find_x=-1
|
position_find_x=695
|
||||||
position_find_y=-1
|
position_find_y=430
|
||||||
position_replace_x=-1
|
position_replace_x=855
|
||||||
position_replace_y=-1
|
position_replace_y=533
|
||||||
position_fif_x=-1
|
position_fif_x=673
|
||||||
position_fif_y=-1
|
position_fif_y=203
|
||||||
|
|
||||||
[plugins]
|
[plugins]
|
||||||
load_plugins=true
|
load_plugins=true
|
||||||
|
@ -22,7 +22,7 @@ cursor_beam_thickness 1.8
|
|||||||
window_margin_width 3.0
|
window_margin_width 3.0
|
||||||
|
|
||||||
detect_urls yes
|
detect_urls yes
|
||||||
enabled_layouts tall:bias=50;full_size=1;mirrored=false
|
enabled_layouts tall:bias=50;full_size=1;mirrored=true
|
||||||
|
|
||||||
# maps
|
# maps
|
||||||
map super+s next_window
|
map super+s next_window
|
||||||
|
@ -1,10 +1,16 @@
|
|||||||
lastupdatecheck: 0
|
lastupdatecheck: 0
|
||||||
recentrepos:
|
recentrepos:
|
||||||
- /mnt/raid/projects/tarch_os/repos/tarch-configs
|
- /mnt/raid/projects/tarch_os/repos/tarch-configs
|
||||||
- /mnt/raid/projects/tarch_os/repos/tarch-bin
|
- /mnt/raid/projects/tarch_os/repos/tarch-misc
|
||||||
- /mnt/raid/projects/tarch_os/repos/tarch-fonts
|
- /mnt/raid/projects/tarch_os/repos/tarch-fonts
|
||||||
- /mnt/raid/projects/tarch_os/repos/tarch-nvim
|
- /mnt/raid/projects/tarch_os/repos/tarch-bin
|
||||||
- /mnt/raid/projects/tarch_os/repos/tarch-bspwm
|
- /mnt/raid/projects/tarch_os/repos/tarch-hooks
|
||||||
|
- /mnt/raid/projects/tarch_os/repos/tarch-install-scripts
|
||||||
|
- /mnt/raid/projects/tarch_os/repos/tarch-calamares
|
||||||
|
- /mnt/raid/projects/tarch_os/repos/tarch-plymouth-theme
|
||||||
|
- /mnt/raid/projects/tarch_os/repos/tarch-grub-theme
|
||||||
|
- /mnt/raid/projects/tarch_os/repos/tarch-sddm-theme-corners
|
||||||
|
- /mnt/raid/projects/tarch_os/repos/tarch-scripts
|
||||||
startuppopupversion: 5
|
startuppopupversion: 5
|
||||||
customcommandshistory: []
|
customcommandshistory: []
|
||||||
hidecommandlog: false
|
hidecommandlog: false
|
||||||
|
8
configs/nvim/init.lua
Normal file
8
configs/nvim/init.lua
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
-- Если нужно что-то вспомнить
|
||||||
|
-- https://www.youtube.com/watch?v=NL8D8EkphUw
|
||||||
|
-- https://github.com/josean-dev/dev-environment-files/tree/main/.config/nvim/lua/josean
|
||||||
|
|
||||||
|
-- Basic config
|
||||||
|
require("core.mappings").load()
|
||||||
|
require("core.options").load()
|
||||||
|
require("plugins").load()
|
48
configs/nvim/lazy-lock.json
Normal file
48
configs/nvim/lazy-lock.json
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
{
|
||||||
|
"Comment.nvim": { "branch": "master", "commit": "0236521ea582747b58869cb72f70ccfa967d2e89" },
|
||||||
|
"LuaSnip": { "branch": "master", "commit": "a7a4b4682c4b3e2ba82b82a4e6e5f5a0e79dec32" },
|
||||||
|
"alpha-nvim": { "branch": "main", "commit": "41283fb402713fc8b327e60907f74e46166f4cfd" },
|
||||||
|
"bufferline.nvim": { "branch": "main", "commit": "64e2c5def50dfd6b6f14d96a45fa3d815a4a1eef" },
|
||||||
|
"catppuccin": { "branch": "main", "commit": "045e3499d9ec8d84635fb08877ae44fd33f6a38d" },
|
||||||
|
"cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" },
|
||||||
|
"cmp-cmdline": { "branch": "main", "commit": "8ee981b4a91f536f52add291594e89fb6645e451" },
|
||||||
|
"cmp-nvim-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" },
|
||||||
|
"cmp-nvim-lsp-signature-help": { "branch": "main", "commit": "3d8912ebeb56e5ae08ef0906e3a54de1c66b92f1" },
|
||||||
|
"cmp-nvim-lua": { "branch": "main", "commit": "f12408bdb54c39c23e67cab726264c10db33ada8" },
|
||||||
|
"cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
|
||||||
|
"cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" },
|
||||||
|
"dressing.nvim": { "branch": "master", "commit": "6f212262061a2120e42da0d1e87326e8a41c0478" },
|
||||||
|
"friendly-snippets": { "branch": "main", "commit": "dcd4a586439a1c81357d5b9d26319ae218cc9479" },
|
||||||
|
"hop.nvim": { "branch": "master", "commit": "6d853addd6e11df8338b26e869a29b36f2c3e893" },
|
||||||
|
"indent-blankline.nvim": { "branch": "master", "commit": "821a7acd88587d966f7e464b0b3031dfe7f5680c" },
|
||||||
|
"lazy.nvim": { "branch": "main", "commit": "83493db50a434a4c5c648faf41e2ead80f96e478" },
|
||||||
|
"lspkind.nvim": { "branch": "master", "commit": "1735dd5a5054c1fb7feaf8e8658dbab925f4f0cf" },
|
||||||
|
"lualine.nvim": { "branch": "master", "commit": "8b56462bfb746760465264de41b4907310f113ec" },
|
||||||
|
"mason-lspconfig.nvim": { "branch": "main", "commit": "21d33d69a81f6351e5a5f49078b2e4f0075c8e73" },
|
||||||
|
"mason-null-ls.nvim": { "branch": "main", "commit": "e270134d83ba59425edc53356c6fd337b61bb8dd" },
|
||||||
|
"mason-tool-installer.nvim": { "branch": "main", "commit": "1212fb6082b7177dde17ea65e429e027835aeb40" },
|
||||||
|
"mason.nvim": { "branch": "main", "commit": "3b5068f0fc565f337d67a2d315d935f574848ee7" },
|
||||||
|
"neoscroll.nvim": { "branch": "master", "commit": "6e3546751076890304428150e53bd59198a4505d" },
|
||||||
|
"none-ls.nvim": { "branch": "main", "commit": "ff3819c52ca04232fb70fbd6c1639de9abcbe122" },
|
||||||
|
"nvim-autopairs": { "branch": "master", "commit": "c6139ca0d5ad7af129ea6c89cb4c56093f2c034a" },
|
||||||
|
"nvim-cmp": { "branch": "main", "commit": "04e0ca376d6abdbfc8b52180f8ea236cbfddf782" },
|
||||||
|
"nvim-highlight-colors": { "branch": "main", "commit": "a9f191d5ba27a5943b8992bf618858fa7374758f" },
|
||||||
|
"nvim-lsp-file-operations": { "branch": "master", "commit": "223aca86b737dc66e9c51ebcda8788a8d9cc6cf2" },
|
||||||
|
"nvim-lspconfig": { "branch": "master", "commit": "16295b79410f131c4fa7870c663b4ace6a761fb2" },
|
||||||
|
"nvim-notify": { "branch": "master", "commit": "5371f4bfc1f6d3adf4fe9d62cd3a9d44356bfd15" },
|
||||||
|
"nvim-pasta": { "branch": "main", "commit": "b9fdc3f24c6cc47beb3e02069a3fae7fdaab4f77" },
|
||||||
|
"nvim-tree.lua": { "branch": "master", "commit": "041dbd18f440207ad161503a384e7c82d575db66" },
|
||||||
|
"nvim-treesitter": { "branch": "master", "commit": "7ff51f53b0efb6228df2e8539b51bb2e737b77f3" },
|
||||||
|
"nvim-ts-autotag": { "branch": "main", "commit": "531f48334c422222aebc888fd36e7d109cb354cd" },
|
||||||
|
"nvim-web-devicons": { "branch": "master", "commit": "75df79feb02d5e0ec114e447453775d4d291ea03" },
|
||||||
|
"plenary.nvim": { "branch": "master", "commit": "f7adfc4b3f4f91aab6caebf42b3682945fbc35be" },
|
||||||
|
"popup.nvim": { "branch": "master", "commit": "b7404d35d5d3548a82149238289fa71f7f6de4ac" },
|
||||||
|
"telescope-file-browser.nvim": { "branch": "master", "commit": "8839e3f8070dfafa5b0c0e4652700298e7b872c4" },
|
||||||
|
"telescope-media-files.nvim": { "branch": "master", "commit": "0826c7a730bc4d36068f7c85cf4c5b3fd9fb570a" },
|
||||||
|
"telescope.nvim": { "branch": "master", "commit": "d90956833d7c27e73c621a61f20b29fdb7122709" },
|
||||||
|
"vim-auto-save": { "branch": "master", "commit": "2e3e54ea4c0fc946c21b0a4ee4c1c295ba736ee8" },
|
||||||
|
"vim-bbye": { "branch": "master", "commit": "25ef93ac5a87526111f43e5110675032dbcacf56" },
|
||||||
|
"vim-tmux-navigator": { "branch": "master", "commit": "38b1d0402c4600543281dc85b3f51884205674b6" },
|
||||||
|
"vimwiki": { "branch": "dev", "commit": "fde35bb87e45abe930eebef5ab99a16289e53789" },
|
||||||
|
"which-key.nvim": { "branch": "main", "commit": "4433e5ec9a507e5097571ed55c02ea9658fb268a" }
|
||||||
|
}
|
154
configs/nvim/lua/core/icons.lua
Normal file
154
configs/nvim/lua/core/icons.lua
Normal file
@ -0,0 +1,154 @@
|
|||||||
|
return {
|
||||||
|
kind = {
|
||||||
|
Array = "",
|
||||||
|
Boolean = "蘒",
|
||||||
|
Class = "",
|
||||||
|
Color = "",
|
||||||
|
Constant = "",
|
||||||
|
Constructor = "",
|
||||||
|
Enum = "",
|
||||||
|
EnumMember = "",
|
||||||
|
Event = "",
|
||||||
|
Field = "",
|
||||||
|
File = "",
|
||||||
|
Folder = "",
|
||||||
|
Function = "",
|
||||||
|
Interface = "",
|
||||||
|
Key = "",
|
||||||
|
Keyword = "",
|
||||||
|
Method = "",
|
||||||
|
Module = "",
|
||||||
|
Namespace = "",
|
||||||
|
Null = "ﳠ",
|
||||||
|
Number = "",
|
||||||
|
Object = "",
|
||||||
|
Operator = "",
|
||||||
|
Package = "",
|
||||||
|
Property = "",
|
||||||
|
Reference = "",
|
||||||
|
Snippet = "",
|
||||||
|
String = "",
|
||||||
|
Struct = "",
|
||||||
|
Text = "",
|
||||||
|
TypeParameter = "",
|
||||||
|
Unit = "",
|
||||||
|
Value = "",
|
||||||
|
Variable = ""
|
||||||
|
},
|
||||||
|
git = {
|
||||||
|
LineAdded = "",
|
||||||
|
LineModified = "",
|
||||||
|
LineRemoved = "",
|
||||||
|
FileDeleted = "",
|
||||||
|
FileIgnored = "◌",
|
||||||
|
FileRenamed = "➜",
|
||||||
|
FileStaged = "S",
|
||||||
|
FileUnmerged = "",
|
||||||
|
FileUnstaged = "",
|
||||||
|
FileUntracked = "U",
|
||||||
|
Diff = "",
|
||||||
|
Repo = "",
|
||||||
|
Octoface = "",
|
||||||
|
Branch = ""
|
||||||
|
},
|
||||||
|
ui = {
|
||||||
|
ArrowCircleDown = "",
|
||||||
|
ArrowCircleLeft = "",
|
||||||
|
ArrowCircleRight = "",
|
||||||
|
ArrowCircleUp = "",
|
||||||
|
BoldArrowDown = "",
|
||||||
|
BoldArrowLeft = "",
|
||||||
|
BoldArrowRight = "",
|
||||||
|
BoldArrowUp = "",
|
||||||
|
BoldClose = "",
|
||||||
|
BoldDividerLeft = "",
|
||||||
|
BoldDividerRight = "",
|
||||||
|
BoldLineLeft = "▎",
|
||||||
|
BookMark = "",
|
||||||
|
BoxChecked = "",
|
||||||
|
Bug = "",
|
||||||
|
Stacks = " ",
|
||||||
|
Scopes = "",
|
||||||
|
Watches = "",
|
||||||
|
DebugConsole = " ",
|
||||||
|
Calendar = "",
|
||||||
|
Check = "",
|
||||||
|
ChevronRight = ">",
|
||||||
|
ChevronShortDown = "",
|
||||||
|
ChevronShortLeft = "",
|
||||||
|
ChevronShortRight = "",
|
||||||
|
ChevronShortUp = "",
|
||||||
|
Circle = "",
|
||||||
|
Close = "",
|
||||||
|
CloudDownload = "",
|
||||||
|
Code = "",
|
||||||
|
Comment = "",
|
||||||
|
Dashboard = "",
|
||||||
|
DividerLeft = "",
|
||||||
|
DividerRight = "",
|
||||||
|
DoubleChevronRight = "»",
|
||||||
|
Ellipsis = "…",
|
||||||
|
EmptyFolder = "",
|
||||||
|
EmptyFolderOpen = "",
|
||||||
|
File = "",
|
||||||
|
FileSymlink = "",
|
||||||
|
Files = "",
|
||||||
|
FindFile = "",
|
||||||
|
FindText = "",
|
||||||
|
Fire = "",
|
||||||
|
Folder = "",
|
||||||
|
FolderOpen = "",
|
||||||
|
FolderSymlink = "",
|
||||||
|
Forward = "",
|
||||||
|
Gear = "",
|
||||||
|
History = "",
|
||||||
|
Lightbulb = "",
|
||||||
|
LineLeft = "▏",
|
||||||
|
LineMiddle = "│",
|
||||||
|
List = "",
|
||||||
|
Lock = "",
|
||||||
|
NewFile = "",
|
||||||
|
Note = "",
|
||||||
|
Package = "",
|
||||||
|
Pencil = "",
|
||||||
|
Plus = "",
|
||||||
|
Project = "",
|
||||||
|
Search = "",
|
||||||
|
SignIn = "",
|
||||||
|
SignOut = "",
|
||||||
|
Tab = "",
|
||||||
|
Table = "",
|
||||||
|
Target = "",
|
||||||
|
Telescope = "",
|
||||||
|
Text = "",
|
||||||
|
Tree = "",
|
||||||
|
Triangle = "契",
|
||||||
|
TriangleShortArrowDown = "",
|
||||||
|
TriangleShortArrowLeft = "",
|
||||||
|
TriangleShortArrowRight = "",
|
||||||
|
TriangleShortArrowUp = ""
|
||||||
|
},
|
||||||
|
diagnostics = {
|
||||||
|
BoldError = "",
|
||||||
|
Error = "",
|
||||||
|
BoldWarning = "",
|
||||||
|
Warning = "",
|
||||||
|
BoldInformation = "",
|
||||||
|
Information = "",
|
||||||
|
BoldQuestion = "",
|
||||||
|
Question = "",
|
||||||
|
BoldHint = "",
|
||||||
|
Hint = "",
|
||||||
|
Debug = "",
|
||||||
|
Trace = "✎"
|
||||||
|
},
|
||||||
|
misc = {
|
||||||
|
Robot = "ﮧ",
|
||||||
|
Squirrel = "",
|
||||||
|
Tag = "",
|
||||||
|
Watch = "",
|
||||||
|
Smiley = "ﲃ",
|
||||||
|
Package = "",
|
||||||
|
CircuitBoard = ""
|
||||||
|
}
|
||||||
|
}
|
93
configs/nvim/lua/core/mappings.lua
Normal file
93
configs/nvim/lua/core/mappings.lua
Normal file
@ -0,0 +1,93 @@
|
|||||||
|
local M = {}
|
||||||
|
local kmap = vim.keymap.set
|
||||||
|
|
||||||
|
M.load = function()
|
||||||
|
-- mapleader
|
||||||
|
vim.g.mapleader = " "
|
||||||
|
vim.g.maplocalleader = " "
|
||||||
|
kmap("", "<Space>", "<Nop>")
|
||||||
|
|
||||||
|
-- переход к ошибкам
|
||||||
|
kmap("n", "<leader>e", ":lua vim.diagnostic.goto_prev({ border = \"rounded\" })<CR>")
|
||||||
|
|
||||||
|
-- сдвиг выделенного блока
|
||||||
|
kmap("v", "<", "<gv")
|
||||||
|
kmap("v", ">", ">gv")
|
||||||
|
|
||||||
|
-- перемещение выделенной строки
|
||||||
|
kmap("v", "<A-j>", ":m .+1<CR>==")
|
||||||
|
kmap("v", "<A-k>", ":m .-2<CR>==")
|
||||||
|
|
||||||
|
-- переназначаем <ESC>
|
||||||
|
kmap("i", "jk", "<ESC>")
|
||||||
|
kmap("i", "kj", "<ESC>")
|
||||||
|
kmap("i", "jj", "<ESC>")
|
||||||
|
kmap("i", "kk", "<ESC>")
|
||||||
|
kmap("c", "jk", "<ESC>")
|
||||||
|
kmap("c", "kj", "<ESC>")
|
||||||
|
kmap("c", "jj", "<ESC>")
|
||||||
|
kmap("c", "kk", "<ESC>")
|
||||||
|
|
||||||
|
-- снять выделение результата поиска
|
||||||
|
kmap("n", "<leader><ESC>", ":nohlsearch<CR><C-L>")
|
||||||
|
|
||||||
|
-- заключить слово в ""
|
||||||
|
kmap("n", "<leader>\"", "viw<esc>a\"<esc>bi\"<esc>lel")
|
||||||
|
|
||||||
|
-- перемещение по ключам
|
||||||
|
kmap("n", "S", ":HopWord<CR>", { silent = true })
|
||||||
|
|
||||||
|
-- поиск
|
||||||
|
-- kmap("n", "<leader>F", ":Telescope find_files<CR>")
|
||||||
|
-- kmap("n", "<leader>T", ":Telescope live_grep<CR>")
|
||||||
|
kmap("n", "<leader>F", ":Telescope file_browser<CR>")
|
||||||
|
kmap("n", "<leader>T", ":Telescope live_grep theme=ivy<CR>")
|
||||||
|
-- поиск только в открытой дирректории
|
||||||
|
-- kmap("n", "<leader>t", ":Telescope live_grep theme=ivy --find-command=fzf --search_dirs=./<CR>")
|
||||||
|
|
||||||
|
-- переключение в tree
|
||||||
|
kmap("n", "<leader>n", ":NvimTreeFocus<CR>")
|
||||||
|
|
||||||
|
-- навигация между окнами TMUX
|
||||||
|
vim.g.tmux_navigator_no_mappings = 1
|
||||||
|
-- noremap <silent> {Previous-Mapping} :<C-U>TmuxNavigatePrevious<cr>
|
||||||
|
kmap("n", "<C-h>", ":<C-U>TmuxNavigateLeft<cr>")
|
||||||
|
kmap("n", "<C-j>", ":<C-U>TmuxNavigateDown<cr>")
|
||||||
|
kmap("n", "<C-k>", ":<C-U>TmuxNavigateUp<cr>")
|
||||||
|
kmap("n", "<C-l>", ":<C-U>TmuxNavigateRight<cr>")
|
||||||
|
|
||||||
|
-- kmap("n", "<C-h>", "<C-w>h")
|
||||||
|
-- kmap("n", "<C-j>", "<C-w>j")
|
||||||
|
-- kmap("n", "<C-k>", "<C-w>k")
|
||||||
|
-- kmap("n", "<C-l>", "<C-w>l")
|
||||||
|
|
||||||
|
-- изменение размера окна
|
||||||
|
kmap("n", "<C-Up>", ":resize +2<CR>")
|
||||||
|
kmap("n", "<C-Down>", ":resize -2<CR>")
|
||||||
|
kmap("n", "<C-Left>", ":vertical resize -2<CR>")
|
||||||
|
kmap("n", "<C-Right>", ":vertical resize +2<CR>")
|
||||||
|
|
||||||
|
-- навигация по открытым буферам
|
||||||
|
kmap("n", "<TAB>", ":bnext<CR>")
|
||||||
|
kmap("n", "<S-TAB>", ":bprevious<CR>")
|
||||||
|
|
||||||
|
-- перемещение курсора посимвольно во время редактирования
|
||||||
|
kmap("i", "<S-Tab>", "<right>")
|
||||||
|
|
||||||
|
-- свертывание кода
|
||||||
|
kmap("i", "<F2>", "<C-O>za") -- toggle fold
|
||||||
|
kmap("n", "<F2>", "za") -- toggle fold
|
||||||
|
|
||||||
|
-- ===================
|
||||||
|
-- перемещение между вкладками
|
||||||
|
kmap("n", "<S-l>", ":BufferLineCycleNext<CR>")
|
||||||
|
kmap("n", "<S-h>", ":BufferLineCyclePrev<CR>")
|
||||||
|
|
||||||
|
-- HELP
|
||||||
|
-- f-n - переход в текущей строке к слову начинающемуся на n (поиск вперед)
|
||||||
|
-- F-n - переход в текущей строке к слову начинающемуся на n (поиск назад)
|
||||||
|
-- gf - если под курсором имя файла, то будет переход к этому файлу
|
||||||
|
-- '' - переключение между прошлой и текущей позиции курсора
|
||||||
|
end
|
||||||
|
|
||||||
|
return M
|
299
configs/nvim/lua/core/options.lua
Normal file
299
configs/nvim/lua/core/options.lua
Normal file
@ -0,0 +1,299 @@
|
|||||||
|
local M = {}
|
||||||
|
|
||||||
|
local opt = vim.opt
|
||||||
|
local g = vim.g
|
||||||
|
local cmd = vim.cmd
|
||||||
|
|
||||||
|
M.load = function()
|
||||||
|
local options = {
|
||||||
|
-- количество экранных строк для использования в командной строке
|
||||||
|
cmdheight = 0,
|
||||||
|
|
||||||
|
-- копирование вставка между vim и всем остальным (allows neovim to access the system clipboard)
|
||||||
|
clipboard = "unnamedplus",
|
||||||
|
|
||||||
|
-- LVIM creates a backup file
|
||||||
|
backup = false,
|
||||||
|
|
||||||
|
-- всплывающее меню для отображения возможных вариантов завершения.
|
||||||
|
completeopt = { "menuone", "noselect" },
|
||||||
|
|
||||||
|
-- скрытый уровень отключен и текст в `` можно видеть
|
||||||
|
conceallevel = 0,
|
||||||
|
|
||||||
|
-- входная и выходная кодировка
|
||||||
|
fileencoding = "utf-8",
|
||||||
|
encoding = "utf-8",
|
||||||
|
|
||||||
|
-- LVIM set to "nvim_treesitter#foldexpr()" for treesitter based folding
|
||||||
|
-- LVIM folding, set to "manual" for treesitter based folding
|
||||||
|
foldmethod = "expr",
|
||||||
|
foldexpr = "nvim_treesitter#foldexpr()",
|
||||||
|
|
||||||
|
-- устанавливает максимальное вложение складок
|
||||||
|
foldnestmax = 10,
|
||||||
|
-- устанавливает уровень сворачивания: складки с более высоким уровнем будут закрыты.
|
||||||
|
-- Установка этого параметра на ноль закроет все складки . Чем больше число, тем меньше складок .
|
||||||
|
foldlevel = 2,
|
||||||
|
foldlevelstart = 20,
|
||||||
|
|
||||||
|
-- LVIM the font used in graphical neovim applications
|
||||||
|
guifont = "monospace:h17",
|
||||||
|
|
||||||
|
-- LVIM required to keep multiple buffers and open multiple buffers
|
||||||
|
hidden = true,
|
||||||
|
|
||||||
|
-- LVIM highlight all matches on previous search pattern
|
||||||
|
hlsearch = true,
|
||||||
|
|
||||||
|
-- игнорировать регистр в шаблонах поиска.p
|
||||||
|
ignorecase = true,
|
||||||
|
|
||||||
|
-- разрешает использование мыши
|
||||||
|
mouse = "a",
|
||||||
|
|
||||||
|
-- pop up menu height
|
||||||
|
pumheight = 10,
|
||||||
|
|
||||||
|
-- we don't need to see things like -- INSERT -- anymore
|
||||||
|
showmode = false,
|
||||||
|
|
||||||
|
-- если ее включить, то будет линии вверху
|
||||||
|
showtabline = 0,
|
||||||
|
|
||||||
|
-- переопределять значение «IGNORECASE» вариант, если поиск шаблон содержит верхний регистра символов. Используется только при вводе шаблона поиска
|
||||||
|
smartcase = true,
|
||||||
|
|
||||||
|
-- горизонтальное разделение идет ниже
|
||||||
|
splitbelow = true,
|
||||||
|
|
||||||
|
-- вертикально разделение идет вправо
|
||||||
|
splitright = true,
|
||||||
|
|
||||||
|
-- creates a swapfile
|
||||||
|
swapfile = false,
|
||||||
|
|
||||||
|
-- установите цвета графического интерфейса term (большинство терминалов поддерживают это)
|
||||||
|
termguicolors = true,
|
||||||
|
|
||||||
|
-- время ожидания завершения отображаемой последовательности (в миллисекундах)
|
||||||
|
timeoutlen = 400,
|
||||||
|
|
||||||
|
-- LVIM set the title of window to the value of the titlestring
|
||||||
|
-- так и не понял т.к. ни разу не увидел результат работы этого
|
||||||
|
-- title = true,
|
||||||
|
-- titlestring = "%<%F%=%l/%L - nvim",
|
||||||
|
|
||||||
|
-- включено, т.е. если закрыть файл и потом открыть то все равно можно будет делать отмену изменений
|
||||||
|
undofile = true,
|
||||||
|
|
||||||
|
-- более быстрое завершение (по умолчанию 4000 мс)
|
||||||
|
updatetime = 100,
|
||||||
|
|
||||||
|
-- if a file is being edited by another program (or was written to file while editing with another program), it is not allowed to be edited
|
||||||
|
writebackup = false,
|
||||||
|
|
||||||
|
-- конвертирование табы в space
|
||||||
|
expandtab = true,
|
||||||
|
|
||||||
|
-- количество пробелов, вставленных для каждого отступа
|
||||||
|
shiftwidth = 2,
|
||||||
|
|
||||||
|
-- вставьте 2 пробела для табуляции
|
||||||
|
tabstop = 2,
|
||||||
|
|
||||||
|
-- highlight the current line
|
||||||
|
cursorline = true,
|
||||||
|
|
||||||
|
-- оставляет выделение только номера строки
|
||||||
|
cursorlineopt = "number",
|
||||||
|
|
||||||
|
-- устанавливает видимость линий
|
||||||
|
number = true,
|
||||||
|
|
||||||
|
-- ширина столбца с цифрами строко
|
||||||
|
numberwidth = 2,
|
||||||
|
|
||||||
|
-- всегда показывайте столбец со знаком, в противном случае текст каждый раз будет смещаться
|
||||||
|
signcolumn = "yes",
|
||||||
|
|
||||||
|
-- display lines as one long line
|
||||||
|
wrap = false,
|
||||||
|
|
||||||
|
-- не читать из глобального хранилища
|
||||||
|
shadafile = "NONE",
|
||||||
|
|
||||||
|
-- начинать скролить за ... строк до конца экрана
|
||||||
|
scrolloff = 12,
|
||||||
|
|
||||||
|
-- LVIM начинать скролить за ... строк до конца экрана
|
||||||
|
sidescrolloff = 12,
|
||||||
|
|
||||||
|
-- показывать курсор все время
|
||||||
|
ruler = true,
|
||||||
|
|
||||||
|
-- LVM что то связанное со статусной строкой TODO: ПРОВЕРИТЬ !!!
|
||||||
|
-- у меня до LVM стояло 0
|
||||||
|
laststatus = 3,
|
||||||
|
|
||||||
|
-- LVIM что-то связаннное с показом вводимых команд
|
||||||
|
showcmd = false,
|
||||||
|
|
||||||
|
-- НЕ РАССМОТРЕННЫЕ В LVIM
|
||||||
|
-- делает умный автоотступ (make indenting smarter again)
|
||||||
|
smartindent = true,
|
||||||
|
|
||||||
|
-- установите относительные пронумерованные строки
|
||||||
|
relativenumber = true,
|
||||||
|
|
||||||
|
-- не переррисовывать все время https://stackoverflow.com/questions/9341768/vim-response-quite-slow/55501120#55501120
|
||||||
|
lazyredraw = true,
|
||||||
|
|
||||||
|
-- -- макс длина линий для подсветки
|
||||||
|
-- synmaxcol = 1024,
|
||||||
|
|
||||||
|
-- новый движок регулярных выражений
|
||||||
|
-- с ним осторожнее т.к. что-то там не поддерживается
|
||||||
|
-- в command_line
|
||||||
|
-- regexpengine = 1,
|
||||||
|
|
||||||
|
-- делает отступы в зависимости от expandtab. так в док. написано.
|
||||||
|
smarttab = true,
|
||||||
|
|
||||||
|
-- автоотступ
|
||||||
|
autoindent = true,
|
||||||
|
|
||||||
|
-- исправляет поведение backspace на большинстве терминалов.
|
||||||
|
backspace = "indent,eol,start",
|
||||||
|
|
||||||
|
-- -- рабочий каталог всегда будет таким же, как и ваш рабочий каталог
|
||||||
|
-- autochdir = true,
|
||||||
|
|
||||||
|
-- граница кода (черта вертикальная)
|
||||||
|
colorcolumn = "320",
|
||||||
|
|
||||||
|
-- transparent menu
|
||||||
|
pumblend = 50,
|
||||||
|
|
||||||
|
-- transparent popup
|
||||||
|
winblend = 5,
|
||||||
|
|
||||||
|
-- softtabstop
|
||||||
|
softtabstop = 2,
|
||||||
|
|
||||||
|
-- disable tilde on end of buffer: https://github.com/neovim/neovim/pull/8546#issuecomment-643643758
|
||||||
|
fillchars = { eob = " " },
|
||||||
|
|
||||||
|
-- Устанавливает режимы, в которых текст в строке курсора также может быть скрыт.
|
||||||
|
concealcursor = "vin",
|
||||||
|
|
||||||
|
wildignorecase = true,
|
||||||
|
viminfo="'1000,f1"
|
||||||
|
}
|
||||||
|
|
||||||
|
-- Когда значение 'verbose' не равно нулю, печатаются сообщения (для отладки в stderr).
|
||||||
|
cmd [[set verbose=0]]
|
||||||
|
|
||||||
|
-- HERE
|
||||||
|
-- попробовать
|
||||||
|
-- отключает коментарии пред новыми строками ( попробовать если не рабортает qrn1)
|
||||||
|
cmd [[set formatoptions-=cro]]
|
||||||
|
|
||||||
|
-- HERE
|
||||||
|
-- а может стоит отключить это ???
|
||||||
|
cmd [[let g:ale_cpp_clangd_options = "-std=c++20"]]
|
||||||
|
|
||||||
|
for k, v in pairs(options) do
|
||||||
|
opt[k] = v
|
||||||
|
end
|
||||||
|
|
||||||
|
-- -------------------------------
|
||||||
|
-- HERE
|
||||||
|
-- проверить то что ниже ВСЕ. нужно оно или нет
|
||||||
|
-- И перенести чтокасается opt в конфигурацию выше (если это нужно)
|
||||||
|
-- Так же проверить все выше, зачем это и что это такое и остаитьв коменты там где их нет
|
||||||
|
-- -------------------------------
|
||||||
|
|
||||||
|
-- перенести linebreak в нужную часть кода
|
||||||
|
-- это перености сткроки по пробелам или по знакам припинания
|
||||||
|
vim.wo.linebreak = true
|
||||||
|
|
||||||
|
-- позволит вашему курсору выйти за конец строки на один символ
|
||||||
|
vim.opt.virtualedit = { "block", "onemore" }
|
||||||
|
|
||||||
|
-- очевидно вроде
|
||||||
|
vim.opt.shell = "/bin/zsh"
|
||||||
|
|
||||||
|
-- совместимость с st, true colors
|
||||||
|
vim["&t_8f"] = "\\<Esc>[38;2;%lu;%lu;%lum"
|
||||||
|
vim["&t_8b"] = "\\<Esc>[48;2;%lu;%lu;%lum"
|
||||||
|
opt.termguicolors = true
|
||||||
|
|
||||||
|
-- просто отключает подробные обычные сообщения.(см. :h shortmess)
|
||||||
|
opt.shortmess:append "c"
|
||||||
|
|
||||||
|
-- переход к предыдущей / следующей строке с помощью h, l, стрелки влево и стрелки вправо, когда курсор достигает конца / начала строки
|
||||||
|
opt.whichwrap:append "<,>,[,],h,l"
|
||||||
|
|
||||||
|
-- отключить проверку орфографии для азиатских символов (алгоритм VIM ее не поддерживает)
|
||||||
|
opt.spelllang:append "cjk"
|
||||||
|
|
||||||
|
-- отключаем некоторые vim плагины
|
||||||
|
local disabled_plugins = {
|
||||||
|
"2html_plugin",
|
||||||
|
"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"
|
||||||
|
}
|
||||||
|
|
||||||
|
local default_providers = {
|
||||||
|
"node",
|
||||||
|
"perl",
|
||||||
|
"python3",
|
||||||
|
"ruby",
|
||||||
|
"filetype"
|
||||||
|
}
|
||||||
|
|
||||||
|
for _, plugin in pairs(disabled_plugins) do
|
||||||
|
g["loaded_" .. plugin] = 1
|
||||||
|
end
|
||||||
|
|
||||||
|
for _, provider in ipairs(default_providers) do
|
||||||
|
g["loaded_" .. provider .. "_provider"] = 0
|
||||||
|
end
|
||||||
|
|
||||||
|
-- Автоматическое удаление завершающих новых строк при записи файла
|
||||||
|
-- не рабботает с md файлами
|
||||||
|
-- Remember foldings
|
||||||
|
vim.cmd [[
|
||||||
|
augroup remember_folds
|
||||||
|
autocmd!
|
||||||
|
autocmd BufWinLeave * silent! mkview
|
||||||
|
autocmd BufWinEnter * silent! loadview
|
||||||
|
augroup end
|
||||||
|
]]
|
||||||
|
end
|
||||||
|
|
||||||
|
return M
|
124
configs/nvim/lua/plugins/configs/alpha.lua
Normal file
124
configs/nvim/lua/plugins/configs/alpha.lua
Normal file
@ -0,0 +1,124 @@
|
|||||||
|
-- стартовый экран
|
||||||
|
return {
|
||||||
|
"goolord/alpha-nvim",
|
||||||
|
config = function()
|
||||||
|
local alpha = require"alpha"
|
||||||
|
|
||||||
|
-- устанавливаем стиль
|
||||||
|
local group = { AlphaHeader = { fg = "#4e4e58" }, AlphaButtons = { fg = "#5a5a64" } }
|
||||||
|
for hl, col in pairs(group) do
|
||||||
|
vim.api.nvim_set_hl(0, hl, col)
|
||||||
|
end
|
||||||
|
|
||||||
|
local function button(sc, txt, keybind)
|
||||||
|
local sc_ = sc:gsub("%s", ""):gsub("SPC", "<leader>")
|
||||||
|
|
||||||
|
local opts = {
|
||||||
|
position = "center",
|
||||||
|
text = txt,
|
||||||
|
shortcut = sc,
|
||||||
|
cursor = 5,
|
||||||
|
width = 36,
|
||||||
|
align_shortcut = "right",
|
||||||
|
hl = "AlphaButtons"
|
||||||
|
}
|
||||||
|
|
||||||
|
if keybind then
|
||||||
|
opts.keymap = { "n", sc_, keybind, { noremap = true, silent = true } }
|
||||||
|
end
|
||||||
|
|
||||||
|
return {
|
||||||
|
type = "button",
|
||||||
|
val = txt,
|
||||||
|
on_press = function()
|
||||||
|
local key = vim.api.nvim_replace_termcodes(sc_, true, false, true) or ""
|
||||||
|
vim.api.nvim_feedkeys(key, "normal", false)
|
||||||
|
end,
|
||||||
|
opts = opts
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
|
-- отступы
|
||||||
|
local fn = vim.fn
|
||||||
|
local marginTopPercent = 0.3
|
||||||
|
local headerPadding = fn.max { 2, fn.floor(fn.winheight(0) * marginTopPercent) }
|
||||||
|
|
||||||
|
local options = {
|
||||||
|
header = {
|
||||||
|
type = "text",
|
||||||
|
val = {
|
||||||
|
[[⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⣤⣴⡶⠶⠒⠛⠛⠛⠛⠒⠶⢶⣦⣤⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ]],
|
||||||
|
[[⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣠⣶⠞⠋⠉⠁⣀⠀⠀⠀⣴⣶⣦⡀⣠⣴⣦⠀⠈⠉⠙⠳⣶⣄⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀]],
|
||||||
|
[[⠀⠀⠀⠀⠀⠀⠀⣀⣴⠟⠉⠀⣀⠀⣀⣾⣿⣷⣦⣿⣿⣿⣿⣿⣿⣿⣿⣿⢀⣀⣴⡆⠀⠉⠻⣦⣀⠀⠀⠀⠀⠀⠀⠀]],
|
||||||
|
[[⠀⠀⠀⠀⠀⢠⡾⠋⠀⡀⠀⢠⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣇⣤⣷⠀⠀⠙⢷⡄⠀⠀⠀⠀⠀]],
|
||||||
|
[[⠀⠀⠀⢀⣴⠟⠀⠀⠀⣿⣶⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠀⠀⠀⠀⠻⣦⡀⠀⠀⠀]],
|
||||||
|
[[⠀⠀⢠⣾⠃⠀⠀⠀⠈⣿⣿⣿⣿⣿⣿⠿⣿⣟⠛⠉⢿⣿⢯⡛⠉⠛⠿⣿⣟⢿⣿⣿⣿⣿⡄⠀⠀⠀⠀⠘⣷⡄⠀⠀]],
|
||||||
|
[[⠀⠀⡾⠁⠀⠀⠀⠀⠀⣹⣿⣿⣿⡏⠀⠁⠀⠀⠀⠀⠀⠉⠁⠑⠀⠀⠀⠀⠀⠁⠙⣿⣿⣿⡇⠀⠀⠀⠀⠀⠈⢷⠀⠀]],
|
||||||
|
[[⠀⣾⠃⠀⠀⠀⠀⠀⠀⠹⣿⣿⣿⠇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⡀⠀⠀⣿⣿⣿⠇⠀⠀⠀⠀⠀⠀⠘⣷⠀]],
|
||||||
|
[[⢰⡟⠀⠀⠀⠀⠀⠀⠀⠈⢻⣿⡏⡀⠄⠚⠙⢄⠀⠀⠀⠀⠀⠀⠀⠀⡠⠋⡀⠓⠄⣿⣿⡗⠀⠀⠀⠀⠀⠀⠀⠀⢻⡆]],
|
||||||
|
[[⢸⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⢻⡇⠀⠐⢢⡐⢌⠑⡄⠀⠀⠀⠀⢀⠎⡡⣢⠕⠉⢰⣿⡟⠁⠀⠀⠀⠀⠀⠀⠀⠀⠘⡇]],
|
||||||
|
[[⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⡇⠀⠀⡎⠈⠢⢕⡈⠂⠀⠀⠲⢁⠲⠊⠉⡆⠀⢸⡟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿]],
|
||||||
|
[[⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⡠⠊⠃⠀⠀⡇⠰⠆⢸⣾⡀⠀⠀⢀⣿⠀⢰⠀⠀⠀⠀⠏⠒⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿]],
|
||||||
|
[[⢸⡀⠀⠀⠀⠀⠀⠀⠀⡜⠀⣤⡃⠸⣭⣫⣉⡓⠾⠛⡃⠀⢀⠚⠻⢞⣋⣉⣯⠇⠸⡘⠉⢸⠀⠀⠀⠀⠀⠀⠀⠀⢠⡇]],
|
||||||
|
[[⠸⣧⠀⠀⠀⠀⠀⠀⠀⢇⠀⢁⡇⠀⠉⠉⠉⠉⠉⠉⡅⠀⠈⠉⠉⠉⠉⠉⠉⠀⠀⠓⠀⠂⠀⠀⠀⠀⠀⠀⠀⠀⣼⠇]],
|
||||||
|
[[⠀⢿⡄⠀⠀⠀⠀⠀⠀⠀⠈⣴⠀⠀⠀⠀⠀⠀⠀⠐⢀⠀⠀⠀⠀⡄⠀⠀⠀⠀⠀⠈⡄⠀⠀⠀⠀⠀⠀⠀⠀⢠⡿⠀]],
|
||||||
|
[[⠀⠀⢷⡀⠀⠀⠀⠀⠀⠀⠀⠃⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠎⠀⠀⠀⠀⠀⠀⠀⢹⠀⠀⠀⠀⠀⠀⠀⢀⡾⠀⠀]],
|
||||||
|
[[⠀⠀⠘⢿⡄⠀⠀⠀⠀⠀⢰⠀⠀⠀⠀⠀⠀⠀⢀⠤⠐⢋⡀⠸⠀⠀⠀⠀⠀⠀⠀⠀⢠⠇⠀⠀⠀⠀⠀⢠⡿⠃⠀⠀]],
|
||||||
|
[[⠀⠀⠀⠈⠻⣦⠀⠀⠀⠀⠈⡀⠀⠀⠀⠀⠀⠀⠁⠀⠀⠁⠈⠁⠆⠀⠀⠀⠀⠀⠀⢀⠞⠀⠀⠀⠀⠀⣴⠟⠁⠀⠀⠀]],
|
||||||
|
[[⠀⠀⠀⠀⠀⠘⢷⣄⠀⠀⠀⠁⠠⢄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⡤⠤⠒⠋⠀⠀⠀⠀⣠⡾⠃⠀⠀⠀⠀⠀]],
|
||||||
|
[[⠀⠀⠀⠀⠀⠀⠀⠉⠻⣦⣀⠀⠀⠀⠀⠀⠁⠀⢄⠀⠀⠀⠀⠀⠀⢀⠌⠀⠀⠀⠀⠀⠀⣀⣴⠟⠉⠀⠀⠀⠀⠀⠀⠀]],
|
||||||
|
[[⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠙⠿⢦⣄⣀⡀⠀⠀⠀⠈⠠⠀⣀⡀⠄⠁⠀⠀⢀⣀⣠⡴⠿⠋⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀]],
|
||||||
|
[[⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠙⠛⠻⠷⠶⠤⣤⣤⣤⣤⠤⠶⠾⠟⠛⠋⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀]],
|
||||||
|
},
|
||||||
|
opts = {
|
||||||
|
position = "center",
|
||||||
|
hl = "AlphaHeader"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
buttons = {
|
||||||
|
type = "group",
|
||||||
|
val = {
|
||||||
|
button(".", " Open current", ":ene <CR>:NvimTreeFindFileToggle<CR>"),
|
||||||
|
button("u", " Update", ":!backup_nvim<CR> | :PackerSync<CR>"),
|
||||||
|
button("f", " Find file", ":Telescope find_files<CR>"),
|
||||||
|
button("r", " Recent File", ":Telescope oldfiles<CR>"),
|
||||||
|
button("w", " Find Word", ":Telescope live_grep<CR>"),
|
||||||
|
button("c", " Configs", ":e $MYVIMRC | :cd %:p:h <CR>:NvimTreeFindFileToggle<CR>"),
|
||||||
|
},
|
||||||
|
opts = {
|
||||||
|
spacing = 1
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
headerPaddingTop = { type = "padding", val = headerPadding },
|
||||||
|
headerPaddingBottom = { type = "padding", val = 2 }
|
||||||
|
}
|
||||||
|
|
||||||
|
alpha.setup {
|
||||||
|
layout = {
|
||||||
|
options.headerPaddingTop,
|
||||||
|
options.header,
|
||||||
|
options.headerPaddingBottom,
|
||||||
|
options.buttons
|
||||||
|
},
|
||||||
|
opts = {}
|
||||||
|
}
|
||||||
|
|
||||||
|
-- отключаем statusline
|
||||||
|
vim.api.nvim_create_autocmd("FileType", {
|
||||||
|
pattern = "alpha",
|
||||||
|
callback = function()
|
||||||
|
-- сохраняем текущее statusline
|
||||||
|
local old_laststatus = vim.opt.laststatus
|
||||||
|
vim.api.nvim_create_autocmd("BufUnload", {
|
||||||
|
buffer = 0,
|
||||||
|
callback = function()
|
||||||
|
vim.opt.laststatus = old_laststatus
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
vim.opt.laststatus = 0
|
||||||
|
end
|
||||||
|
})
|
||||||
|
end
|
||||||
|
}
|
15
configs/nvim/lua/plugins/configs/autopairs.lua
Normal file
15
configs/nvim/lua/plugins/configs/autopairs.lua
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
-- ставит две скобки {}, ()
|
||||||
|
return {
|
||||||
|
"windwp/nvim-autopairs",
|
||||||
|
config = function()
|
||||||
|
local autopairs = require"nvim-autopairs"
|
||||||
|
|
||||||
|
local options = {
|
||||||
|
fast_wrap = {},
|
||||||
|
disable_filetype = { "TelescopePrompt", "vim" }
|
||||||
|
}
|
||||||
|
|
||||||
|
autopairs.setup(options)
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|
18
configs/nvim/lua/plugins/configs/autosave.lua
Normal file
18
configs/nvim/lua/plugins/configs/autosave.lua
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
-- autosave
|
||||||
|
return {
|
||||||
|
"907th/vim-auto-save",
|
||||||
|
config = function()
|
||||||
|
local g = vim.g
|
||||||
|
g.auto_save = 1
|
||||||
|
end
|
||||||
|
}
|
||||||
|
-- еще один другой плагин для сохранения
|
||||||
|
-- но выше он лучше потому что при переходе с кода в дерево он не выводит сообщения и не тормозит.
|
||||||
|
-- этот ниеж, на всякий случай.
|
||||||
|
-- return {
|
||||||
|
-- "okuuva/auto-save.nvim",
|
||||||
|
-- cmd = "ASToggle",
|
||||||
|
-- event = { "InsertLeave", "TextChanged" },
|
||||||
|
-- opts = { }
|
||||||
|
-- }
|
||||||
|
|
38
configs/nvim/lua/plugins/configs/blankline.lua
Normal file
38
configs/nvim/lua/plugins/configs/blankline.lua
Normal file
@ -0,0 +1,38 @@
|
|||||||
|
-- добавляет направляющие отступов ко всем строкам (включая пустые строки).
|
||||||
|
return {
|
||||||
|
"lukas-reineke/indent-blankline.nvim",
|
||||||
|
main = "ibl",
|
||||||
|
config = function()
|
||||||
|
local blankline = require"ibl"
|
||||||
|
|
||||||
|
local options = {
|
||||||
|
exclude = {
|
||||||
|
filetypes = {
|
||||||
|
"help",
|
||||||
|
"terminal",
|
||||||
|
"alpha",
|
||||||
|
"packer",
|
||||||
|
"lspinfo",
|
||||||
|
"TelescopePrompt",
|
||||||
|
"TelescopeResults",
|
||||||
|
"mason",
|
||||||
|
"checkhealth",
|
||||||
|
"man",
|
||||||
|
""
|
||||||
|
},
|
||||||
|
buftypes = {
|
||||||
|
"terminal"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
whitespace = {
|
||||||
|
remove_blankline_trail = true
|
||||||
|
},
|
||||||
|
scope = {
|
||||||
|
enabled = true,
|
||||||
|
highlight = { "SpecialKey", "SpecialKey", "SpecialKey" },
|
||||||
|
show_start = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
blankline.setup(options)
|
||||||
|
end
|
||||||
|
}
|
42
configs/nvim/lua/plugins/configs/bufferline.lua
Normal file
42
configs/nvim/lua/plugins/configs/bufferline.lua
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
-- верхняя панель буферов (открытых вкладок)
|
||||||
|
return {
|
||||||
|
"akinsho/bufferline.nvim",
|
||||||
|
version = "*",
|
||||||
|
dependencies = {
|
||||||
|
"kyazdani42/nvim-web-devicons"
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
local bufferline = require"bufferline"
|
||||||
|
|
||||||
|
bufferline.setup {
|
||||||
|
options = {
|
||||||
|
numbers = "none",
|
||||||
|
close_command = "Bdelete! %d",
|
||||||
|
right_mouse_command = "Bdelete! %d",
|
||||||
|
left_mouse_command = "buffer %d",
|
||||||
|
middle_mouse_command = nil,
|
||||||
|
indicator = "▎",
|
||||||
|
buffer_close_icon = "",
|
||||||
|
modified_icon = "●",
|
||||||
|
close_icon = "",
|
||||||
|
left_trunc_marker = "",
|
||||||
|
right_trunc_marker = "",
|
||||||
|
max_name_length = 30,
|
||||||
|
max_prefix_length = 30,
|
||||||
|
tab_size = 18,
|
||||||
|
diagnostics = false,
|
||||||
|
diagnostics_update_in_insert = false,
|
||||||
|
offsets = { { filetype = "NvimTree", text = "", padding = 1 } },
|
||||||
|
show_buffer_icons = true,
|
||||||
|
show_buffer_close_icons = true,
|
||||||
|
show_close_icon = true,
|
||||||
|
show_tab_indicators = true,
|
||||||
|
persist_buffer_sort = true,
|
||||||
|
separator_style = "thin",
|
||||||
|
enforce_regular_tabs = true,
|
||||||
|
always_show_bufferline = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|
105
configs/nvim/lua/plugins/configs/cmp.lua
Normal file
105
configs/nvim/lua/plugins/configs/cmp.lua
Normal file
@ -0,0 +1,105 @@
|
|||||||
|
-- автозавершение
|
||||||
|
return {
|
||||||
|
"hrsh7th/nvim-cmp",
|
||||||
|
event = "InsertEnter",
|
||||||
|
dependencies = {
|
||||||
|
-- автозаполнители
|
||||||
|
"hrsh7th/cmp-buffer", -- source for text in buffer
|
||||||
|
"hrsh7th/cmp-path", -- source for file system paths
|
||||||
|
"L3MON4D3/LuaSnip", -- snippet engine
|
||||||
|
"saadparwaiz1/cmp_luasnip", -- for autocompletion
|
||||||
|
"rafamadriz/friendly-snippets", -- useful snippets
|
||||||
|
"onsails/lspkind.nvim", -- vs-code like pictograms
|
||||||
|
"hrsh7th/cmp-nvim-lsp",
|
||||||
|
"hrsh7th/cmp-nvim-lsp-signature-help",
|
||||||
|
"hrsh7th/cmp-cmdline",
|
||||||
|
"hrsh7th/cmp-nvim-lua"
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
local cmp = require"cmp"
|
||||||
|
|
||||||
|
vim.o.completeopt = "menu,menuone,noselect"
|
||||||
|
|
||||||
|
local function border(hl_name)
|
||||||
|
return {
|
||||||
|
{ "╭", hl_name },
|
||||||
|
{ "─", hl_name },
|
||||||
|
{ "╮", hl_name },
|
||||||
|
{ "│", hl_name },
|
||||||
|
{ "╯", hl_name },
|
||||||
|
{ "─", hl_name },
|
||||||
|
{ "╰", hl_name },
|
||||||
|
{ "│", hl_name }
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
|
local options = {
|
||||||
|
window = {
|
||||||
|
completion = {
|
||||||
|
border = border "CmpBorder",
|
||||||
|
winhighlight = "Normal:CmpPmenu,CursorLine:PmenuSel,Search:None"
|
||||||
|
},
|
||||||
|
documentation = {
|
||||||
|
border = border "CmpDocBorder"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
snippet = {
|
||||||
|
expand = function(args)
|
||||||
|
require("luasnip").lsp_expand(args.body)
|
||||||
|
end
|
||||||
|
},
|
||||||
|
formatting = {
|
||||||
|
format = function(_, vim_item)
|
||||||
|
local icons = require("core.icons").kind
|
||||||
|
vim_item.kind = string.format("%s %s", icons[vim_item.kind], vim_item.kind)
|
||||||
|
return vim_item
|
||||||
|
end
|
||||||
|
},
|
||||||
|
mapping = {
|
||||||
|
["<C-p>"] = cmp.mapping.select_prev_item(),
|
||||||
|
["<C-n>"] = cmp.mapping.select_next_item(),
|
||||||
|
["<C-d>"] = cmp.mapping.scroll_docs(-4),
|
||||||
|
["<C-f>"] = cmp.mapping.scroll_docs(4),
|
||||||
|
["<C-Space>"] = cmp.mapping.complete(),
|
||||||
|
["<C-e>"] = cmp.mapping.close(),
|
||||||
|
["<CR>"] = cmp.mapping.confirm {
|
||||||
|
behavior = cmp.ConfirmBehavior.Replace,
|
||||||
|
select = false
|
||||||
|
},
|
||||||
|
["<Tab>"] = cmp.mapping(function(fallback)
|
||||||
|
if cmp.visible() then
|
||||||
|
cmp.select_next_item()
|
||||||
|
elseif require("luasnip").expand_or_jumpable() then
|
||||||
|
vim.fn.feedkeys(vim.api.nvim_replace_termcodes("<Plug>luasnip-expand-or-jump", true, true, true), "")
|
||||||
|
else
|
||||||
|
fallback()
|
||||||
|
end
|
||||||
|
end, {
|
||||||
|
"i",
|
||||||
|
"s"
|
||||||
|
}),
|
||||||
|
["<S-Tab>"] = cmp.mapping(function(fallback)
|
||||||
|
if cmp.visible() then
|
||||||
|
cmp.select_prev_item()
|
||||||
|
elseif require("luasnip").jumpable(-1) then
|
||||||
|
vim.fn.feedkeys(vim.api.nvim_replace_termcodes("<Plug>luasnip-jump-prev", true, true, true), "")
|
||||||
|
else
|
||||||
|
fallback()
|
||||||
|
end
|
||||||
|
end, {
|
||||||
|
"i",
|
||||||
|
"s"
|
||||||
|
}),
|
||||||
|
},
|
||||||
|
sources = {
|
||||||
|
{ name = "luasnip" },
|
||||||
|
{ name = "nvim_lsp" },
|
||||||
|
{ name = "buffer" },
|
||||||
|
{ name = "nvim_lua" },
|
||||||
|
{ name = "path" }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
cmp.setup(options)
|
||||||
|
end
|
||||||
|
}
|
56
configs/nvim/lua/plugins/configs/colorscheme.lua
Normal file
56
configs/nvim/lua/plugins/configs/colorscheme.lua
Normal file
@ -0,0 +1,56 @@
|
|||||||
|
--colorschemes
|
||||||
|
return {
|
||||||
|
"catppuccin/nvim",
|
||||||
|
name = "catppuccin",
|
||||||
|
priority = 1000,
|
||||||
|
config = function()
|
||||||
|
local catppuccin = require"catppuccin"
|
||||||
|
|
||||||
|
local opt = {
|
||||||
|
flavour = "mocha", -- latte, frappe, macchiato, mocha
|
||||||
|
background = { -- :h background
|
||||||
|
light = "mocha",
|
||||||
|
dark = "mocha"
|
||||||
|
},
|
||||||
|
transparent_background = false,
|
||||||
|
term_colors = false,
|
||||||
|
dim_inactive = {
|
||||||
|
enabled = false,
|
||||||
|
shade = "dark",
|
||||||
|
percentage = 0.15
|
||||||
|
},
|
||||||
|
no_italic = false, -- Force no italic
|
||||||
|
no_bold = false, -- Force no bold
|
||||||
|
styles = {
|
||||||
|
comments = { "italic" },
|
||||||
|
conditionals = { "italic" },
|
||||||
|
loops = {},
|
||||||
|
functions = {},
|
||||||
|
keywords = {},
|
||||||
|
strings = {},
|
||||||
|
variables = {},
|
||||||
|
numbers = {},
|
||||||
|
booleans = {},
|
||||||
|
properties = {},
|
||||||
|
types = {},
|
||||||
|
operators = {}
|
||||||
|
},
|
||||||
|
color_overrides = {},
|
||||||
|
custom_highlights = {},
|
||||||
|
integrations = {
|
||||||
|
cmp = true,
|
||||||
|
gitsigns = true,
|
||||||
|
nvimtree = true,
|
||||||
|
telescope = true,
|
||||||
|
notify = false,
|
||||||
|
mini = false
|
||||||
|
-- For more plugins integrations please scroll down (https://github.com/catppuccin/nvim#integrations)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
catppuccin.setup(opt)
|
||||||
|
|
||||||
|
-- setup must be called before loading
|
||||||
|
vim.cmd.colorscheme "catppuccin"
|
||||||
|
end
|
||||||
|
}
|
10
configs/nvim/lua/plugins/configs/comment.lua
Normal file
10
configs/nvim/lua/plugins/configs/comment.lua
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
-- комментирование блоками
|
||||||
|
return {
|
||||||
|
"numToStr/Comment.nvim",
|
||||||
|
lazy = false,
|
||||||
|
config = function()
|
||||||
|
require("Comment").setup{}
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|
||||||
|
|
5
configs/nvim/lua/plugins/configs/dressing.lua
Normal file
5
configs/nvim/lua/plugins/configs/dressing.lua
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
-- взаимодействует с апи nvim для отображения UI
|
||||||
|
return {
|
||||||
|
"stevearc/dressing.nvim",
|
||||||
|
event = "VeryLazy"
|
||||||
|
}
|
9
configs/nvim/lua/plugins/configs/highlight.lua
Normal file
9
configs/nvim/lua/plugins/configs/highlight.lua
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
-- подсветка цветов типа #333
|
||||||
|
return {
|
||||||
|
"brenoprata10/nvim-highlight-colors",
|
||||||
|
config = function()
|
||||||
|
require("nvim-highlight-colors").setup{}
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|
||||||
|
|
8
configs/nvim/lua/plugins/configs/hop.lua
Normal file
8
configs/nvim/lua/plugins/configs/hop.lua
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
-- перемещение по ключам
|
||||||
|
return {
|
||||||
|
"smoka7/hop.nvim",
|
||||||
|
version = "*",
|
||||||
|
opts = {}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
35
configs/nvim/lua/plugins/configs/init.lua
Normal file
35
configs/nvim/lua/plugins/configs/init.lua
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
-- тут конфимги которые специально не нужно что-то там накстраивать
|
||||||
|
return {
|
||||||
|
-- набор иконок
|
||||||
|
"kyazdani42/nvim-web-devicons",
|
||||||
|
|
||||||
|
-- wiki
|
||||||
|
"vimwiki/vimwiki",
|
||||||
|
|
||||||
|
-- улачшает копипасту и следит за ее историей
|
||||||
|
"hrsh7th/nvim-pasta",
|
||||||
|
|
||||||
|
-- popup api
|
||||||
|
"nvim-lua/popup.nvim",
|
||||||
|
|
||||||
|
-- улучшает код lua и используеьтся во многи плагинах ниже
|
||||||
|
"nvim-lua/plenary.nvim",
|
||||||
|
|
||||||
|
-- просмотр изображений, PDF-файлов, ePub, видео и шрифтов из Neovim с помощью Telescope.
|
||||||
|
"nvim-telescope/telescope-media-files.nvim",
|
||||||
|
|
||||||
|
-- расширение файлового браузера для Telescope
|
||||||
|
"nvim-telescope/telescope-file-browser.nvim",
|
||||||
|
|
||||||
|
-- конфиг для mason
|
||||||
|
"williamboman/mason-lspconfig.nvim",
|
||||||
|
|
||||||
|
-- снипеты для языков
|
||||||
|
"rafamadriz/friendly-snippets",
|
||||||
|
|
||||||
|
-- autotag для vue, js, ts и т.п.
|
||||||
|
"windwp/nvim-ts-autotag",
|
||||||
|
|
||||||
|
-- закрывает вкладки. буз него buferline плохо работает
|
||||||
|
"moll/vim-bbye"
|
||||||
|
}
|
172
configs/nvim/lua/plugins/configs/lsp/lsp_configs.lua
Normal file
172
configs/nvim/lua/plugins/configs/lsp/lsp_configs.lua
Normal file
@ -0,0 +1,172 @@
|
|||||||
|
-- конфии lsp
|
||||||
|
return {
|
||||||
|
"neovim/nvim-lspconfig",
|
||||||
|
event = { "BufReadPre", "BufNewFile" },
|
||||||
|
dependencies = {
|
||||||
|
"hrsh7th/cmp-nvim-lsp",
|
||||||
|
{ "antosha417/nvim-lsp-file-operations", config = true },
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
-- import lspconfig plugin
|
||||||
|
local lspconfig = require("lspconfig")
|
||||||
|
|
||||||
|
-- import cmp-nvim-lsp plugin
|
||||||
|
local cmp_nvim_lsp = require("cmp_nvim_lsp")
|
||||||
|
|
||||||
|
local on_attach = function(_, bufnr)
|
||||||
|
local keymap = vim.keymap
|
||||||
|
local opts = { noremap = true, silent = true }
|
||||||
|
|
||||||
|
opts.buffer = bufnr
|
||||||
|
|
||||||
|
opts.desc = "Show LSP references"
|
||||||
|
keymap.set("n", "gR", "<cmd>Telescope lsp_references<CR>", opts)
|
||||||
|
|
||||||
|
opts.desc = "Go to declaration"
|
||||||
|
keymap.set("n", "gD", vim.lsp.buf.declaration, opts)
|
||||||
|
|
||||||
|
opts.desc = "Show LSP definitions"
|
||||||
|
keymap.set("n", "gd", "<cmd>Telescope lsp_definitions<CR>", opts)
|
||||||
|
|
||||||
|
opts.desc = "Show LSP implementations"
|
||||||
|
keymap.set("n", "gi", "<cmd>Telescope lsp_implementations<CR>", opts)
|
||||||
|
|
||||||
|
opts.desc = "Show LSP type definitions"
|
||||||
|
keymap.set("n", "gt", "<cmd>Telescope lsp_type_definitions<CR>", opts)
|
||||||
|
|
||||||
|
opts.desc = "See available code actions"
|
||||||
|
keymap.set({ "n", "v" }, "<leader>ca", vim.lsp.buf.code_action, opts)
|
||||||
|
|
||||||
|
opts.desc = "Smart rename"
|
||||||
|
keymap.set("n", "<leader>rn", vim.lsp.buf.rename, opts)
|
||||||
|
|
||||||
|
opts.desc = "Show buffer diagnostics"
|
||||||
|
keymap.set("n", "<leader>D", "<cmd>Telescope diagnostics bufnr=0<CR>", opts)
|
||||||
|
|
||||||
|
opts.desc = "Show line diagnostics"
|
||||||
|
keymap.set("n", "<leader>d", vim.diagnostic.open_float, opts)
|
||||||
|
|
||||||
|
opts.desc = "Go to next diagnostic"
|
||||||
|
keymap.set("n", "<leader>e", vim.diagnostic.goto_next, opts)
|
||||||
|
|
||||||
|
opts.desc = "Show documentation for what is under cursor"
|
||||||
|
keymap.set("n", "K", vim.lsp.buf.hover, opts)
|
||||||
|
|
||||||
|
opts.desc = "Restart LSP"
|
||||||
|
keymap.set("n", "<leader>rs", ":LspRestart<CR>", opts)
|
||||||
|
end
|
||||||
|
|
||||||
|
-- used to enable autocompletion (assign to every lsp server config)
|
||||||
|
local capabilities = cmp_nvim_lsp.default_capabilities()
|
||||||
|
|
||||||
|
-- Change the Diagnostic symbols in the sign column (gutter)
|
||||||
|
local signs = { Error = " ", Warn = " ", Hint = " ", Info = " " }
|
||||||
|
for type, icon in pairs(signs) do
|
||||||
|
local hl = "DiagnosticSign" .. type
|
||||||
|
vim.fn.sign_define(hl, { text = icon, texthl = hl, numhl = "" })
|
||||||
|
end
|
||||||
|
|
||||||
|
-- configure html server
|
||||||
|
lspconfig["html"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure typescript server with plugin
|
||||||
|
lspconfig["tsserver"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure css server
|
||||||
|
lspconfig["cssls"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure tailwindcss server
|
||||||
|
lspconfig["tailwindcss"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure svelte server
|
||||||
|
lspconfig["svelte"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = function(client, bufnr)
|
||||||
|
on_attach(client, bufnr)
|
||||||
|
|
||||||
|
vim.api.nvim_create_autocmd("BufWritePost", {
|
||||||
|
pattern = { "*.js", "*.ts" },
|
||||||
|
callback = function(ctx)
|
||||||
|
if client.name == "svelte" then
|
||||||
|
client.notify("$/onDidChangeTsOrJsFile", { uri = ctx.file })
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure prisma orm server
|
||||||
|
lspconfig["prismals"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure graphql language server
|
||||||
|
lspconfig["graphql"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
filetypes = { "graphql", "gql", "svelte", "typescriptreact", "javascriptreact" },
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure emmet language server
|
||||||
|
lspconfig["emmet_ls"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
filetypes = { "html", "typescriptreact", "javascriptreact", "css", "sass", "scss", "less", "svelte" },
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure python server
|
||||||
|
lspconfig["pyright"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure clang server
|
||||||
|
lspconfig["clangd"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure lua server (with special settings)
|
||||||
|
lspconfig["lua_ls"].setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = on_attach,
|
||||||
|
settings = { -- custom settings for lua
|
||||||
|
Lua = {
|
||||||
|
-- make the language server recognize "vim" global
|
||||||
|
diagnostics = {
|
||||||
|
globals = { "vim" },
|
||||||
|
},
|
||||||
|
workspace = {
|
||||||
|
-- make language server aware of runtime files
|
||||||
|
library = {
|
||||||
|
[vim.fn.expand("$VIMRUNTIME/lua")] = true,
|
||||||
|
[vim.fn.stdpath("config") .. "/lua"] = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
-- configure for c#
|
||||||
|
-- нужно установить yay -S omnisharp-roslyn
|
||||||
|
local pid = vim.fn.getpid()
|
||||||
|
local omnisharp_bin = "/usr/bin/OmniSharp"
|
||||||
|
|
||||||
|
lspconfig["omnisharp"].setup{
|
||||||
|
cmd = { omnisharp_bin, "--languageserver" , "--hostPID", tostring(pid) }
|
||||||
|
}
|
||||||
|
end,
|
||||||
|
}
|
54
configs/nvim/lua/plugins/configs/lsp/mason.lua
Normal file
54
configs/nvim/lua/plugins/configs/lsp/mason.lua
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
-- для работы с LSP
|
||||||
|
return {
|
||||||
|
"williamboman/mason.nvim",
|
||||||
|
dependencies = {
|
||||||
|
"williamboman/mason-lspconfig.nvim",
|
||||||
|
"WhoIsSethDaniel/mason-tool-installer.nvim"
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
local mason = require("mason")
|
||||||
|
local mason_lspconfig = require("mason-lspconfig")
|
||||||
|
local mason_tool_installer = require("mason-tool-installer")
|
||||||
|
|
||||||
|
-- enable mason and configure icons
|
||||||
|
mason.setup({
|
||||||
|
ui = {
|
||||||
|
icons = {
|
||||||
|
package_installed = "✓",
|
||||||
|
package_pending = "➜",
|
||||||
|
package_uninstalled = "✗"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
mason_lspconfig.setup({
|
||||||
|
-- list of servers for mason to install
|
||||||
|
ensure_installed = {
|
||||||
|
"tsserver",
|
||||||
|
"html",
|
||||||
|
"cssls",
|
||||||
|
"tailwindcss",
|
||||||
|
"svelte",
|
||||||
|
"lua_ls",
|
||||||
|
"graphql",
|
||||||
|
"emmet_ls",
|
||||||
|
"prismals",
|
||||||
|
"pyright",
|
||||||
|
"clangd"
|
||||||
|
},
|
||||||
|
-- auto-install configured servers (with lspconfig)
|
||||||
|
automatic_installation = true -- not the same as ensure_installed
|
||||||
|
})
|
||||||
|
|
||||||
|
mason_tool_installer.setup({
|
||||||
|
ensure_installed = {
|
||||||
|
"prettier", -- prettier formatter
|
||||||
|
"stylua", -- lua formatter
|
||||||
|
"isort", -- python formatter
|
||||||
|
"black", -- python formatter
|
||||||
|
"pylint", -- python linter
|
||||||
|
"eslint_d" -- js linter
|
||||||
|
}
|
||||||
|
})
|
||||||
|
end
|
||||||
|
}
|
72
configs/nvim/lua/plugins/configs/lsp/none_ls.lua
Normal file
72
configs/nvim/lua/plugins/configs/lsp/none_ls.lua
Normal file
@ -0,0 +1,72 @@
|
|||||||
|
return {
|
||||||
|
"nvimtools/none-ls.nvim", -- configure formatters & linters
|
||||||
|
lazy = true,
|
||||||
|
-- event = { "BufReadPre", "BufNewFile" }, -- to enable uncomment this
|
||||||
|
dependencies = {
|
||||||
|
"jay-babu/mason-null-ls.nvim",
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
local mason_null_ls = require("mason-null-ls")
|
||||||
|
local null_ls = require("null-ls")
|
||||||
|
local null_ls_utils = require("null-ls.utils")
|
||||||
|
|
||||||
|
mason_null_ls.setup({
|
||||||
|
ensure_installed = {
|
||||||
|
"prettier", -- prettier formatter
|
||||||
|
"stylua", -- lua formatter
|
||||||
|
"black", -- python formatter
|
||||||
|
"pylint", -- python linter
|
||||||
|
"eslint_d", -- js linter
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
-- for conciseness
|
||||||
|
local formatting = null_ls.builtins.formatting -- to setup formatters
|
||||||
|
local diagnostics = null_ls.builtins.diagnostics -- to setup linters
|
||||||
|
|
||||||
|
-- to setup format on save
|
||||||
|
local augroup = vim.api.nvim_create_augroup("LspFormatting", {})
|
||||||
|
|
||||||
|
-- configure null_ls
|
||||||
|
null_ls.setup({
|
||||||
|
-- add package.json as identifier for root (for typescript monorepos)
|
||||||
|
root_dir = null_ls_utils.root_pattern(".null-ls-root", "Makefile", ".git", "package.json"),
|
||||||
|
-- setup formatters & linters
|
||||||
|
sources = {
|
||||||
|
-- to disable file types use
|
||||||
|
-- "formatting.prettier.with({disabled_filetypes: {}})" (see null-ls docs)
|
||||||
|
formatting.prettier.with({
|
||||||
|
extra_filetypes = { "svelte" },
|
||||||
|
}), -- js/ts formatter
|
||||||
|
formatting.stylua, -- lua formatter
|
||||||
|
formatting.isort,
|
||||||
|
formatting.black,
|
||||||
|
diagnostics.pylint,
|
||||||
|
diagnostics.eslint_d.with({ -- js/ts linter
|
||||||
|
condition = function(utils)
|
||||||
|
return utils.root_has_file({ ".eslintrc.js", ".eslintrc.cjs" }) -- only enable if root has .eslintrc.js or .eslintrc.cjs
|
||||||
|
end,
|
||||||
|
}),
|
||||||
|
},
|
||||||
|
-- configure format on save
|
||||||
|
on_attach = function(current_client, bufnr)
|
||||||
|
if current_client.supports_method("textDocument/formatting") then
|
||||||
|
vim.api.nvim_clear_autocmds({ group = augroup, buffer = bufnr })
|
||||||
|
vim.api.nvim_create_autocmd("BufWritePre", {
|
||||||
|
group = augroup,
|
||||||
|
buffer = bufnr,
|
||||||
|
callback = function()
|
||||||
|
vim.lsp.buf.format({
|
||||||
|
filter = function(client)
|
||||||
|
-- only use null-ls for formatting instead of lsp server
|
||||||
|
return client.name == "null-ls"
|
||||||
|
end,
|
||||||
|
bufnr = bufnr,
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
}
|
51
configs/nvim/lua/plugins/configs/lualine.lua
Normal file
51
configs/nvim/lua/plugins/configs/lualine.lua
Normal file
@ -0,0 +1,51 @@
|
|||||||
|
-- нижняя информационная линия
|
||||||
|
return {
|
||||||
|
"nvim-lualine/lualine.nvim",
|
||||||
|
dependencies = {
|
||||||
|
"kyazdani42/nvim-web-devicons"
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
local lualine = require"lualine"
|
||||||
|
|
||||||
|
local opt = {
|
||||||
|
options = {
|
||||||
|
icons_enabled = true,
|
||||||
|
theme = 'auto',
|
||||||
|
component_separators = { left = '', right = ''},
|
||||||
|
section_separators = { left = '', right = ''},
|
||||||
|
disabled_filetypes = { 'packer', 'NvimTree' },
|
||||||
|
ignore_focus = {},
|
||||||
|
always_divide_middle = true,
|
||||||
|
globalstatus = false,
|
||||||
|
refresh = {
|
||||||
|
statusline = 1000,
|
||||||
|
tabline = 1000,
|
||||||
|
winbar = 1000
|
||||||
|
}
|
||||||
|
},
|
||||||
|
sections = {
|
||||||
|
lualine_a = {'mode'},
|
||||||
|
lualine_b = {'branch'},
|
||||||
|
--lualine_c = {'filename', full_path = true, shorten = false, maxchar = 70 },
|
||||||
|
lualine_c = {{'filename', file_status = false, path = 2 }},
|
||||||
|
lualine_x = {'encoding', 'filetype'},
|
||||||
|
lualine_y = {'progress'},
|
||||||
|
lualine_z = {'location'}
|
||||||
|
},
|
||||||
|
inactive_sections = {
|
||||||
|
lualine_a = {},
|
||||||
|
lualine_b = {},
|
||||||
|
lualine_c = {'filename'},
|
||||||
|
lualine_x = {'location'},
|
||||||
|
lualine_y = {},
|
||||||
|
lualine_z = {}
|
||||||
|
},
|
||||||
|
tabline = {},
|
||||||
|
winbar = {},
|
||||||
|
inactive_winbar = {},
|
||||||
|
extensions = {}
|
||||||
|
}
|
||||||
|
lualine.setup(opt)
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|
8
configs/nvim/lua/plugins/configs/neoscroll.lua
Normal file
8
configs/nvim/lua/plugins/configs/neoscroll.lua
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
-- плавная прокрутка
|
||||||
|
return {
|
||||||
|
"karb94/neoscroll.nvim",
|
||||||
|
config = function ()
|
||||||
|
require('neoscroll').setup{}
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|
90
configs/nvim/lua/plugins/configs/notify.lua
Normal file
90
configs/nvim/lua/plugins/configs/notify.lua
Normal file
@ -0,0 +1,90 @@
|
|||||||
|
-- notify popup прикольные уведомления в цветных рамочках, которые потом исчезают
|
||||||
|
return {
|
||||||
|
"rcarriga/nvim-notify",
|
||||||
|
config = function()
|
||||||
|
local notify = require"notify"
|
||||||
|
local stages_util = require"notify.stages.util"
|
||||||
|
local opts = {
|
||||||
|
---@usage Animation style one of { "fade", "slide", "fade_in_slide_out", "static" }
|
||||||
|
stages = {
|
||||||
|
function(state)
|
||||||
|
local next_row = stages_util.available_slot(
|
||||||
|
state.open_windows,
|
||||||
|
state.message.height + 2,
|
||||||
|
stages_util.DIRECTION.BOTTOM_UP
|
||||||
|
)
|
||||||
|
|
||||||
|
if not next_row then
|
||||||
|
return nil
|
||||||
|
end
|
||||||
|
|
||||||
|
return {
|
||||||
|
relative = "editor",
|
||||||
|
anchor = "NE",
|
||||||
|
width = state.message.width,
|
||||||
|
height = state.message.height,
|
||||||
|
col = 1,
|
||||||
|
row = next_row,
|
||||||
|
border = "rounded",
|
||||||
|
style = "minimal",
|
||||||
|
opacity = 0
|
||||||
|
}
|
||||||
|
end,
|
||||||
|
function(state, win)
|
||||||
|
return {
|
||||||
|
opacity = { 100 },
|
||||||
|
col = { 1 },
|
||||||
|
row = {
|
||||||
|
stages_util.slot_after_previous(
|
||||||
|
win,
|
||||||
|
state.open_windows,
|
||||||
|
stages_util.DIRECTION.BOTTOM_UP
|
||||||
|
),
|
||||||
|
frequency = 3,
|
||||||
|
complete = function()
|
||||||
|
return true
|
||||||
|
end
|
||||||
|
}
|
||||||
|
}
|
||||||
|
end
|
||||||
|
},
|
||||||
|
|
||||||
|
---@usage Function called when a new window is opened, use for changing win settings/config
|
||||||
|
on_open = nil,
|
||||||
|
|
||||||
|
---@usage Function called when a window is closed
|
||||||
|
on_close = nil,
|
||||||
|
|
||||||
|
---@usage timeout for notifications in ms, default 5000
|
||||||
|
timeout = 4000,
|
||||||
|
|
||||||
|
-- Render function for notifications. See notify-render()
|
||||||
|
render = "default",
|
||||||
|
|
||||||
|
---@usage highlight behind the window for stages that change opacity
|
||||||
|
background_colour = "#282A36",
|
||||||
|
-- background_colour = "Normal",
|
||||||
|
|
||||||
|
---@usage minimum width for notification windows
|
||||||
|
minimum_width = 30,
|
||||||
|
|
||||||
|
---@usage Icons for the different levels
|
||||||
|
icons = {
|
||||||
|
ERROR = "",
|
||||||
|
WARN = "",
|
||||||
|
INFO = "",
|
||||||
|
DEBUG = "",
|
||||||
|
TRACE = "✎"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if #vim.api.nvim_list_uis() == 0 then
|
||||||
|
-- no need to configure notifications in headless
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
notify.setup(opts)
|
||||||
|
vim.notify = notify
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|
163
configs/nvim/lua/plugins/configs/nvim_tree.lua
Normal file
163
configs/nvim/lua/plugins/configs/nvim_tree.lua
Normal file
@ -0,0 +1,163 @@
|
|||||||
|
-- дерево файлов
|
||||||
|
return {
|
||||||
|
"nvim-tree/nvim-tree.lua",
|
||||||
|
config = function()
|
||||||
|
local nvim_tree = require"nvim-tree"
|
||||||
|
|
||||||
|
local function on_attach(bufnr)
|
||||||
|
local api = require('nvim-tree.api')
|
||||||
|
|
||||||
|
local function opts(desc)
|
||||||
|
return { desc = 'nvim-tree: ' .. desc, buffer = bufnr, noremap = true, silent = true, nowait = true }
|
||||||
|
end
|
||||||
|
|
||||||
|
vim.keymap.set('n', "<C-]>", api.tree.change_root_to_node, opts("CD"))
|
||||||
|
vim.keymap.set('n', "<C-e>", api.node.open.replace_tree_buffer, opts("Open: In Place"))
|
||||||
|
vim.keymap.set('n', "<C-k>", api.node.show_info_popup, opts("Info"))
|
||||||
|
vim.keymap.set('n', "<C-r>", api.fs.rename_sub, opts("Rename: Omit Filename"))
|
||||||
|
vim.keymap.set('n', "<C-t>", api.node.open.tab, opts("Open: New Tab"))
|
||||||
|
vim.keymap.set('n', "<C-v>", api.node.open.vertical, opts("Open: Vertical Split"))
|
||||||
|
vim.keymap.set('n', "<C-x>", api.node.open.horizontal, opts("Open: Horizontal Split"))
|
||||||
|
vim.keymap.set('n', "<BS>", api.node.navigate.parent_close, opts("Close Directory"))
|
||||||
|
vim.keymap.set('n', "<CR>", api.node.open.edit, opts("Open"))
|
||||||
|
vim.keymap.set('n', "<Tab>", api.node.open.preview, opts("Open Preview"))
|
||||||
|
vim.keymap.set('n', '>', api.node.navigate.sibling.next, opts("Next Sibling"))
|
||||||
|
vim.keymap.set('n', '<', api.node.navigate.sibling.prev, opts("Previous Sibling"))
|
||||||
|
vim.keymap.set('n', '.', api.node.run.cmd, opts("Run Command"))
|
||||||
|
vim.keymap.set('n', '-', api.tree.change_root_to_parent, opts("Up"))
|
||||||
|
vim.keymap.set('n', 'a', api.fs.create, opts("Create"))
|
||||||
|
vim.keymap.set('n', "bmv", api.marks.bulk.move, opts("Move Bookmarked"))
|
||||||
|
vim.keymap.set('n', 'B', api.tree.toggle_no_buffer_filter, opts("Toggle No Buffer"))
|
||||||
|
vim.keymap.set('n', 'c', api.fs.copy.node, opts("Copy"))
|
||||||
|
vim.keymap.set('n', 'C', api.tree.toggle_git_clean_filter, opts("Toggle Git Clean"))
|
||||||
|
vim.keymap.set('n', "[c", api.node.navigate.git.prev, opts("Prev Git"))
|
||||||
|
vim.keymap.set('n', "]c", api.node.navigate.git.next, opts("Next Git"))
|
||||||
|
vim.keymap.set('n', 'd', api.fs.trash, opts("Trash"))
|
||||||
|
vim.keymap.set('n', 'D', api.fs.remove, opts("Delete"))
|
||||||
|
vim.keymap.set('n', 'E', api.tree.expand_all, opts("Expand All"))
|
||||||
|
vim.keymap.set('n', 'e', api.fs.rename_basename, opts("Rename: Basename"))
|
||||||
|
vim.keymap.set('n', "]e", api.node.navigate.diagnostics.next, opts("Next Diagnostic"))
|
||||||
|
vim.keymap.set('n', "[e", api.node.navigate.diagnostics.prev, opts("Prev Diagnostic"))
|
||||||
|
vim.keymap.set('n', 'F', api.live_filter.clear, opts("Clean Filter"))
|
||||||
|
vim.keymap.set('n', 'f', api.live_filter.start, opts("Filter"))
|
||||||
|
vim.keymap.set('n', "g?", api.tree.toggle_help, opts("Help"))
|
||||||
|
vim.keymap.set('n', "gy", api.fs.copy.absolute_path, opts("Copy Absolute Path"))
|
||||||
|
vim.keymap.set('n', 'H', api.tree.toggle_hidden_filter, opts("Toggle Dotfiles"))
|
||||||
|
vim.keymap.set('n', 'I', api.tree.toggle_gitignore_filter, opts("Toggle Git Ignore"))
|
||||||
|
vim.keymap.set('n', 'J', api.node.navigate.sibling.last, opts("Last Sibling"))
|
||||||
|
vim.keymap.set('n', 'K', api.node.navigate.sibling.first, opts("First Sibling"))
|
||||||
|
vim.keymap.set('n', 'm', api.marks.toggle, opts("Toggle Bookmark"))
|
||||||
|
vim.keymap.set('n', 'o', api.node.open.edit, opts("Open"))
|
||||||
|
vim.keymap.set('n', 'O', api.node.open.no_window_picker, opts("Open: No Window Picker"))
|
||||||
|
vim.keymap.set('n', 'p', api.fs.paste, opts("Paste"))
|
||||||
|
vim.keymap.set('n', 'P', api.node.navigate.parent, opts("Parent Directory"))
|
||||||
|
vim.keymap.set('n', 'q', api.tree.close, opts("Close"))
|
||||||
|
vim.keymap.set('n', 'r', api.fs.rename, opts("Rename"))
|
||||||
|
vim.keymap.set('n', 'R', api.tree.reload, opts("Refresh"))
|
||||||
|
vim.keymap.set('n', 's', api.node.run.system, opts("Run System"))
|
||||||
|
vim.keymap.set('n', 'S', api.tree.search_node, opts("Search"))
|
||||||
|
vim.keymap.set('n', 'U', api.tree.toggle_custom_filter, opts("Toggle Hidden"))
|
||||||
|
vim.keymap.set('n', 'W', api.tree.collapse_all, opts("Collapse"))
|
||||||
|
vim.keymap.set('n', 'x', api.fs.cut, opts("Cut"))
|
||||||
|
vim.keymap.set('n', 'y', api.fs.copy.filename, opts("Copy Name"))
|
||||||
|
vim.keymap.set('n', 'Y', api.fs.copy.relative_path, opts("Copy Relative Path"))
|
||||||
|
vim.keymap.set('n', "<2-LeftMouse>", api.node.open.edit, opts("Open"))
|
||||||
|
vim.keymap.set('n', "<2-RightMouse>", api.tree.change_root_to_node, opts("CD"))
|
||||||
|
-- END_DEFAULT_ON_ATTACH
|
||||||
|
|
||||||
|
-- Mappings migrated from view.mappings.list
|
||||||
|
vim.keymap.set('n', 'l', api.node.open.edit, opts("Open"))
|
||||||
|
vim.keymap.set('n', "<CR>", api.node.open.edit, opts("Open"))
|
||||||
|
vim.keymap.set('n', 'o', api.node.open.edit, opts("Open"))
|
||||||
|
vim.keymap.set('n', 'h', api.node.navigate.parent_close, opts("Close Directory"))
|
||||||
|
vim.keymap.set('n', 'v', api.node.open.vertical, opts("Open: Vertical Split"))
|
||||||
|
vim.keymap.set('n', 'D', api.fs.remove, opts("Delete"))
|
||||||
|
vim.keymap.set('n', 'd', api.fs.trash, opts("Trash"))
|
||||||
|
end
|
||||||
|
|
||||||
|
nvim_tree.setup({
|
||||||
|
on_attach = on_attach,
|
||||||
|
disable_netrw = true,
|
||||||
|
hijack_netrw = true,
|
||||||
|
open_on_tab = false,
|
||||||
|
hijack_cursor = false,
|
||||||
|
update_cwd = true,
|
||||||
|
diagnostics = {
|
||||||
|
enable = true,
|
||||||
|
icons = {
|
||||||
|
hint = "",
|
||||||
|
info = "",
|
||||||
|
warning = "",
|
||||||
|
error = ""
|
||||||
|
}
|
||||||
|
},
|
||||||
|
update_focused_file = {
|
||||||
|
enable = true,
|
||||||
|
update_cwd = true,
|
||||||
|
ignore_list = {},
|
||||||
|
update_root = false
|
||||||
|
},
|
||||||
|
system_open = {
|
||||||
|
cmd = nil,
|
||||||
|
args = {}
|
||||||
|
},
|
||||||
|
git = {
|
||||||
|
enable = true,
|
||||||
|
ignore = true,
|
||||||
|
timeout = 200
|
||||||
|
},
|
||||||
|
filters = {
|
||||||
|
dotfiles = false,
|
||||||
|
custom = { "node_modules", ".cache" }
|
||||||
|
},
|
||||||
|
hijack_unnamed_buffer_when_opening = false,
|
||||||
|
renderer = {
|
||||||
|
icons = {
|
||||||
|
glyphs = {
|
||||||
|
default = "",
|
||||||
|
symlink = "",
|
||||||
|
git = {
|
||||||
|
unstaged = "",
|
||||||
|
staged = "S",
|
||||||
|
unmerged = "",
|
||||||
|
renamed = "➜",
|
||||||
|
deleted = "",
|
||||||
|
untracked = "U",
|
||||||
|
ignored = "◌",
|
||||||
|
},
|
||||||
|
folder = {
|
||||||
|
default = "",
|
||||||
|
open = "",
|
||||||
|
empty = "",
|
||||||
|
empty_open = "",
|
||||||
|
--symlink = "",
|
||||||
|
symlink = "",
|
||||||
|
symlink_open = ""
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
view = {
|
||||||
|
-- hide_root_folder = false,
|
||||||
|
side = "left",
|
||||||
|
width = 40,
|
||||||
|
-- mappings = {
|
||||||
|
-- custom_only = false,
|
||||||
|
-- list = {
|
||||||
|
-- { key = { "l", "<CR>", "o" }, cb = tree_cb "edit" },
|
||||||
|
-- { key = "h", cb = tree_cb "close_node" },
|
||||||
|
-- { key = "v", cb = tree_cb "vsplit" },
|
||||||
|
-- { key = "D", action = "remove" },
|
||||||
|
-- { key = "d", action = "trash" }
|
||||||
|
-- }
|
||||||
|
-- },
|
||||||
|
number = false,
|
||||||
|
relativenumber = false
|
||||||
|
},
|
||||||
|
trash = {
|
||||||
|
cmd = "delete",
|
||||||
|
require_confirm = true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
end
|
||||||
|
}
|
160
configs/nvim/lua/plugins/configs/telescope.lua
Normal file
160
configs/nvim/lua/plugins/configs/telescope.lua
Normal file
@ -0,0 +1,160 @@
|
|||||||
|
-- teleascope для поиска
|
||||||
|
return {
|
||||||
|
"nvim-telescope/telescope.nvim",
|
||||||
|
tag = "0.1.5",
|
||||||
|
config = function()
|
||||||
|
local telescope = require"telescope"
|
||||||
|
local actions = require "telescope.actions"
|
||||||
|
local fb_actions = require "telescope._extensions.file_browser.actions"
|
||||||
|
|
||||||
|
local opts = {
|
||||||
|
defaults = {
|
||||||
|
prompt_prefix = "🔍 ",
|
||||||
|
selection_caret = " ",
|
||||||
|
-- path_display = { "smart" },
|
||||||
|
path_display = {
|
||||||
|
shorten = {
|
||||||
|
len = 7, exclude = { 1, -1 }
|
||||||
|
},
|
||||||
|
truncate = true,
|
||||||
|
},
|
||||||
|
initial_mode = "insert",
|
||||||
|
|
||||||
|
vimgrep_arguments = {
|
||||||
|
"rg",
|
||||||
|
"--color=never",
|
||||||
|
"--no-heading",
|
||||||
|
"--with-filename",
|
||||||
|
"--line-number",
|
||||||
|
"--column",
|
||||||
|
"--smart-case",
|
||||||
|
"--hidden",
|
||||||
|
"--glob=!.git/"
|
||||||
|
},
|
||||||
|
|
||||||
|
mappings = {
|
||||||
|
i = {
|
||||||
|
["<C-n>"] = actions.cycle_history_next,
|
||||||
|
["<C-p>"] = actions.cycle_history_prev,
|
||||||
|
|
||||||
|
["<C-j>"] = actions.move_selection_next,
|
||||||
|
["<C-k>"] = actions.move_selection_previous,
|
||||||
|
|
||||||
|
["<C-c>"] = actions.close,
|
||||||
|
|
||||||
|
["<Down>"] = actions.move_selection_next,
|
||||||
|
["<Up>"] = actions.move_selection_previous,
|
||||||
|
|
||||||
|
["<CR>"] = actions.select_default,
|
||||||
|
["<C-x>"] = actions.select_horizontal,
|
||||||
|
["<C-v>"] = actions.select_vertical,
|
||||||
|
["<C-t>"] = actions.select_tab,
|
||||||
|
|
||||||
|
["<C-u>"] = actions.preview_scrolling_up,
|
||||||
|
["<C-d>"] = actions.preview_scrolling_down,
|
||||||
|
|
||||||
|
["<PageUp>"] = actions.results_scrolling_up,
|
||||||
|
["<PageDown>"] = actions.results_scrolling_down,
|
||||||
|
|
||||||
|
["<Tab>"] = actions.toggle_selection + actions.move_selection_worse,
|
||||||
|
["<S-Tab>"] = actions.toggle_selection + actions.move_selection_better,
|
||||||
|
["<C-q>"] = actions.send_to_qflist + actions.open_qflist,
|
||||||
|
["<M-q>"] = actions.send_selected_to_qflist + actions.open_qflist,
|
||||||
|
["<C-l>"] = actions.complete_tag,
|
||||||
|
["<C-_>"] = actions.which_key -- keys from pressing <C-/>
|
||||||
|
},
|
||||||
|
|
||||||
|
n = {
|
||||||
|
["<esc>"] = actions.close,
|
||||||
|
["<CR>"] = actions.select_default,
|
||||||
|
["<C-x>"] = actions.select_horizontal,
|
||||||
|
["<C-v>"] = actions.select_vertical,
|
||||||
|
["<C-t>"] = actions.select_tab,
|
||||||
|
|
||||||
|
["<Tab>"] = actions.toggle_selection + actions.move_selection_worse,
|
||||||
|
["<S-Tab>"] = actions.toggle_selection + actions.move_selection_better,
|
||||||
|
["<C-q>"] = actions.send_to_qflist + actions.open_qflist,
|
||||||
|
["<M-q>"] = actions.send_selected_to_qflist + actions.open_qflist,
|
||||||
|
|
||||||
|
["j"] = actions.move_selection_next,
|
||||||
|
["k"] = actions.move_selection_previous,
|
||||||
|
["H"] = actions.move_to_top,
|
||||||
|
["M"] = actions.move_to_middle,
|
||||||
|
["L"] = actions.move_to_bottom,
|
||||||
|
|
||||||
|
["<Down>"] = actions.move_selection_next,
|
||||||
|
["<Up>"] = actions.move_selection_previous,
|
||||||
|
["gg"] = actions.move_to_top,
|
||||||
|
["G"] = actions.move_to_bottom,
|
||||||
|
|
||||||
|
["<C-u>"] = actions.preview_scrolling_up,
|
||||||
|
["<C-d>"] = actions.preview_scrolling_down,
|
||||||
|
|
||||||
|
["<PageUp>"] = actions.results_scrolling_up,
|
||||||
|
["<PageDown>"] = actions.results_scrolling_down,
|
||||||
|
|
||||||
|
["?"] = actions.which_key
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
file_ignore_patterns = {
|
||||||
|
".git/",
|
||||||
|
".cache",
|
||||||
|
"%.o",
|
||||||
|
"%.a",
|
||||||
|
"%.out",
|
||||||
|
"%.class",
|
||||||
|
"%.pdf",
|
||||||
|
"%.mkv",
|
||||||
|
"%.mp4",
|
||||||
|
"%.zip",
|
||||||
|
"telescope_history"
|
||||||
|
},
|
||||||
|
winblend = 0,
|
||||||
|
border = {},
|
||||||
|
borderchars = { "─", "│", "─", "│", "╭", "╮", "╯", "╰" },
|
||||||
|
color_devicons = true,
|
||||||
|
set_env = { ["COLORTERM"] = "truecolor" }, -- default = nil,
|
||||||
|
pickers = {
|
||||||
|
-- find_files = {
|
||||||
|
-- find_command = { "fd", "--type=file", "--hidden" }
|
||||||
|
-- },
|
||||||
|
live_grep = {
|
||||||
|
--@usage don't include the filename in the search results
|
||||||
|
only_sort_text = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
extensions = {
|
||||||
|
fzf = {
|
||||||
|
fuzzy = true, -- false will only do exact matching
|
||||||
|
override_generic_sorter = true, -- override the generic sorter
|
||||||
|
override_file_sorter = true, -- override the file sorter
|
||||||
|
case_mode = "smart_case", -- or "ignore_case" or "respect_case"
|
||||||
|
},
|
||||||
|
media_files = {
|
||||||
|
-- filetypes whitelist
|
||||||
|
-- defaults to {"png", "jpg", "mp4", "webm", "pdf"}
|
||||||
|
filetypes = { "png", "webp", "jpg", "jpeg" },
|
||||||
|
-- find command (defaults to `fd`)
|
||||||
|
find_cmd = "rg"
|
||||||
|
},
|
||||||
|
file_browser = {
|
||||||
|
theme = "ivy",
|
||||||
|
previewer = true,
|
||||||
|
mappings = {
|
||||||
|
["n"] = {
|
||||||
|
["a"] = fb_actions.create,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
telescope.setup(opts)
|
||||||
|
|
||||||
|
telescope.load_extension "media_files"
|
||||||
|
telescope.load_extension "file_browser"
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
7
configs/nvim/lua/plugins/configs/tmux_navigator.lua
Normal file
7
configs/nvim/lua/plugins/configs/tmux_navigator.lua
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
-- tmux плагин перемещения
|
||||||
|
-- см. core/mappings.lua
|
||||||
|
return {
|
||||||
|
"christoomey/vim-tmux-navigator",
|
||||||
|
lazzy = false
|
||||||
|
}
|
||||||
|
|
102
configs/nvim/lua/plugins/configs/treesitter.lua
Normal file
102
configs/nvim/lua/plugins/configs/treesitter.lua
Normal file
@ -0,0 +1,102 @@
|
|||||||
|
-- подсветка синтаксиса
|
||||||
|
return {
|
||||||
|
"nvim-treesitter/nvim-treesitter",
|
||||||
|
cmd = { "TSInstall", "TSBufEnable", "TSBufDisable", "TSEnable", "TSDisable", "TSModuleInfo" },
|
||||||
|
config = function()
|
||||||
|
local ts_config = require"nvim-treesitter.configs"
|
||||||
|
|
||||||
|
local default = {
|
||||||
|
on_config_done = nil,
|
||||||
|
ignore_install = {},
|
||||||
|
ensure_installed = {
|
||||||
|
"lua",
|
||||||
|
"vim",
|
||||||
|
"cpp",
|
||||||
|
"vue",
|
||||||
|
"cmake",
|
||||||
|
"css",
|
||||||
|
"html",
|
||||||
|
"go",
|
||||||
|
"glsl",
|
||||||
|
"javascript",
|
||||||
|
"json",
|
||||||
|
"llvm",
|
||||||
|
"meson",
|
||||||
|
"pug",
|
||||||
|
"query",
|
||||||
|
"regex",
|
||||||
|
"scss",
|
||||||
|
"sql",
|
||||||
|
"yaml",
|
||||||
|
"typescript",
|
||||||
|
"dockerfile"
|
||||||
|
},
|
||||||
|
matchup = {
|
||||||
|
enable = false -- mandatory, false will disable the whole extension
|
||||||
|
-- disable = { "c", "ruby" }, -- optional, list of language that will be disabled
|
||||||
|
},
|
||||||
|
highlight = {
|
||||||
|
enable = true,
|
||||||
|
use_languagetree = true,
|
||||||
|
additional_vim_regex_highlighting = true,
|
||||||
|
disable = { "latex" }
|
||||||
|
},
|
||||||
|
context_commentstring = {
|
||||||
|
enable = true,
|
||||||
|
config = {
|
||||||
|
-- Languages that have a single comment style
|
||||||
|
typescript = "// %s",
|
||||||
|
css = "/* %s */",
|
||||||
|
scss = "/* %s */",
|
||||||
|
html = "<!-- %s -->",
|
||||||
|
svelte = "<!-- %s -->",
|
||||||
|
vue = "<!-- %s -->",
|
||||||
|
json = ""
|
||||||
|
}
|
||||||
|
},
|
||||||
|
-- indent = {enable = true, disable = {"python", "html", "javascript"}},
|
||||||
|
indent = { enable = false, disable = { "yaml" } },
|
||||||
|
autotag = { enable = true },
|
||||||
|
textobjects = {
|
||||||
|
swap = {
|
||||||
|
enable = false
|
||||||
|
-- swap_next = textobj_swap_keymaps,
|
||||||
|
},
|
||||||
|
-- move = textobj_move_keymaps,
|
||||||
|
select = {
|
||||||
|
enable = false
|
||||||
|
-- keymaps = textobj_sel_keymaps,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
textsubjects = {
|
||||||
|
enable = false,
|
||||||
|
keymaps = { ["."] = "textsubjects-smart", [";"] = "textsubjects-big" }
|
||||||
|
},
|
||||||
|
playground = {
|
||||||
|
enable = false,
|
||||||
|
disable = {},
|
||||||
|
updatetime = 25, -- Debounced time for highlighting nodes in the playground from source code
|
||||||
|
persist_queries = false, -- Whether the query persists across vim sessions
|
||||||
|
keybindings = {
|
||||||
|
toggle_query_editor = "o",
|
||||||
|
toggle_hl_groups = "i",
|
||||||
|
toggle_injected_languages = "t",
|
||||||
|
toggle_anonymous_nodes = "a",
|
||||||
|
toggle_language_display = "I",
|
||||||
|
focus_language = "f",
|
||||||
|
unfocus_language = "F",
|
||||||
|
update = "R",
|
||||||
|
goto_node = "<cr>",
|
||||||
|
show_help = "?"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
rainbow = {
|
||||||
|
enable = true,
|
||||||
|
extended_mode = true, -- Highlight also non-parentheses delimiters, boolean or table: lang -> boolean
|
||||||
|
max_file_lines = 5000 -- Do not enable for files with more than 1000 lines, int
|
||||||
|
},
|
||||||
|
}
|
||||||
|
ts_config.setup(default)
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|
12
configs/nvim/lua/plugins/configs/wich_key.lua
Normal file
12
configs/nvim/lua/plugins/configs/wich_key.lua
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
-- позсказки по клавиатуре
|
||||||
|
return {
|
||||||
|
"folke/which-key.nvim",
|
||||||
|
event = "VeryLazy",
|
||||||
|
init = function()
|
||||||
|
vim.o.timeout = true
|
||||||
|
vim.o.timeoutlen = 200
|
||||||
|
end,
|
||||||
|
opts = { }
|
||||||
|
}
|
||||||
|
|
||||||
|
|
38
configs/nvim/lua/plugins/init.lua
Normal file
38
configs/nvim/lua/plugins/init.lua
Normal file
@ -0,0 +1,38 @@
|
|||||||
|
local M = {}
|
||||||
|
|
||||||
|
M.load = function()
|
||||||
|
-- офф. загрузка lazy если что см. их доки https://github.com/folke/lazy.nvim
|
||||||
|
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", -- latest stable release
|
||||||
|
lazypath
|
||||||
|
})
|
||||||
|
end
|
||||||
|
vim.opt.rtp:prepend(lazypath)
|
||||||
|
|
||||||
|
require("lazy").setup(
|
||||||
|
{
|
||||||
|
{ import = "plugins.configs" },
|
||||||
|
{ import = "plugins.configs.lsp" }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
install = {
|
||||||
|
colorscheme = { "catppuccin" }
|
||||||
|
},
|
||||||
|
checker = {
|
||||||
|
enabled = false, -- проверка обновления
|
||||||
|
notify = false -- уведомление об обновлении
|
||||||
|
},
|
||||||
|
change_detection = {
|
||||||
|
notify = false -- уведомление если файл изменили
|
||||||
|
}
|
||||||
|
}
|
||||||
|
)
|
||||||
|
end
|
||||||
|
|
||||||
|
return M
|
||||||
|
|
||||||
|
-- опробовать
|
||||||
|
-- https://github.com/aznhe21/actions-preview.nvim
|
@ -1,22 +1,3 @@
|
|||||||
/*
|
|
||||||
*
|
|
||||||
* Copyright © 2022 To Cyb3rTh1eveZ
|
|
||||||
*
|
|
||||||
* ██████╗██╗ ██╗██████╗ ██████╗ ██████╗ ████████╗██╗ ██╗ ██╗███████╗██╗ ██╗███████╗███████╗
|
|
||||||
* ██╔════╝╚██╗ ██╔╝██╔══██╗╚════██╗██╔══██╗╚══██╔══╝██║ ██║███║██╔════╝██║ ██║██╔════╝╚══███╔╝
|
|
||||||
* ██║ ╚████╔╝ ██████╔╝ █████╔╝██████╔╝ ██║ ███████║╚██║█████╗ ██║ ██║█████╗ ███╔╝
|
|
||||||
* ██║ ╚██╔╝ ██╔══██╗ ╚═══██╗██╔══██╗ ██║ ██╔══██║ ██║██╔══╝ ╚██╗ ██╔╝██╔══╝ ███╔╝
|
|
||||||
* ╚██████╗ ██║ ██████╔╝██████╔╝██║ ██║ ██║ ██║ ██║ ██║███████╗ ╚████╔╝ ███████╗███████╗
|
|
||||||
* ╚═════╝ ╚═╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝╚══════╝ ╚═══╝ ╚══════╝╚══════╝
|
|
||||||
*
|
|
||||||
*
|
|
||||||
* Copyright (C) Mahmoud Mohamed (00xWolf) <https://github.com/mmsaeed509
|
|
||||||
* LICENSE © GNU-GPL3
|
|
||||||
*
|
|
||||||
*
|
|
||||||
* */
|
|
||||||
|
|
||||||
|
|
||||||
configuration {
|
configuration {
|
||||||
|
|
||||||
/*---------- General setting ----------*/
|
/*---------- General setting ----------*/
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
<property name="last-icon-view-zoom-level" type="string" value="THUNAR_ZOOM_LEVEL_150_PERCENT"/>
|
<property name="last-icon-view-zoom-level" type="string" value="THUNAR_ZOOM_LEVEL_150_PERCENT"/>
|
||||||
<property name="last-show-hidden" type="bool" value="true"/>
|
<property name="last-show-hidden" type="bool" value="true"/>
|
||||||
<property name="last-separator-position" type="int" value="158"/>
|
<property name="last-separator-position" type="int" value="158"/>
|
||||||
<property name="last-window-width" type="int" value="3816"/>
|
<property name="last-window-width" type="int" value="1901"/>
|
||||||
<property name="last-window-height" type="int" value="2086"/>
|
<property name="last-window-height" type="int" value="2086"/>
|
||||||
<property name="last-window-maximized" type="bool" value="false"/>
|
<property name="last-window-maximized" type="bool" value="false"/>
|
||||||
<property name="misc-single-click" type="bool" value="false"/>
|
<property name="misc-single-click" type="bool" value="false"/>
|
||||||
|
15
makepkg.sh
15
makepkg.sh
@ -1,6 +1,19 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
source "$HOME/bin/scripts/system/style"
|
RESET_COLOR="\033[0m"
|
||||||
|
BOLD="\033[1m"
|
||||||
|
ITALIC="\033[3m"
|
||||||
|
|
||||||
|
BLACK="\033[30m"
|
||||||
|
RED="\033[31m"
|
||||||
|
GREEN="\033[32m"
|
||||||
|
YELLOW="\033[33m"
|
||||||
|
BLUE="\033[34m"
|
||||||
|
MAGENTA="\033[35m"
|
||||||
|
CYAN="\033[36m"
|
||||||
|
WHITE="\033[37m"
|
||||||
|
PURPLE="\033[35m"
|
||||||
|
|
||||||
|
|
||||||
BUILDING_DIR="build"
|
BUILDING_DIR="build"
|
||||||
|
|
||||||
|
@ -1,6 +1,18 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
source "$HOME/bin/scripts/system/style"
|
RESET_COLOR="\033[0m"
|
||||||
|
BOLD="\033[1m"
|
||||||
|
ITALIC="\033[3m"
|
||||||
|
|
||||||
|
BLACK="\033[30m"
|
||||||
|
RED="\033[31m"
|
||||||
|
GREEN="\033[32m"
|
||||||
|
YELLOW="\033[33m"
|
||||||
|
BLUE="\033[34m"
|
||||||
|
MAGENTA="\033[35m"
|
||||||
|
CYAN="\033[36m"
|
||||||
|
WHITE="\033[37m"
|
||||||
|
PURPLE="\033[35m"
|
||||||
|
|
||||||
USER=`echo ${SUDO_USER:-$(whoami)}`
|
USER=`echo ${SUDO_USER:-$(whoami)}`
|
||||||
GID=`echo ${SUDO_GID}`
|
GID=`echo ${SUDO_GID}`
|
||||||
@ -18,6 +30,8 @@ BACKUP (){
|
|||||||
mkdir -p ${BACKUP_DIR}/${FILES_NAME}-${BACKUP_NAME}-${BACKUP_RANDOM}
|
mkdir -p ${BACKUP_DIR}/${FILES_NAME}-${BACKUP_NAME}-${BACKUP_RANDOM}
|
||||||
|
|
||||||
echo -e ${CYAN}" ==> перемещаем текущий конфиг ${PURPLE}${FILES_NAME} ${CYAN} в backup дирректорию." ${RESET_COLOR}
|
echo -e ${CYAN}" ==> перемещаем текущий конфиг ${PURPLE}${FILES_NAME} ${CYAN} в backup дирректорию." ${RESET_COLOR}
|
||||||
|
mv ${CONFIG_DIR}/bspwm ${BACKUP_DIR}/${FILES_NAME}-${BACKUP_NAME}-${BACKUP_RANDOM}
|
||||||
|
mv ${CONFIG_DIR}/nvim ${BACKUP_DIR}/${FILES_NAME}-${BACKUP_NAME}-${BACKUP_RANDOM}
|
||||||
mv ${CONFIG_DIR}/geany ${BACKUP_DIR}/${FILES_NAME}-${BACKUP_NAME}-${BACKUP_RANDOM}
|
mv ${CONFIG_DIR}/geany ${BACKUP_DIR}/${FILES_NAME}-${BACKUP_NAME}-${BACKUP_RANDOM}
|
||||||
mv ${CONFIG_DIR}/gtk-2.0 ${BACKUP_DIR}/${FILES_NAME}-${BACKUP_NAME}-${BACKUP_RANDOM}
|
mv ${CONFIG_DIR}/gtk-2.0 ${BACKUP_DIR}/${FILES_NAME}-${BACKUP_NAME}-${BACKUP_RANDOM}
|
||||||
mv ${CONFIG_DIR}/gtk-3.0 ${BACKUP_DIR}/${FILES_NAME}-${BACKUP_NAME}-${BACKUP_RANDOM}
|
mv ${CONFIG_DIR}/gtk-3.0 ${BACKUP_DIR}/${FILES_NAME}-${BACKUP_NAME}-${BACKUP_RANDOM}
|
||||||
@ -42,6 +56,8 @@ INSTALL (){
|
|||||||
echo -e ${BOLD}${GREEN}"\n[*] устанавливаем пакет: ${CYAN}${PKG_NAME}${GREEN} ..." ${RESET_COLOR}
|
echo -e ${BOLD}${GREEN}"\n[*] устанавливаем пакет: ${CYAN}${PKG_NAME}${GREEN} ..." ${RESET_COLOR}
|
||||||
|
|
||||||
mkdir -p ${CONFIG_DIR}
|
mkdir -p ${CONFIG_DIR}
|
||||||
|
cp -rf ${CONFIG_DIR_SKEL}/bspwm ${CONFIG_DIR}
|
||||||
|
cp -rf ${CONFIG_DIR_SKEL}/nvim ${CONFIG_DIR}
|
||||||
cp -rf ${CONFIG_DIR_SKEL}/geany ${CONFIG_DIR}
|
cp -rf ${CONFIG_DIR_SKEL}/geany ${CONFIG_DIR}
|
||||||
cp -rf ${CONFIG_DIR_SKEL}/gtk-2.0 ${CONFIG_DIR}
|
cp -rf ${CONFIG_DIR_SKEL}/gtk-2.0 ${CONFIG_DIR}
|
||||||
cp -rf ${CONFIG_DIR_SKEL}/gtk-3.0 ${CONFIG_DIR}
|
cp -rf ${CONFIG_DIR_SKEL}/gtk-3.0 ${CONFIG_DIR}
|
||||||
@ -58,6 +74,8 @@ INSTALL (){
|
|||||||
cp ${CONFIG_DIR_SKEL}/mimeapps.list ${CONFIG_DIR}
|
cp ${CONFIG_DIR_SKEL}/mimeapps.list ${CONFIG_DIR}
|
||||||
|
|
||||||
echo -e ${CYAN}" ==> предоставление разрешений для пользователя: ${PURPLE}${USER}" ${RESET_COLOR}
|
echo -e ${CYAN}" ==> предоставление разрешений для пользователя: ${PURPLE}${USER}" ${RESET_COLOR}
|
||||||
|
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/bspwm
|
||||||
|
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/nvim
|
||||||
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/geany
|
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/geany
|
||||||
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/gtk-2.0
|
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/gtk-2.0
|
||||||
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/gtk-3.0
|
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/gtk-3.0
|
||||||
@ -73,8 +91,7 @@ INSTALL (){
|
|||||||
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/xfce4
|
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/xfce4
|
||||||
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/mimeapps.list
|
chown -R ${USER}:${GROUB} ${CONFIG_DIR}/mimeapps.list
|
||||||
|
|
||||||
|
if [[ -d "${CONFIG_DIR}/bspwm" && -d "${CONFIG_DIR}/nvim" && -d "${CONFIG_DIR}/geany" && -d "${CONFIG_DIR}/gtk-2.0" && -d "${CONFIG_DIR}/gtk-3.0" && -d "${CONFIG_DIR}/jgmenu" && -d "${CONFIG_DIR}/kitty" && -d "${CONFIG_DIR}/lazygit" && -d "${CONFIG_DIR}/neofetch" && -d "${CONFIG_DIR}/networkmanager-dmenu" && -d "${CONFIG_DIR}/nitrogen" && -d "${CONFIG_DIR}/qt5ct" && -d "${CONFIG_DIR}/rofi" && -d "${CONFIG_DIR}/Thunar" && -d "${CONFIG_DIR}/xfce4" && -f "${CONFIG_DIR}/mimeapps.list" ]]; then
|
||||||
if [[ -d "${CONFIG_DIR}/geany" && -d "${CONFIG_DIR}/gtk-2.0" && -d "${CONFIG_DIR}/gtk-3.0" && -d "${CONFIG_DIR}/jgmenu" && -d "${CONFIG_DIR}/kitty" && -d "${CONFIG_DIR}/lazygit" && -d "${CONFIG_DIR}/neofetch" && -d "${CONFIG_DIR}/networkmanager-dmenu" && -d "${CONFIG_DIR}/nitrogen" && -d "${CONFIG_DIR}/qt5ct" && -d "${CONFIG_DIR}/rofi" && -d "${CONFIG_DIR}/Thunar" && -d "${CONFIG_DIR}/xfce4" && -f "${CONFIG_DIR}/mimeapps.list" ]]; then
|
|
||||||
echo -e ${BOLD}${GREEN}"[✔] конфигурационные файлы установлены..." ${RESET_COLOR}
|
echo -e ${BOLD}${GREEN}"[✔] конфигурационные файлы установлены..." ${RESET_COLOR}
|
||||||
else
|
else
|
||||||
echo -e ${BOLD}${RED}"[✘] ошибка установки..." ${RESET_COLOR}
|
echo -e ${BOLD}${RED}"[✘] ошибка установки..." ${RESET_COLOR}
|
||||||
@ -87,7 +104,7 @@ RUN_MAIN (){
|
|||||||
if [[ "${GROUB}" == 'liveuser' ]]; then
|
if [[ "${GROUB}" == 'liveuser' ]]; then
|
||||||
exit
|
exit
|
||||||
else
|
else
|
||||||
if [[ ! -d "${CONFIG_DIR}/geany" && ! -d "${CONFIG_DIR}/gtk-2.0" && ! -d "${CONFIG_DIR}/gtk-3.0" && ! -d "${CONFIG_DIR}/jgmenu" && ! -d "${CONFIG_DIR}/kitty" && ! -d "${CONFIG_DIR}/lazygit" && ! -d "${CONFIG_DIR}/neofetch" && ! -d "${CONFIG_DIR}/networkmanager-dmenu" && ! -d "${CONFIG_DIR}/nitrogen" && ! -d "${CONFIG_DIR}/qt5ct" && ! -d "${CONFIG_DIR}/rofi" && ! -d "${CONFIG_DIR}/Thunar" && ! -d "${CONFIG_DIR}/xfce4" && ! -f "${CONFIG_DIR}/mimeapps.list" ]]; then
|
if [[ ! -d "${CONFIG_DIR}/bspwm" && ! -d "${CONFIG_DIR}/nvim" && ! -d "${CONFIG_DIR}/geany" && ! -d "${CONFIG_DIR}/gtk-2.0" && ! -d "${CONFIG_DIR}/gtk-3.0" && ! -d "${CONFIG_DIR}/jgmenu" && ! -d "${CONFIG_DIR}/kitty" && ! -d "${CONFIG_DIR}/lazygit" && ! -d "${CONFIG_DIR}/neofetch" && ! -d "${CONFIG_DIR}/networkmanager-dmenu" && ! -d "${CONFIG_DIR}/nitrogen" && ! -d "${CONFIG_DIR}/qt5ct" && ! -d "${CONFIG_DIR}/rofi" && ! -d "${CONFIG_DIR}/Thunar" && ! -d "${CONFIG_DIR}/xfce4" && ! -f "${CONFIG_DIR}/mimeapps.list" ]]; then
|
||||||
INSTALL
|
INSTALL
|
||||||
else
|
else
|
||||||
BACKUP
|
BACKUP
|
||||||
@ -96,7 +113,6 @@ RUN_MAIN (){
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
post_install() {
|
post_install() {
|
||||||
RUN_MAIN
|
RUN_MAIN
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user